RomânăEnglish
 
exteon.ro - Manual
2.2. Installation

The main way of distribution for the php profiler extension is, for now, source code tarball. To compile the extension, you will need the php-devel package. If you don't have it, you will need to install it; the precise command differs depending on the Linux distro you use; in CentOS for instance it's:

yum install php-devel

You will, ofcourse, need all the tools of the trade for compiling, like C compiler etc, but if you install the php devel package from rpms, like in the example above, this will take care of all dependencies as well.

 

1)  Download the PHP Profiler source tarball

 

You can find the source bundle on the project's main page, under the download icon. Or just click here to get to the profiler download page.

 

 2) Extract the source folder

tar -xzf web3tracer-<version>.tar.gz

3) Compile:

cd web3tracer cd extension phpize ./configure make

4) Install

 

The previous step should have created the web3tracer.so file in the web3tracer/extension/modules folder. You will need to copy this to the right place (usually /etc/lib/php/modules) and enable it in /etc/php.ini, or /etc/php.d/web3tracer.ini, then restart the web server to account for the new PHP profiler module:

cp modules/web3tracer.so /usr/lib/php/modules/ echo "extension=web3tracer.so" > /etc/php.d/web3tracer.ini service httpd restart

For more information about compiling and installing PHP modules, visit this link: http://php.net/manual/en/install.pecl.phpize.php

 

5) Check that module is loaded

 

You should check the output of the phpinfo() function to make sure the module is loaded and running. In order to do that, create a PHP file in your web server's document root, say info.php, with the following content:

<?php phpinfo(); ?>

Then access it in your browser, probably at http://localhost/info.php and check the web3tracer module is listed; it should read something like:

web3tracer

web3tracer 1.0.1
CPU num 2
 

 

Once this is done, the PHP profiler is ready for operation. Go on to the next chapters to start profiling your first PHP script.

 


(c) SC EXTEON SRL 2006-2009, All Rights Reserved
Powered by   Web3 CMS