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
4.4k views
in Technique[技术] by (71.8m points)

Xdebug + phpstorm调试配置问题

感觉之前都能调试的,现在又没法调试了,感觉各个配置都正常!各配置信息如下:

环境:Ubuntu 18.04 + Nginx + php7.2-fpm + Xdebug 2.6
php服务器地址是192.168.0.116
本地装过phpstorm软件的地址是192.168.0.10

xdebgu.ini:

zend_extension=/usr/lib/php/20170718/xdebug.so
xdebug.remote_handler=dbgp
xdebug.remote_autostart=1
xdebug.remote_enable=1
xdebug.idekey=PHPSTORM
xdebug.remote_host=192.168.0.116
xdebug.remote_port=9009
xdebug.remote_connect_back = 1
xdebug.auto_trace=1
xdebug.remote_log=/var/log/xdebug.log

image

image

然后是phpstorm配置:
image

image

image

image

image

怎么破?baidu了各种方法,就是不成功!

这是xdebug的log:

Log opened at 2020-12-18 06:39:00
I: Checking remote connect back address.
I: Checking header 'HTTP_X_FORWARDED_FOR'.
I: Checking header 'REMOTE_ADDR'.
W: Remote address not found, connecting to configured address/port: 192.168.0.116:9009. :-|
W: Creating socket for '192.168.0.116:9009', poll success, but error: Operation now in progress (29).
E: Could not connect to client. :-(
Log closed at 2020-12-18 06:39:00

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

1 Answer

0 votes
by (71.8m points)

这里可以不配置。

图片.png
然后就是 host 配置。

图片.png

图片.png

看起来你只有一个 xdebug.remote_host 需要修改

xdebug.remote_host=192.168.0.10

修改后记得重启 FPM


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

...