Poll success, but error: Operation now in progress (29). when Xdebug trying connect to PhpStorm from docker container Poll success, but error: Operation now in progress (29). when Xdebug trying connect to PhpStorm from docker container docker docker

Poll success, but error: Operation now in progress (29). when Xdebug trying connect to PhpStorm from docker container


Xdebug can't connect to PhpStorm because PhpStorm was not reachable by my external host ip.How I debug it.First I checked from docker container that PhpStorm listen port (9000 in my case)

nc -vz external_ip 9000

It got (tcp) failed: Connection refused
I try the same from the host and also got the errorThen I tried from host

nc -vz localhost 9000

And I got [tcp/*] succeeded!So the problem in xdebug.remote_host not in PhpStorm probably

I found host ip in container

netstat -nr | grep '^0\.0\.0\.0' | awk '{print $2}'

Put it in xdebug.remote_host and now it works correctly

Thanks for @LazyOne


In my case I simply set the following xdebug conf:

xdebug.remote_connect_back=0xdebug.remote_host=host.docker.internal

host.docker.internal should 'magically' find the host's IP (cf. documentation). Note that this requires Docker v18.03+ and currently only works on Mac and Windows hosts.


May be your xdebug.remote_port 9000 is using by php-fpm. You try changing other port. Example xdebug.remote_port=9001 and in launch.json file still port=9000