PHPStorm, Xdebug and remote debugging (using FTP in phpstorm)

First of all:

  • Apache server runs on Ubuntu on SunVirtualBox x86
  • Debug Server - XDebug
  • Files are uploaded from FTP using phpstorm

PHP version

PHP 5.4.9-4ubuntu2.4 (cli) (built: Dec 12 2013 04:26:30) Copyright (c) 1997-2012 The PHP Group Zend Engine v2.4.0, Copyright (c) 1998-2012 Zend Technologies with Xdebug v2.2.1, Copyright (c) 2002-2012, by Derick Rethans 

Important: XDebug is configured correctly because everything works on my localhost.

enter image description here

But I just canโ€™t set up remote debugging, here are all the images and steps that I took, PLEASE HELP and advise me.

Step 1 - The main click to create a new project from existing files.

Step1

Step 2 - select FTP

Step2

Step 3 - project settings in the file system

Step 3

Step 4 - Configure FTP Connection and Advanced - Passive Mode

Setting FTP connection and Advanced - Passive mode

Step 5 Run / debug configuration, select Remote PHP debug file and enter the Ide key: PHPSTORM

Run / Debug configuration

Step 6 - servers and checking the remote environment, the WARNING pops up here : the debug extension is not loaded

Servers and validate remote enviroment

Step 7 - Configure Php ini.

Php ini configuration.

So in the end.

1) Is there anything I had to do on the remote server from my client for this to work? Maybe installing XDEBUG, maybe you will find these questions silly, believe me, I lost 3 days in this and I'm a little disappointed when talking about renting. so please help.

2) I will gladly upload more screenshots or answer any question you have to help me. I know that this is something simple, but I rack my brains over it.

Help again, I went through, of course, 15 pages on remote debugging in PHPSTROM, and all of them were just not accurate enough. As you can see in the first photos, everything works fine on my localhost.

+7
php phpstorm xdebug ftp remote-debugging
source share
2 answers

The main difference between using XDebug on your local computer and using XDebug with a remote system is that you need to configure two things:

1) xdebug.remote_host on your server outside of your network will be YOUR IP ADDRESS, just like what you get if you go to whatismyip.com. This IP address is subject to change. (You can use dynamic DNS from specific providers and the host name instead of IP if your home IP address changes a lot). In any case, when XDebug starts on a remote server, it becomes a CUSTOMER who is looking for YOUR XDEBUG SERVER running on your laptop on port 9000.

This is what confuses so many XDebug users. This leads to the following:

2) You must edit your home / office firewall (presumably this is a traffic call by IP address that you entered in xdebug.ini or php.ini in step 1) in order to redirect incoming traffic to port 9000 to your IP laptop in your home / office network.

The best resource about this (IMO) is here: http://matthardy.net/blog/configuring-phpstorm-xdebug-dbgp-proxy-settings-remote-debugging-multiple-users/

+2
source share

You must set the debubugger port to 9000 in remotedebug, as you have in php.ini.

-one
source share

All Articles