xdebug (again :(

Greetings
Sorry for another xdebug related questions.
I'm trying to use it through ssh following the tutorial (https://www.jetbrains.com/help/phpstorm/remote-debugging-via-ssh-tunnel.html#set-up-an-ssh-tunnel-to-the-remote-machine).
Everything seems to be set up, and I can actually see the traffic between PHPStorm and the server with tcpdump.
In the debug settings, everything is checked (things like "break on first line" and so on).

If I disabled with the phone icon, the traffic stops.

However, it doesn't break.

Can you help me?

Thanks in advance

Regards

3 comments
Comment actions Permalink

Hi there,

Start with enabling Xdebug log, then try to debug. The log will contain what file initiates the debug (the path). Could be that the path mapping is wrong...

Showing your Xdebug settings (both PhpStorm + xdebug_info() output) should also add some info into what you have got there.

0
Comment actions Permalink

Thanks for your answer.

Xdebug log starts with:

[26010] Log opened at 2022-01-18 14:09:09.420009                                                                                                                                                                                                                              
[26010] [Step Debug] INFO: Connecting to configured address/port: 127.0.0.1:9001.
[26010] [Step Debug] INFO: Connected to debugging client: 127.0.0.1:9001 (through xdebug.client_host/xdebug.client_port). :-)
[26010] [Step Debug] -> <init xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" fileuri="file:///var/www/decitox/html-20220117/index.php" language="PHP" xdebug:language_version="7.4.15" protocol_version="1.0" appid="26010" idekey="phpstorm">
<engine version="3.0.2"><![CDATA[Xdebug]]></engine><author><![CDATA[Derick Rethans]]></author><url><![CDATA[https://xdebug.org]]></url><copyright><![CDATA[Copyright (c) 2002-2021 by Derick Rethans]]></copyright></init>
                                       
[26010] [Step Debug] <- eval -i 1 -- KHN0cmluZykoaW5pX2dldCgneGRlYnVnLmNvdmVyYWdlX2VuYWJsZScpLic7Jy5pbmlfZ2V0KCd4ZGVidWcucHJvZmlsZXJfZW5hYmxlJykuJzsnLmluaV9nZXQoJ3hkZWJ1Zy5yZW1vdGVfYXV0b3N0YXJ0JykuJzsnLmluaV9nZXQoJ3hkZWJ1Zy5yZW1vdGVfY29ubmVjdF9iYWNrJykuJzsnLmluaV9nZXQoJ
3hkZWJ1Zy5yZW1vdGVfbW9kZScpKQ==
[26010] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="eval" transaction_id="1"><property type="string" size="509" encoding="base64"><![CDATA[VGhpcyBzZXR0aW5nIGhhcyBiZWVuIGNoYW5nZWQsIHNlZSB0aGUgdXBncmFka
W5nIGd1aWRlIGF0IGh0dHBzOi8veGRlYnVnLm9yZy9kb2NzL3VwZ3JhZGVfZ3VpZGUjY2hhbmdlZC14ZGVidWcuY292ZXJhZ2VfZW5hYmxlO1RoaXMgc2V0dGluZyBoYXMgYmVlbiBjaGFuZ2VkLCBzZWUgdGhlIHVwZ3JhZGluZyBndWlkZSBhdCBodHRwczovL3hkZWJ1Zy5vcmcvZG9jcy91cGdyYWRlX2d1aWRlI2NoYW5nZWQteGRlYnVnLnByb2Z
[26010] [Step Debug] <- feature_set -i 2 -n show_hidden -v 1                                                                                                                                                                                                                  
[26010] [Step Debug] -> <response xmlns="urn:debugger_protocol_v1" xmlns:xdebug="https://xdebug.org/dbgp/xdebug" command="feature_set" transaction_id="2" feature="show_hidden" success="1"></response>

 

The mapping seems correct, but I don't see here on what PHPtorm makes the selection of the "server" configuration, where the mapping is made...

The xdebug config in PHPStorm is:



In the ini file:

xdebug.mode=debug 
xdebug.client_host=127.0.0.1
xdebug.client_port=9001
xdebug.start_with_request=yes

 

What should I use in the "server" definition inside PHPStorm?

 

0
Comment actions Permalink

OK I found the problem... the "server" was set to 443 but as the webserver is actually behind a proxy, it should be set to 80...

0

Please sign in to leave a comment.