Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.0k views
in Technique[技术] by (71.8m points)

php - Phpstorm, xdebug and vagrant still waiting for incoming connection

This is annoying me, mainly because it was working fine then all of a sudden breakpoints stopped breaking and when i checked debugger it was just waiting for incoming connection.

My vagrant machine is running on private_ip: 192.168.13.37

My xdebug.ini config is as follows:

zend_extension=/usr/lib/php5/20090626+lfs/xdebug.so
xdebug.remote_enable = on
xdebug.remote_connect_back = on
xdebug.remote_port = 9020

These are my PHPstorm debug settings: enter image description here

I have a vagrant server setup in PHPstorm which has a host of dev.website.com which points at the correct IP in windows host file, the port is 80 and the folders are mapped correctly.

I also have PHP application set up to use the explained server which a start url of / .

I have clicked start listening for PHP debug connections, then clicked the little green bug icon to start debugging. This launches the project with the following query string ?XDEBUG_SESSION_START=18359 but when I look in PHPstorm in the debug window it will say waiting for incoming connection with ide key 18359

Any ideas how to get it working again?

Edit Added xdebug log : pastebin

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Had identical problem, what helped me is setting :

xdebug.remote_autostart = 1

my other settings are:

zend_extension=xdebug.so
xdebug.remote_enable=1
xdebug.remote_connect_back=1
xdebug.remote_port=9010
xdebug.idekey=phpstorm
xdebug.remote_autostart = 1
xdebug.remote_handler=dbgp
xdebug.remote_host=10.0.2.2

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...