I'm struggling with this error message. Sometimes I cannot run xdebug on Visual Studio Code after upgrading or restarting the editor. Here's a screenshot of the error:
Can anyone help me with this?
I'm struggling with this error message. Sometimes I cannot run xdebug on Visual Studio Code after upgrading or restarting the editor. Here's a screenshot of the error:
Can anyone help me with this?
After several minutes to find out what happens on my machine, i figure it out how to solve my problem.
Because the xdebug is running based on port 9000
and i see on the Debug Console
(VSCode) has message listen EADDRINUSE :::9000
, i think there is an another process running on port 9000
so i check what process running on it by this command
sudo netstat -nlp | grep :9000
The command above will show you what process running on port 9000
, then i get this result
tcp6 0 0 :::9000 :::* LISTEN 14856/hhvm
HHVM was take over port of xdebug by default, so i need to take it service down or change the port number.
I had same issue while I was start using VSCode. Well i took 3 hours to figure out what is exactly issue, I just stared with some step by step debugging like what port being used and what are the other settings.
Finally I was lucky and got the solutions :) So I created a page to share with everyone. You can check what is my findings and what you should need to setup to get Xdebug work with VSCode.
Link:
How-to-setup-PHP-Debugging-xdebug-with-VSCode-Visual-Studio-Code
Hope my experience would be helpful for someone. Cheers!!!