Skip to content
YaronMiro edited this page Oct 6, 2014 · 7 revisions

Let's install pear:

sudo apt-get install php5-dev php-pear

Let's install xDebug:

sudo pecl install xdebug

After the process will end you'll get something like this:

running: find "/tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4" | xargs ls -dils
3804571   4 drwxr-xr-x 3 root root   4096 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4
3804627   4 drwxr-xr-x 3 root root   4096 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4/usr
3938413   4 drwxr-xr-x 3 root root   4096 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4/usr/lib
3938414   4 drwxr-xr-x 3 root root   4096 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4/usr/lib/php5
3938415   4 drwxr-xr-x 2 root root   4096 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4/usr/lib/php5/20090626
3938416 808 -rwxr-xr-x 1 root root 825487 Mar  4 09:09 /tmp/pear/temp/pear-build-rootAEFhBM/install-xdebug-2.2.4/usr/lib/php5/20090626/xdebug.so


Build process completed successfully
Installing '/usr/lib/php5/20090626/xdebug.so'

You'll need the path of the xdebug.so
which is the path at the end of the log file:
example: Installing '/usr/lib/php5/20090626/xdebug.so'

Edit you php.ini field and the next code:

[zend_extension]
zend_extension="/usr/lib/php5/20090626/xdebug.so"
xdebug.remote_enable=1
xdebug.remote_port=9000
xdebug.profiler_enable=1
xdebug.profiler_output_dir="/tmp"

Restart your apache and you have xDebug install.