Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I propose adding to the README some simple text and useful links. The XHProf docs are absolutely fine for getting people going, sure, people should be able to work that out for themselves, but some simple steps in the README couldn't hurt - install xhprof from PECL, enable and configure, read the docs for how the UI works - link. Job done! =)
If you think this is a good idea, happy to provide the patch to README.txt.
Comment | File | Size | Author |
---|---|---|---|
#13 | XHProf_Documentation.pdf | 283.44 KB | davidwhthomas |
#3 | 1278864-3-xhprof_docs_added.patch | 3.51 KB | greg.harvey |
Comments
Comment #1
salvisYes, definitely a good idea.
I've never used XHProf myself, so you'll need to find others to review and RTBC your patch.
Is there only one way to install XHProf?
Comment #2
greg.harveyNo, more than one way - you can also install manually, but PECL is easiest (when it works!) ... I'll work on a patch. =)
Comment #3
greg.harveyOK, here's a first pass.
Comment #4
salvisThis looks definitely valuable, thank you!
Any XHProf users out there who could review it?
Comment #5
moshe weitzman CreditAttribution: moshe weitzman commentedWe are planning to remove xhprof integration from devel in favor of the revived and nice xhprof module. See http://drupal.org/project/xhprof.
Comment #6
greg.harveySounds good. That module could do with an edit on the project page and a dev snapshot release though! Guess I'll raise an issue for that...
Edit: Done - #1304968: Update project page to explain this project is alive again
Comment #7
Anonymous (not verified) CreditAttribution: Anonymous commentedThe XHProf install step failed for me on a Mac with MAMP 2, but I was able to find a gist that worked really nicely: https://gist.github.com/1306569
It looks like these need to be updated for the change in modules, but as soon as I got XHProf installed, the admin screens worked for me.
Comment #8
nerdcore CreditAttribution: nerdcore commentedI have installed the xhprof.so PHP extension using PECL and enabled it in /etc/php5/conf.d/xhprof.ini. This is working because I can see "xhprof" in the output of `php -m`.
I have installed the Drupal XHProf 7.x-1.0-beta2 module and enabled it on the Modules page of my site.
I have turned enabled the use of the module at Configuration -> Development -> XHProf settings (/admin/config/development/xhprof) by checking ON " Enable profiling of all page views and drush requests. "
Now what?
When I visit a page and click "XHProf output" at the bottom of the page, I get this error:
" Run #51b789ae8cea0: Invalid Run Id = 51b789ae8cea0 "
And the list of the "Top 100 functions" is totally empty. I am a bit lost as to what I should be seeing or where to go from here. Any help greatly appreciated.
Comment #9
jessepinho CreditAttribution: jessepinho commented@nerdcore: Did you add these lines to your php.ini?
Even after adding those lines, I was still getting the error you described. But when I manually created the /var/tmp/xhprof directory, it started working. Hope this helps!
Comment #10
sah62 CreditAttribution: sah62 commentedAnother note: your web server user needs to have write permission on the xhprof.output_dir directory.
Comment #11
donquixote CreditAttribution: donquixote commentedThanks @jessepinho (#9) and @sah62 (#10).
This advice sounds obvious, but it would really help to have some error reporting on admin/reports/xhprof/% pages for non-writable or non-existing directories, or missing PHP configuration.
Comment #12
donquixote CreditAttribution: donquixote commentedSee #2335663: Show warnings for missing directories, file permissions, php config
Comment #13
davidwhthomas CreditAttribution: davidwhthomas commentedRelated to https://www.drupal.org/node/2393853
I just added some online documentation there for now.
I was especially interested in the glossary of XHProf terms:
Attaching facebook XHProf docs from webarchive as pdf.
Perhaps the link on the project page could be updated to point to the new URL:
http://web.archive.org/web/20110514095512/http://mirror.facebook.net/fac...