问题描述
我在使用 php7 和 Apache2 在 ElementaryOS (Ubuntu 16.04.2) 上运行 xdebug 时遇到了一些问题.
I'm having some problems getting xdebug running on ElementaryOS (Ubuntu 16.04.2) with php7, and Apache2.
我用 sudo apt-get install php-xdebug
安装了它.安装没有报告任何错误.我添加了
I installed it with sudo apt-get install php-xdebug
. The install didn't report any errors. I've added
xdebug.remote_enable=1
xdebug.remote_host=127.0.0.1
xdebug.remote_connect_back=1 ; Not safe for production servers
xdebug.remote_port=9000
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_autostart=true
到/etc/php/7.0/apache2/php.ini
.
我还需要添加 xdebug.so 文件位置,例如 zend_extension="/path/to/xdebug.so"
.但是,安装后我一直找不到xdebug.so.
I also need to add the xdebug.so file location like, zend_extension="/path/to/xdebug.so"
. However, I have been unable to find xdebug.so after the install.
有谁知道xdebug.so 在哪里,或者自php7.0 发布后说明有什么变化.大多数说明/帮助似乎都是针对 php5 在线的.
Does anyone know where xdebug.so is, or has the instructions changed since php7.0 was released. Most of the instructions/help seem to be for php5 online.
谢谢.
推荐答案
检查 xDebug 是否已安装.
Check xDebug is installed.
php -m
运行定位xdebug.so
为我返回 /usr/lib/php/20151012/xdebug.so
,但 20151012
将来可能会改变.
Returns /usr/lib/php/20151012/xdebug.so
for me, but 20151012
might change in the future.
如果 locate
没有返回任何东西或者你刚刚安装了 locate
You have to execute sudo updatedb
if locate
does not return anything or you've just installed locate
这篇关于在 linux 上找不到 xdebug.so的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!