dongroufan6846 2012-05-01 23:40
浏览 62
已采纳

在ubuntu服务器5.3.6-13ubuntu3.6上安装xdebug 2.1.4

I have tried to install xdebug on my ubuntu server machine and it's not working. The reason I know it's not working is that the output of var_dump is not colorized, nor can I connect to it using netbeans.

I followed the tailored instructions on how to install xdebug on

http://xdebug.org/wizard.php

Here is what the output of my phpinfo analysis was:

Xdebug installed: no
Server API: Apache 2.0 Handler
Windows: no
Zend Server: no
PHP Version: 5.3.6-13
Zend API nr: 220090626
PHP API nr: 20090626
Debug Build: no
Thread Safe Build: no
Configuration File Path: /etc/php5/apache2
Configuration File: /etc/php5/apache2/php.ini
Extensions directory: /usr/lib/php5/20090626

The name of the file that wizard recommended was xdebug-2.1.4.tgz

The output of phpize was

Configuring for:
PHP Api Version:         20090626
Zend Module Api No:      20090626
Zend Extension Api No:   220090626

My phpinfo now does show xdebug installed, here is how it looks like:

enter image description here

Here is what I have in my php.ini

zend_extension = /usr/lib/php5/20090626/xdebug.so
xdebug.profiler_output_dir = "/var/log/apache2/xdebug"
xdebug.profiler_output_name = "cachegrind.out.%p"
xdebug.profiler_enable =1
xdebug.profiler_append=1
xdebug.extended_info=1
xdebug.remote_enable=1
xdebug.remote_handler="dbgp"
xdebug.remote_mode=req
xdebug.remote_host=192.168.2.13
xdebug.remote_port=9000
;xdebug.idekey=xdebug
xdebug.idekey=netbeans-xdebug
xdebug.remote_connect_back=1
xdebug.remote_log="/var/log/apache2/xdebug_remote.log"
xdebug.show_exception_trace=0
xdebug.show_local_vars=9
xdebug.show_mem_delta=0

The output of lsb_release -a on my computer is

No LSB modules are available.
Distributor ID: Ubuntu
Description:    Ubuntu 11.10
Release:        11.10
Codename:       oneiric

PHP version shown on phpinfo is 5.3.6-13ubuntu3.6

  • 写回答

1条回答 默认 最新

  • duaabhuv188411 2012-05-02 09:14
    关注

    For the colours, you probably want to set html_errors=1 in php.ini as well.

    As for the netbeans issue (you really should not combine issues in one question!), which IP addresses do your machine running PHP, and which IP address does your machine running netbeans have? The xdebug.remote_host setting should contain the IP address of the one running netbeans. The remote log file that you're generating should have connection attempts in it too.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥15 做个有关计算的小程序
  • ¥15 MPI读取tif文件无法正常给各进程分配路径
  • ¥15 如何用MATLAB实现以下三个公式(有相互嵌套)
  • ¥30 关于#算法#的问题:运用EViews第九版本进行一系列计量经济学的时间数列数据回归分析预测问题 求各位帮我解答一下
  • ¥15 setInterval 页面闪烁,怎么解决
  • ¥15 如何让企业微信机器人实现消息汇总整合
  • ¥50 关于#ui#的问题:做yolov8的ui界面出现的问题
  • ¥15 如何用Python爬取各高校教师公开的教育和工作经历
  • ¥15 TLE9879QXA40 电机驱动
  • ¥20 对于工程问题的非线性数学模型进行线性化