xDebug not connecting with Netbeans -
i have vm (centos 7, apache, php 5.4). small test php script works no problem. when try debug netbeans (8.0.2 on windows 8.1) shows 'waiting connection' , nothing more happens. using ssh tunnel vm port 9005 host port 9005.
xdebug log:
log opened @ 2015-08-16 18:11:22 i: connecting configured address/port: localhost:9005. i: connected client. :-) -> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" fileuri="file:///var/www/project/html/index.php" language="php" protocol_version="1.0" appid="55867" idekey="netbeans-xdebug"><engine version="2.3.2"><![cdata[xdebug]]></engine><author><![cdata[derick rethans]]></author><url><![cdata[http://xdebug.org]]></url><copyright><![cdata[copyright (c) 2002-2015 derick rethans]]></copyright></init> -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" status="stopping" reason="ok"></response> log closed @ 2015-08-16 18:11:24
result php -i :
xdebug support => enabled ide key => netbeans-xdebug xdebug.auto_trace => off xdebug.cli_color => 0 xdebug.collect_assignments => off xdebug.collect_includes => on xdebug.collect_params => 0 xdebug.collect_return => off xdebug.collect_vars => off xdebug.coverage_enable => on xdebug.default_enable => on xdebug.dump.cookie => no value xdebug.dump.env => no value xdebug.dump.files => no value xdebug.dump.get => no value xdebug.dump.post => no value xdebug.dump.request => no value xdebug.dump.server => no value xdebug.dump.session => no value xdebug.dump_globals => on xdebug.dump_once => on xdebug.dump_undefined => off xdebug.extended_info => on xdebug.file_link_format => no value xdebug.force_display_errors => off xdebug.force_error_reporting => 0 xdebug.halt_level => 0 xdebug.idekey => netbeans-xdebug xdebug.max_nesting_level => 256 xdebug.max_stack_frames => -1 xdebug.overload_var_dump => on xdebug.profiler_aggregate => off xdebug.profiler_append => off xdebug.profiler_enable => off xdebug.profiler_enable_trigger => off xdebug.profiler_enable_trigger_value => no value xdebug.profiler_output_dir => /tmp xdebug.profiler_output_name => cachegrind.out.%p xdebug.remote_autostart => off xdebug.remote_connect_back => off xdebug.remote_cookie_expire_time => 3600 xdebug.remote_enable => on xdebug.remote_handler => dbgp xdebug.remote_host => localhost xdebug.remote_log => /var/log/xdebug/debug.log xdebug.remote_mode => req xdebug.remote_port => 9005 xdebug.scream => off xdebug.show_exception_trace => off xdebug.show_local_vars => off xdebug.show_mem_delta => off xdebug.trace_enable_trigger => off xdebug.trace_enable_trigger_value => no value xdebug.trace_format => 0 xdebug.trace_options => 0 xdebug.trace_output_dir => /tmp xdebug.trace_output_name => trace.%c xdebug.var_display_max_children => 128 xdebug.var_display_max_data => 2048 xdebug.var_display_max_depth => 3
i tried same config xdebugclient , worked -> issues netbeans.
remote log xdebugclient:
log opened @ 2015-08-16 19:43:51 i: connecting configured address/port: localhost:9005. i: connected client. :-) -> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" fileuri="file:///var/www/project/html/index.php" language="php" protocol_version="1.0" appid="58314" idekey="netbeans-xdebug"><engine version="2.3.3"><![cdata[xdebug]]></engine><author><![cdata[derick rethans]]></author><url><![cdata[http://xdebug.org]]></url><copyright><![cdata[copyright (c) 2002-2015 derick rethans]]></copyright></init> <- run -i xdc2 -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" command="run" transaction_id="xdc2" status="break" reason="ok"><xdebug:message filename="file:///var/www/project/html/index.php" lineno="13"></xdebug:message></response> <- step_out -i xdc10 -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="http://xdebug.org/dbgp/xdebug" command="step_out" transaction_id="xdc10" status="stopping" reason="ok"></response> log closed @ 2015-08-16 19:45:11
in settings have
xdebug.remote_host => localhost
you should have ip address of remote machine (the 1 runs netbeans), , assume should have debuging port opened on windows firewall, centos can connect port in netbeans. haven't done remote debugging on other machines, local, should work.
xdebug sample static ip/single developer:
- the ip of server 10.0.1.2 http on port 80
- the ide on ip 10.0.1.42, xdebug.remote_host set 10.0.1.42
- the ide listens on port 9000, xdebug.remote_port set 9000
- the http request started on machine running ide
- xdebug connects 10.0.1.42:9000
- debugging runs, http response provided
xdebug documentation: http://xdebug.org/docs/remote
Comments
Post a Comment