Connecting to xdebug fails ...

Hi, all

I'm having some troubles with xdebug in the last time ...

I have a local setup like following:

* Installed php54, php55 and php56 on a mac via homebrew
* Installed the extension for php5*-xdebug for all of them
* Configured xdebug like following:

zend_extension=<path to .so file>



* Installed version of xdebug is 2.2.5 for all php-versions
* Registered each of these installations in PhpStorm as PHP interpreters (all correctly recognized, including xdebug version)
* Registered a PHP server for and validated the xdebug configuration (works)

My PhpUnit also is installed by homebrew (shouldn't really make any difference at all, but just to have that mentioned). I use 4.2.0 in combination with the latest EAP and 3.7.30 for the last stable version of PhpStorm.

Whatever combination I take (PhpStorm 7.1.3 - phpUnit 3.7.30 or PhpStorm EAP - phpUnit 4.2.0), when running the debugger for unit-tests, I always get the response, that the connection could not be established.
Screen Shot 2014-09-15 at 10.43.56 vorm..png

When clicking on "Validate installation", I just get "'xdebug' extension is installed. Check configuration options."
Screen Shot 2014-09-15 at 10.45.41 vorm..png

Here's the configuration shown when clicking on "Show phpinfo":

PHP version: 5.6.0

Loaded extensions:
apc, apcu, bcmath, bz2, calendar, Core,        couchbase, ctype, curl, date, dba, dom, ereg, exif, fileinfo, filter,        ftp, gd, gettext, hash, iconv, imagick, intl, json, ldap, libxml,        mbstring, mcrypt, memcache, memcached, mhash, mysql, mysqli, mysqlnd,        odbc, openssl, pcntl, pcre, PDO, pdo_mysql, PDO_ODBC, pdo_sqlite, Phar,        posix, readline, Reflection, session, shmop, SimpleXML, snmp, soap,        sockets, SPL, sqlite3, standard, sysvmsg, sysvsem, sysvshm, tokenizer,        wddx, xdebug, xml, xmlreader, xmlrpc, xmlwriter, xsl, zip, zlib

Screen Shot 2014-09-15 at 10.53.25 vorm..png

Comment actions Permalink

Hi there,

1) xdebug version used?

2) Please enable logging on both xdebug & PhpStorm sides and attempt to debug -- see what they will have to say about it:

Check that server (host name or IP) as well as port (especially port) match your settings in IDE


  • Make sure that all "Debug" tool windows are closed.
  • Activate "phone handle" icon -- IDE will start listening on xdebug port.
  • Check your network connections (e.g. via netstat or any other tool) -- make sure that it's PhpStorm who listens on xdebug port -- maybe that port is occupied by some another process

4) Same as above -- but instead of  last step -- try connecting to xdebug port using telnet (e.g. "telnet 9000" -- not 100% sure that it's correct syntax for Mac). Maybe firewall / antivirus software blocks incoming connections

Comment actions Permalink

Thanks very much for the detailed response, Andriy.

The problem for me was, that the PHP-FPM module for  PHP 5.6.0 created an fpm-controler, listening on the port 9000 :|
Using sockets for the fpm-controler now. Works perfectly!


Please sign in to leave a comment.