-
Notifications
You must be signed in to change notification settings - Fork 13
Install xhprof
Yuri edited this page Jun 17, 2015
·
9 revisions
- Update toturial on how to install + combined with the xhprof module.
INSTALL DEPENDENCIES
apt-get install php5-dev
sudo pecl config-set preferred_state beta
sudo pecl install xhprof
DOWNLOAD XHPROF SOURCE
cd /tmp
git clone git://github.com/facebook/xhprof.git
INSTALL XHPROF EXTENSION
cd xhprof/extension
phpize
./configure
make
make install
EDIT PHP INI FILE Edit the PHP inf file and add the next code in the end:
The likely location (ubuntu 14.04) nano /etc/php5/apache2/php.ini
.
[xhprof]
extension=xhprof.so
xhprof.output_dir=/tmp
Restart your apache server
cd into your www folder and run the next command:
mkdir xhprof
cp -a /tmp/xhprof/xhprof_* /var/www/xhprof
Go to devel settings and check on enable profile and set the next variables:
xhprof directory - /var/www/xhprof
XHProf URL - http://localhost/xhprof/xhprof_html
Create a symlink to our xhprof_html folder. So just in case set this:
ln -s /usr/share/php/xhprof_html /var/www/html/xhprof_html
Get graphing functions:
sudo apt-get install graphviz
sudo service apache2 restart
Useful articles: drupal.stackexchange.com