Phpstorm, XDebug, and DBGP Proxy

Source: Internet
Author: User

Phpstorm Configuring remote Debugging with Xdebug, Dbgp-proxy

1. Single-Client remote debugging

  

A. Installing the Xdebug library file (windows:php_xdebug.dll;linux:php_xdebug.so)

B. Modify PHP.ini (PHP source operating environment)

        ;Xdebug Library fileZend_extension = "D:/wamp/bin/php/php5.3.10/zend_ext/php_xdebug.dll";Turn on remote debuggingXdebug.remote_enable = on;Client IPxdebug.remote_host=localhost;Client Listening Portxdebug.remote_port=9000Xdebug.remote_handler=DBGP;Idekeyxdebug.idekey=Phpstorm xdebug.profiler_enable=off Xdebug.profiler_enable_trigger=off Xdebug.profiler_output_name=cachegrind.out.%t.%p Xdebug.profiler_output_dir= "D:/wamp/tmp"

C. Client (IDE Runtime Environment)

I. Configure PHP remote service, Phpstorm:file>settings>languages & Frameworks>php>servers

Apache Service: Where "Use path mappings" is used to map local code to remote service host code and then trace

II. Configuration Xdebug,phpstorm:file>settings>languages & Frameworks>php>debug

Debug Port: Default 9000, consistent with "Xdebug.remote_port"

III. Click "Edit Configurations" to select the server

IIII. Open the Monitor in Phpstorm, it's a phone-like button.

V. Turn on debug, the small button like the beetle (this opens a link and then injects the concatenated parameter Xdebug_session_start into Cookie:xdebug_session, which is unique

Flag an IDE)

2. Multi-Client remote debugging

  

A. On the remote service host, install Komodo remote debugging (http://code.activestate.com/komodo/remotedebugging/)

Start Pydbgpproxy.exe-i 0.0.0.0:9001-d 9000

Console output:

INFO:dbgp.proxy:starting proxy listeners. appid:10814
INFO:DBGP.PROXY:DBGP Listener on 127.0.0.1:9000
INFO:dbgp.proxy:IDE Listener on 0.0.0.0:9001

is successfully started

DBGP Proxy Server Listener 9000 communicates with remote Host service, IDE (Phpstorm) listens 9001 communicates with DBGP Proxy server

  

B. Installing the Xdebug library file (windows:php_xdebug.dll;linux:php_xdebug.so)

C. Modify PHP.ini (PHP source operating environment)

        ;Xdebug Library fileZend_extension = "D:/wamp/bin/php/php5.3.10/zend_ext/php_xdebug.dll";Turn on remote debuggingXdebug.remote_enable = on;DBGP PROXY Server host IPxdebug.remote_host=localhost;DBGP PROXY Server listener Portxdebug.remote_port=9000;AgentXdebug.remote_handler=DBGP;in this mode the item is not in effect and can be canceled        ;Xdebug.idekey=phpstormXdebug.profiler_enable =off Xdebug.profiler_enable_trigger=off Xdebug.profiler_output_name=cachegrind.out.%t.%p Xdebug.profiler_output_dir= "D:/wamp/tmp"

C. Client (IDE Runtime Environment)

I. Configure PHP remote service, Phpstorm:file>settings>languages & Frameworks>php>servers

Apache Service: Where "Use path mappings" is used to map local code to remote service host code and then trace

II. Configuration Xdebug,phpstorm:file>settings>languages & Frameworks>php>debug

Debug Port: Monitor 900x (where x is selected by itself), listen for external debug connections (communicates with DBGP proxy)

DBGP Proxy:

IDE key (IDE key, preferably not the same as other clients)

Host (DBGP Proxy server IP)

Port (DBGP Proxy server's listening port, consistent with-I 0.0.0.0:9001)

III. Inject the IDE's configuration into DBGP Proxy server

Click on the Toolbar "Tools" and select "Register IDE" to register (if the IDE is not configured, you can select "Configurations" to configure and then register)

IIII. Click "Edit Configurations" to select the server

V. Turn on the monitor in the Phpstorm is a phone-like button

VI. Open Debug, the small button like the beetle (this opens a link and then injects the concatenated parameter Xdebug_session_start into Cookie:xdebug_session, which is unique

Flag an IDE), modify the Xdebug_session_start parameter value to IDE Key

See also: http://matthardy.net/blog/configuring-phpstorm-xdebug-dbgp-proxy-settings-remote-debugging-multiple-users/

Http://wenku.baidu.com/link?url=ppL0e290lQSjle8jkI3Apaqvi5yYkv_kuSxl6SYnvwZFWPVMemRl8NrLO_ Qkmm6kunn1jbmmmbls5i4il5yw5ixi2kq0mfmcr1hl9uyigq3

Komodo Remote Debugging

Phpstorm, XDebug, and DBGP Proxy

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.