PHP Xdebug installation on Fedora/CentOS x64
First, install xdebug
package on system:
$ sudo yum install php-pecl-xdebug.x86_64
Or with DNF:
$ sudo dnf install php-xdebug
If your have an Nginx server, we should restart the PHP processor php-fpm
:
$ sudo systemctl restart php-fpm
Or if you have a Apache server, we should restart the httpd
server:
$ sudo systemctl restart httpd
Finally, verify if xdebug extension is loaded:
php -r "echo (extension_loaded('xdebug') ? 'xdebug up and running!' : 'xdebug is not loaded!');"
// xdebug up and running!⏎
Ran into a minor issue with the last command to verify if xdebug is running on fedora 27. Apparently the double and single quotes are inverse. ran it successful with :
php -r 'echo (extension_loaded("xdebug") ? "xdebug up and running!" : "xdebug is not loaded!");'