我似乎无法让 Apache 2.4 加载我的xdebug配置。我已经添加:
zend_extension=xdebug.so
remote_enable=on
Run Code Online (Sandbox Code Playgroud)
到/etc/php5/apache2/conf.d/20-xdebug.ini。
根据phpinfo()该文件确实被解析,但remote_enable仍然关闭。
我在日志中没有看到任何错误。我还可能缺少什么?
我有一个 php 版本7.1.1,phpize我按照https://xdebug.org/wizard.php的说明安装的是这样的,
Configuring for:
PHP Api Version: 20151012
Zend Module Api No: 20151012
Zend Extension Api No: 320151012
Run Code Online (Sandbox Code Playgroud)
当我搜索这个时,它是为了 php 7.0
有什么办法可以改变这个吗?我按照此说明https://xdebug.org/docs/faq#custom-phpize但仍然无法正常工作。
我尝试xdebug在 Ubuntu 14.04 中安装,但是当我执行以下命令时:
sudo pecl install xdebug
Run Code Online (Sandbox Code Playgroud)
它返回错误:
Download of "pecl/xdebug" succeeded, but it is not a valid package archive
Run Code Online (Sandbox Code Playgroud)
有人遇到过同样的问题或知道如何解决吗?
谢谢
我正进入(状态
fatal error maximum function nesting level of '100' reached aborting..
Run Code Online (Sandbox Code Playgroud)
看来我必须编辑
xdebug.max_nesting_level from 100 to more.
Run Code Online (Sandbox Code Playgroud)
但是我无法在应该编辑的地方找到正确的文件?我正在使用 Ubuntu 14.04、lighttpd 网络服务器和 PHP ..
从互联网上我看到我必须编辑 /etc/php5/apache2 中的 php.ini 文件。
但我正在使用 lighttpd。
在我的 /etc/php5/ 中有三个文件夹,即
在 cgi 和 cli 文件夹中有 php.ini 文件,但这两个文件不包含任何编辑 xdebug 的文件。
在 mods-available 文件夹中,我得到了 1 个文件,即 xdebug.ini,它只包含
zend_extension=xdebug.so
Run Code Online (Sandbox Code Playgroud)
所以我需要帮助如何在 ubuntu 14.04 PHP 和 Lighttpd 中编辑 xdebug.max_nesting_level。对不起,我的英语不好。寻求您的帮助来解决这个问题
我正在尝试使用 PHP 5 在 Ubuntu 16 中安装 xdebug,但它失败了。我使用的命令是:
sudo pecl install xdebug
Run Code Online (Sandbox Code Playgroud)
我在论坛上搜索了很多,但找不到这个原因。有人可以帮我解决这个问题吗?
以下是控制台输出错误:
downloading xdebug-2.4.0.tgz ...
Starting to download xdebug-2.4.0.tgz (264,832 bytes)
......................................................done: 264,832 bytes
76 source files, building
running: phpize
Configuring for:
PHP Api Version: 20131106
Zend Module Api No: 20131226
Zend Extension Api No: 220131226
cp: cannot stat 'ltmain.sh': No such file or directory
building in /tmp/pear/temp/pear-build-roottZWTLj/xdebug-2.4.0
running: /tmp/pear/temp/xdebug/configure --with-php-config=/usr/bin/php-config
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking for …Run Code Online (Sandbox Code Playgroud) 我不记得 xdebug 是如何启用的,但我发现/etc/php/7.0/mods-availablexdebug在目录中被列为xdebug.ini.
如果我转到该目录,/etc/php/7.0/apache2/conf.d则那里有一个指向 xdebug.ini 文件的符号链接,该符号链接名为20-xdebug.ini.
xdebug.ini 的内容为:
zend_extension=xdebug.so
Run Code Online (Sandbox Code Playgroud)
xdebug 正在工作,但因为我大部分时间都被它惹恼了,我想我可以把它关掉:
sudo a2dismod xdebug
Run Code Online (Sandbox Code Playgroud)
但是那个命令对我咆哮,“错误:模块 xdebug 不存在!”。我希望随时可以方便地关闭和打开 xdebug,所以我的问题是:
我知道我可以进去注释掉该行,然后重新启动 apache,但是我需要懒人的解决方案,如果有的话。
我已经在 v3.0.1 版本中安装了 xdebug,但它导致我在 php7.2 和我的 symfony 安装中出现问题。我现在无法升级 php 版本,所以我需要将 xdebug 版本降级到预览版(2.* 中的任何一个)我尝试过类似:sudo apt install php-xdebug=2.9.8-7.2-vc15-nts和其他一些组合,但没有任何效果。
如何降级 xdebug 版本?