栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 系统运维 > 运维 > Linux

Xdebug延长调试时间

Linux 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

Xdebug延长调试时间

 因为我在phpstorm用xdebug调试时,没过多久就断掉然后出现500服务器错误的现象

解决办法

1. 打开apache的配置文件,在apacheconfhttpd.conf里修改

找到这一行并且把前面的注释去掉

Include conf/extra/httpd-default.conf

添加这一行
Include conf/extra/httpd-fcgid.conf

 2.在apacheconforiginalextrahttpd-default.conf里修改

直接在文档末尾处加上下面这段文字,具体时间可以自己修改

#xdebug:
# Timeout: The number of seconds before receives and sends time out.
#
Timeout 7200

#
# KeepAlive: Whether or not to allow persistent connections (more than
# one request per connection). Set to "Off" to deactivate.
#
KeepAlive On

#
# MaxKeepAliveRequests: The maximum number of requests to allow
# during a persistent connection. Set to 0 to allow an unlimited amount.
# We recommend you leave this number high, for maximum performance.
#
MaxKeepAliveRequests 0

#
# KeepAliveTimeout: Number of seconds to wait for the next request from the
# same client on the same connection.
#
KeepAliveTimeout 7200

3.在apacheconforiginalextra目录下新建一个httpd-fcgid.conf文件,这个就是我们刚才在配置文件加的,然后把下面的内容加进去

ProcessLifeTime 7200
FcgidIOTimeout 7200
FcgidConnectTimeout 7200
FcgidOutputBufferSize 128
FcgidMaxRequestsPerProcess 1000
FcgidMinProcessesPerClass 0 
FcgidMaxProcesses 16 
FcgidMaxRequestLen 268435456   
FcgidInitialEnv PHP_FCGI_MAX_REQUESTS 1000
IPCConnectTimeout 7200
IPCCommTimeout 7200
FcgidIdleTimeout 7200
FcgidBusyTimeout 60000
FcgidBusyScanInterval 120
FcgidInitialEnv PHPRC "D:phpstudy_proExtensionsphpphp7.4.3nts"        这里填写你自己php的路径
AddHandler fcgid-script .php

修改完apache记得重启一下!!

4.在php的配置文件php.ini里修改

找到这一行,修改成你配置的时间

max_execution_time=7200

配置完成,你可以快乐的调试了

转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/338847.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号