Debug Management - Profile: Performance testing.
Ok real quick question how and were do you turn this on? I have looked all over the place for where to enter and what to use with the PROFILE_PUBLISHER environment variable and I cannot find where you are supposed to enter this information and how? z2.py? Command line? or in the start parameters section of windows 2000 services? TIA Sherwood ---------------------------------------------------- Sherwood Robinson Hostmaster The Free Lance-Star/Internet Department srobinson@fredericksburg.com http://www.fredericksburg.com 616 Amelia St. Fredericksburg, VA 22401 540-374-5000 ext. 5657
Hi Sherwood, put this in your Zope's "start" script (assumes you're running Zope on UNIX): export PROFILE_PUBLISHER=var/profile.log Then stop and restart Zope. Visiting the debug section of the control panel, visit the profile tab. You'll see profiling information on that screen. The next trick is making sense out of it... but let's get you set up first. Note that profiling will slow a site down by up to 20 times, so it's probably not a good idea to do this in production. - C ----- Original Message ----- From: "Sherwood Robinson" <srobinson@fredericksburg.com> To: <zope@zope.org> Sent: Monday, April 09, 2001 12:39 PM Subject: [Zope] Debug Management - Profile: Performance testing.
Ok real quick question how and were do you turn this on? I have looked all over the place for where to enter and what to use with the PROFILE_PUBLISHER environment variable and I cannot find where you are supposed to enter this information and how?
z2.py? Command line? or in the start parameters section of windows 2000 services?
TIA
Sherwood
---------------------------------------------------- Sherwood Robinson Hostmaster The Free Lance-Star/Internet Department srobinson@fredericksburg.com http://www.fredericksburg.com
616 Amelia St. Fredericksburg, VA 22401 540-374-5000 ext. 5657
_______________________________________________ Zope maillist - Zope@zope.org http://lists.zope.org/mailman/listinfo/zope ** No cross posts or HTML encoding! ** (Related lists - http://lists.zope.org/mailman/listinfo/zope-announce http://lists.zope.org/mailman/listinfo/zope-dev )
On Tuesday 10 April 2001 00:46, Chris McDonough wrote:
Hi Sherwood,
put this in your Zope's "start" script (assumes you're running Zope on UNIX):
export PROFILE_PUBLISHER=var/profile.log
Then stop and restart Zope.
just for fun, i tried this. what i tried inserting PROFILE_PUBLISHER=var/profile.log in my start and also export PROFILE_PUBLISHER=var/profile.log profiling is enabled. but there's no profile.log in var
Visiting the debug section of the control panel, visit the profile tab. You'll see profiling information on that screen.
The next trick is making sense out of it... but let's get you set up first.
yes - i see stuff. care to help me make some sense? 536018 function calls (518142 primitive calls) in 43.490 CPU seconds Ordered by: internal time List reduced from 397 to 100 due to restriction <100> ncalls tottime percall cumtime percall filename:lineno(function) 150784 11.570 0.000 15.060 0.000 UserDb.py:445(sqlattr) 36 9.080 0.252 31.030 0.862 UserDb.py:134(getUsers) 150784 3.490 0.000 3.490 0.000 UserDb.py:440(typeconv) 37696 2.960 0.000 2.960 0.000 UserDb.py:45(__init__) 38296 2.380 0.000 2.380 0.000 Results.py:171(__getitem__) 2847/38 1.050 0.000 9.110 0.240 DT_InSV.py:380(__getitem__) 689 0.950 0.001 1.400 0.002 Results.py:106(__init__) 4729 0.900 0.000 1.720 0.000 ZopeSecurityPolicy.py:100(validate) ...snipped more stuff--- thanks -----------8<------------------- http://www.kedai.com.my/kk http://www.kedai.com.my/eZine http://www.zope.org/members/kedai I will follow you! Damage Inc.
just for fun, i tried this. what i tried
inserting PROFILE_PUBLISHER=var/profile.log in my start
and also export PROFILE_PUBLISHER=var/profile.log
profiling is enabled. but there's no profile.log in var
The profiling information is accumulated in memory until Zope is shutdown (via the control panel). When you go to the Control Panel and click shutdown, the profile.log will be written.
Visiting the debug section of the control panel, visit the profile tab. You'll see profiling information on that screen.
The next trick is making sense out of it... but let's get you set up first.
yes - i see stuff. care to help me make some sense?
536018 function calls (518142 primitive calls) in 43.490 CPU seconds
Zope profiling just uses the Python profiler (with some extra machinery to deal with thread issues). You can use the Python profiler docs to learn to read the output: http://www.python.org/doc/current/lib/module-profile.html Brian Lloyd brian@digicool.com Software Engineer 540.371.6909 Digital Creations http://www.digicool.com
participants (4)
-
bak -
Brian Lloyd -
Chris McDonough -
Sherwood Robinson