合 WordPress网站更新插件报错502 Bad Gateway以及504 Gateway Time-out问题
Tags: 故障处理NginxwordpressPHP更新插件
现在
wordprss安装插件或者上传大文件时,总是时不时出现这个问题。
错误——502 Bad Gateway 502 Bad Gateway nginx
安装失败:
1 2 3 | 502 Bad Gateway 502 Bad Gateway nginx <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> 504 Gateway Time-out 504 Gateway Time-out nginx <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> <!-- a padding to disable MSIE and Chrome friendly error page --> |
若是导致网站不能访问,查看是否有/www/wwwroot/wordpress/.maintenance文件,若有,请删除:
1 | rm -rf /www/wwwroot/wordpress/.maintenance |
解决
步骤1:修改php配置文件php-fpm.conf
vi /www/server/php/74/etc/php-fpm.conf
修改 request_terminate_timeout = 600
upload_max_filesize = 100M
或者在宝塔面板直接修改: