du7133 2012-11-20 17:32
浏览 50

Ubuntu / PHPStorm / Xdebug

I am unable to get xdebug working on PhpStorm under Ubuntu 12.10 and PHP5.4 It appears to me that everything is enabled, but the IDE does not stop at breakpoints. Below are the relevant parameters.

Can someone look at the parameters to see What I am missing? I am wondering if the xdebug.remote_enable needs to be on. I am debugging a local file. The server root and project paths are the same.

If I do need to change PHP54 xdebug parameters, where in the heck do I do that in ubuntu?

I added the following to /etc/php5/apache2/php.ini, restarted apache, but they seem to be ignored.

xdebug.remote_enable=1
xdebug.remote_port=9000
xdebug.remote_handler="dbgp"
xdebug.remote_host="localhost"

php - i output

/etc/php5/cli/conf.d/20-xdebug.ini
xdebug
xdebug support => enabled
xdebug.auto_trace => Off => Off
xdebug.cli_color => 0 => 0
xdebug.collect_assignments => Off => Off
xdebug.collect_includes => On => On
xdebug.collect_params => 0 => 0
xdebug.collect_return => Off => Off
xdebug.collect_vars => Off => Off
xdebug.coverage_enable => On => On
xdebug.default_enable => On => On
xdebug.dump.COOKIE => no value => no value
xdebug.dump.ENV => no value => no value
xdebug.dump.FILES => no value => no value
xdebug.dump.GET => no value => no value
xdebug.dump.POST => no value => no value
xdebug.dump.REQUEST => no value => no value
xdebug.dump.SERVER => no value => no value
xdebug.dump.SESSION => no value => no value
xdebug.dump_globals => On => On
xdebug.dump_once => On => On
xdebug.dump_undefined => Off => Off
xdebug.extended_info => On => On
xdebug.file_link_format => no value => no value
xdebug.idekey => no value => no value
xdebug.max_nesting_level => 100 => 100
xdebug.overload_var_dump => On => On
xdebug.profiler_aggregate => Off => Off
xdebug.profiler_append => Off => Off
xdebug.profiler_enable => Off => Off
xdebug.profiler_enable_trigger => Off => Off
xdebug.profiler_output_dir => /tmp => /tmp
xdebug.profiler_output_name => cachegrind.out.%p => cachegrind.out.%p
xdebug.remote_autostart => Off => Off
xdebug.remote_connect_back => Off => Off
xdebug.remote_cookie_expire_time => 3600 => 3600
xdebug.remote_enable => Off => Off
xdebug.remote_handler => dbgp => dbgp
xdebug.remote_host => localhost => localhost
xdebug.remote_log => no value => no value
xdebug.remote_mode => req => req
xdebug.remote_port => 9000 => 9000
xdebug.scream => Off => Off
xdebug.show_exception_trace => Off => Off
xdebug.show_local_vars => Off => Off
xdebug.show_mem_delta => Off => Off
xdebug.trace_enable_trigger => Off => Off
xdebug.trace_format => 0 => 0
xdebug.trace_options => 0 => 0
xdebug.trace_output_dir => /tmp => /tmp
xdebug.trace_output_name => trace.%c => trace.%c
xdebug.var_display_max_children => 128 => 128
xdebug.var_display_max_data => 512 => 512
xdebug.var_display_max_depth => 3 => 3
  • 写回答

2条回答 默认 最新

  • doubianxian6557 2012-11-22 09:14
    关注

    "php -i" on the command line uses a different php.ini file (/etc/php5/cli/php.ini) than apache does (/etc/php5/apache2/php.ini). Make sure you check phpinfo() through a browser to see whether xdebug.remote_enable has been set. phpinfo() output also tells you which INI files have been loaded, so check there as well.

    In general however, for extensions, you want to put configuration files for extensions in /etc/php5/mods-available - in this case, you would create /etc/php5/mods-available/xdebug.ini with just:

    xdebug.remote_enable=1
    

    in it. All the other settings should be left untouched (as they are default values anyway).

    评论

报告相同问题?

悬赏问题

  • ¥15 如何用Labview在myRIO上做LCD显示?(语言-开发语言)
  • ¥15 Vue3地图和异步函数使用
  • ¥15 C++ yoloV5改写遇到的问题
  • ¥20 win11修改中文用户名路径
  • ¥15 win2012磁盘空间不足,c盘正常,d盘无法写入
  • ¥15 用土力学知识进行土坡稳定性分析与挡土墙设计
  • ¥70 PlayWright在Java上连接CDP关联本地Chrome启动失败,貌似是Windows端口转发问题
  • ¥15 帮我写一个c++工程
  • ¥30 Eclipse官网打不开,官网首页进不去,显示无法访问此页面,求解决方法
  • ¥15 关于smbclient 库的使用