Configure xdebug for php storm - can't validate

Answered

I can't configure xdebug  remote properly.
My local machine, where I use PHPstorm is win10 and ip 192.168.1.16
My server is running on ubuntu 16.10 and ip 192.168.1.235

I have used remote deployment configuration with success for a month, but I miss debugger. Mappings are set correctly.

 

My interpreter:

Xdebug settings (settings>Languages...>PHP>Debug) are left at default, port 9000

Php.ini: (for php/7.0/cli/php.ini and the same for apache)


Validation script:


I have followed your tutorial   till this validation script and now I don't know what next. Debugging doesn't work. I even dont have debugging configuration set up.

 

 

0
6 comments

xdebug 2.5 isn't officially supported yet. Please try to revert to 2.4.1

0
Avatar
Permanently deleted user

It doesn't help. I must have done something wrong.

0

On this step:

please click on "..." button against deployment server > then go to Mapping tab and doublecheck paths entered there.

0
Avatar
Permanently deleted user

Local Path is : D:\PhpstormProjects\DashBoard

Deployment path is: /var/www/portfolio/projects/dashboard

Web path is: /projects/dashboard

ProjectULR : https://192.168.1.235/projects/dashboard

0

Mike, you are doing everything right, but the server replies with 401 - unauthorized.
(Path to create validation script should be local though, the script is copied to the remote side by a deployment configuration)
It means that authentication is required to connect to your web server, and we don't support that in Web Server Debug Validation: https://youtrack.jetbrains.com/issue/WI-31423

I suggest that you ignore the validation tool and try to debug despite the fact that you can't validate.
First, you need to add the xdebug.remote_host parameter to php.ini as currently Xdebug doesn't know where it should send the debug data. It should be an IP of your physical machine where PhpStorm is running.
Next, follow this guide: https://confluence.jetbrains.com/display/PhpStorm/Zero-configuration+Web+Application+Debugging+with+Xdebug+and+PhpStorm

If debugging doesn't work, please describe the steps you've done to start it.

0
Avatar
Permanently deleted user

Thank you very much. Adding xdebug.remote_host=192.168.1.16 helped.

I couldn't find what 401 mean.

That validation script once worked for me on similar configuration. I don't remember now what settings I had but it worked. Maybe that was something in php.ini. Thanks again

0

Please sign in to leave a comment.