沃梦达 / 编程问答 / php问题 / 正文

一步一步:如何进行 Xdebug 故障排除连接到客户端 IDE

Step-by-step: How to do Xdebug troubleshooting connection to client IDE(一步一步:如何进行 Xdebug 故障排除连接到客户端 IDE)

本文介绍了一步一步:如何进行 Xdebug 故障排除连接到客户端 IDE的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

背景

将 Xdebug 与 PHP 和 Komodo IDE 以及 Eclipse PDT 结合使用.

Using Xdebug with PHP and Komodo IDE, and Eclipse PDT.

Xdebug 已安装在服务器上并正常工作.这得到证实,因为 Xdebug 代码命令在插入服务器上的 PHP 文件时按预期工作.

Xdebug is installed on the server and working properly. This is confirmed because the Xdebug code commands work as expected when inserted into PHP files on the server.

问题

无法连接到客户端工作站,并且很难确定原因,因为它使用多个 IDE 失败.

Connecting to the client workstation is not working, and it is difficult to determine why because it fails with multiple IDEs.

问题

如果您知道 Xdebug 已安装并在服务器上运行,但客户端无法连接,则最好有一个分步清单来解决问题.

It would be nice to have a step-by-step checklist to troubleshoot the case where you know Xdebug is installed and working on the server, but the client does not connect.

任何人都可以帮助添加此内容以制作全面的故障排除清单吗?

Can anyone help add to this to make a comprehensive troubleshooting checklist?

具体来说,是否有任何简单的方法来确保网络流量到达客户端,并且按照 IDE 期望查看数据的方式正确格式化?

Specifically, is there any bare-bones way to make sure the network traffic is reaching the client, and is correctly formatted in the way the IDE expects to see the data?

  • SSH 进入网络主机并尝试访问客户端:

  • SSH into web host and try to reach the client:

  • 主机可以访问客户端吗?(ping -c 5 xxx.xxx.xxx.xxx)
  • 主机可以访问端口 9000 吗?(nmap -p 9000 xxx.xxx.xxx.xxx)
  • 如果以上两个都成功了,输出应该是什么?
  • 如果以上两个都失败了,接下来的故障排除步骤是什么?

验证客户端软件防火墙的设置

Verify settings of software-based firewall on client

目标

目标是找到一些解决方案,让客户端机器上的人至少可以确认某物正在到达客户端,而不必确定 IDE 是否是问题所在,因为 IDE 是另一个级别可能会带来问题的复杂性.

The goal is to find some solution where the person on the client machine can at least confirm that something is reaching the client without having to determine whether the IDE is the problem, since IDE is another level of complexity that may be introducing problems.

推荐答案

这是我肯定希望包含在 Xdebug 文档中的内容.我认为最好让很多人在这方面进行合作,所以我在 xdebug.org github 存储库中创建了一个文件(https://github.com/derickr/xdebug.org/blob/master/html/docs/tutorials/troubleshooting.rest)收集提示.随意分叉和扩展!

This is something I would definitely want to include in the Xdebug documentation. I think it would work best to have many people collaborate on this, so I've created a file in the xdebug.org github repository (https://github.com/derickr/xdebug.org/blob/master/html/docs/tutorials/troubleshooting.rest) to collect tips. Feel free to fork and extend!

在 Xdebug 方面,在即将发布的版本 (2.2) 中,它已经在其 xdebug.remote_log 文件中转储了一些额外的诊断信息,例如它是否尝试连接以及连接是被接受还是被拒绝.

On the Xdebug side, in the upcoming version (2.2) it already dumps in its xdebug.remote_log file a couple of extra diagnostics such as whether it tried to connect and whether the connection was accepted or denied.

这篇关于一步一步:如何进行 Xdebug 故障排除连接到客户端 IDE的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持编程学习网!

本文标题为:一步一步:如何进行 Xdebug 故障排除连接到客户端 IDE