简体   繁体   English

xDebug随机在端口9000(nginx)上启动大量连接

[英]xDebug randomly starting a lot of connections on port 9000 (nginx)

I am encountering the following issue with xdebug: 我在xdebug中遇到以下问题:

When i try to connect to xDebug and start debugging by sending a request with from the browser with ?XDEBUG_SESSION_START=netbeans-xdebug , a lot of connections are being made to port 9000, as shown by netstat -a | grep 9000 当我尝试连接到xDebug并通过使用?XDEBUG_SESSION_START=netbeans-xdebug从浏览器发送请求开始调试时,正在建立与9000端口的许多连接,如netstat -a | grep 9000所示netstat -a | grep 9000 netstat -a | grep 9000

This seems to happen randomly. 这似乎是随机发生的。 If I'm lucky, netstat -a | 如果幸运的话,netstat -a | grep 9000 will just show one connection and everything works fine. grep 9000只会显示一个连接,并且一切正常。 But when there is more than one connection debugging won't work. 但是,当连接不止一个时,调试将无法进行。 The only solution then is to stop the debugger, and kill all the connections on port 9000. 然后,唯一的解决方案是停止调试器,并终止端口9000上的所有连接。

The problems started when swithcing from Apache to Nginx a while ago. 从Apache切换到Nginx之前,问题就开始了。

nginx version: nginx/1.6.1 running on Ubuntu Server 12.04.5 LTS with PHP 5.5.15 nginx版本:在装有PHP 5.5.15的Ubuntu Server 12.04.5 LTS上运行的nginx / 1.6.1

xdebug config: xdebug配置:

xdebug support => enabled
Version => 2.2.5
IDE Key => marijn

Supported protocols => Revision
DBGp - Common DeBuGger Protocol => $Revision: 1.145 $

Directive => Local Value => Master Value
xdebug.auto_trace => Off => Off
xdebug.cli_color => 0 => 0
xdebug.collect_assignments => Off => Off
xdebug.collect_includes => On => On
xdebug.collect_params => 0 => 0
xdebug.collect_return => Off => Off
xdebug.collect_vars => Off => Off
xdebug.coverage_enable => On => On
xdebug.default_enable => On => On
xdebug.dump.COOKIE => no value => no value
xdebug.dump.ENV => no value => no value
xdebug.dump.FILES => no value => no value
xdebug.dump.GET => no value => no value
xdebug.dump.POST => no value => no value
xdebug.dump.REQUEST => no value => no value
xdebug.dump.SERVER => no value => no value
xdebug.dump.SESSION => no value => no value
xdebug.dump_globals => On => On
xdebug.dump_once => On => On
xdebug.dump_undefined => Off => Off
xdebug.extended_info => On => On
xdebug.file_link_format => no value => no value
xdebug.idekey => no value => no value
xdebug.max_nesting_level => 100000 => 100000
xdebug.overload_var_dump => On => On
xdebug.profiler_aggregate => Off => Off
xdebug.profiler_append => Off => Off
xdebug.profiler_enable => Off => Off
xdebug.profiler_enable_trigger => On => On
xdebug.profiler_output_dir => /tmp => /tmp
xdebug.profiler_output_name => cachegrind.out.%p => cachegrind.out.%p
xdebug.remote_autostart => Off => Off
xdebug.remote_connect_back => Off => Off
xdebug.remote_cookie_expire_time => 3600 => 3600
xdebug.remote_enable => On => On
xdebug.remote_handler => dbgp => dbgp
xdebug.remote_host => localhost => localhost
xdebug.remote_log => no value => no value
xdebug.remote_mode => req => req
xdebug.remote_port => 9000 => 9000
xdebug.scream => Off => Off
xdebug.show_exception_trace => Off => Off
xdebug.show_local_vars => Off => Off
xdebug.show_mem_delta => Off => Off
xdebug.trace_enable_trigger => Off => Off
xdebug.trace_format => 0 => 0
xdebug.trace_options => 0 => 0
xdebug.trace_output_dir => /tmp => /tmp
xdebug.trace_output_name => trace.%c => trace.%c
xdebug.var_display_max_children => 128 => 128
xdebug.var_display_max_data => 512 => 512
xdebug.var_display_max_depth => 3 => 3

I have been able to reproduce the problem, it consequently happens when i start my debugging session in Chrome (with the extension 'xDebug Helper') earlier than my debugging session in netbeans. 我已经能够重现该问题,因此,当我在Chrome中启动调试会话(扩展名为“ xDebug Helper”)时早于在netbeans中进行调试会话时发生。

So the problem is resolved by first starting my debugging session from netbeans, and then in chrome. 因此,首先通过netbeans启动调试会话,然后在chrome中解决问题。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM