Jump to content

Recommended Posts

Hi Guys,

On a fresh debian 9 install, php7.2 all working nicely. Then I try to install xdebug. I followed the instructions here https://xdebug.org/docs/install

Basically I ran


sudo pecl install xdebug


and added  zend_extension=/usr/lib/php/20180731/xdebug.so to my /etc/php/7.2/fpm/php.ini file

I've checked in /usr/lib/php/20180731 and xdebug.so is there. When i view my phpinfo() there is no mention of xdebug, pretty sure that aint right.

How to go about checking my installation

Share this post

Link to post
Share on other sites

How is PHP integrated into the browser?  Is it Apache with mod_php, nginx with php-fpm?  

Also did you run command line php (php -i) and see if the module is showing there? 

What xdebug configuration do you have?  Is there an xdebug.ini, and if so where, and what are the contents? 

Share this post

Link to post
Share on other sites
Posted (edited)

Hi gizmola,


I have nginx and php-fpm,

php -i does not show xdebug as being installed.

I added 


zend_extension = /usr/lib/php/20180731/xdebug.so


to the bottom of /etc/php/7.2/fpm/php.ini and restarted nginx

AFAIK i don't have a xdebug.ini.

Edited by ludo1960

Share this post

Link to post
Share on other sites

After much fiddling around I see that the make test command seems to want to use php 7.3, but php -v returns 


ludo@aegir:/usr/lib/php$ php -v
Failed loading /usr/lib/php/20180731/xdebug.so:  /usr/lib/php/20180731/xdebug.so: undefined symbol: zend_hash_add
PHP 7.2.18-1+0~20190503103213.21+stretch~1.gbp101320 (cli) (built: May  3 2019 10:32:13) ( NTS )
Copyright (c) 1997-2018 The PHP Group
Zend Engine v3.2.0, Copyright (c) 1998-2018 Zend Technologies
    with Zend OPcache v7.2.18-1+0~20190503103213.21+stretch~1.gbp101320, Copyright (c) 1999-2018, by Zend Technologies

How can I make xdebug use php 7.2, I did use php 7.2 in the xdebug configuration tool


ludo@aegir:~/Downloads/xdebug-2.7.2$ make test

Build complete.
Don't forget to run 'make test'.

PHP         : /usr/bin/php7.3 
PHP_SAPI    : cli
PHP_VERSION : 7.3.5-1+0~20190503093827.38+stretch~1.gbp60a41b
PHP_OS      : Linux - Linux aegir.local.com 4.9.0-9-amd64 #1 SMP Debian 4.9.168-1 (2019-04-12) x86_64
INI actual  : /home/ludo/Downloads/xdebug-2.7.2/tmp-php.ini
More .INIs  :   
CWD         : /home/ludo/Downloads/xdebug-2.7.2
Extra dirs  : 
VALGRIND    : Not used
TIME START 2019-05-09 02:47:18
No tests were run.

Any ideas guys?

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.