wordpress - Azure 应用程序网关上的 504 网关超时导致 WordPress 插件更新错误
问题描述
我们的 WordPress 站点位于 Azure 应用程序网关 (WAF v2) 后面。当我们更新 WordPress 插件时,我们会收到以下错误:
Update failed: 504 Gateway Time-out 504 Gateway Time-out Microsoft-Azure-Application-Gateway/v2
<!-- 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 -->
查看 WAF 日志,使用以下查询,更新插件时没有活动。
AzureDiagnostics
| where ResourceType == "APPLICATIONGATEWAYS" and Category == "ApplicationGatewayFirewallLog" and action_s != "Allowed"
| project TimeGenerated, hostname_s, requestUri_s, clientIp_s, ruleSetType_s, ruleSetVersion_s, ruleId_s, action_s, Message, instanceId_s
我们已将时间设置Request time-out (seconds)
为 60 秒,但这没有任何效果。综上所述,插件似乎确实可以安装、更新和正常工作。
我们能做些什么来防止这个错误吗?
解决方案
最后,我只是将Request time-out (seconds)
时间增加到 120 秒。在此之后,我安装的每个插件都已正确安装且没有错误。
可以通过以下方式访问此设置:
- 应用防火墙。
- HTTP 设置。
- 您的 HTTP 设置。
- 请求超时(秒)。
推荐阅读
- amazon-iam - 调用 PutRolePolicy 操作时发生错误(ValidationError):policyDocument 的指定值无效
- ios - 为什么我不能更改 Timer.scheduledTimer 函数中变量的值?
- javascript - 循环删除和添加对象属性
- image - Android Studio - 将位图保存到图库不正确
- r - 如何通过分组合并行并仅在R中保留最高值
- cordova - 从 Cordova android 模拟器打印
- powershell - 需要使用 Powershell 向 Teams 发送 .csv
- ios - Swift 中的递归函数在使用大量输入调用时崩溃
- python - pandas 中的列表列(如果存在于另一个列表中)
- javascript - 谷歌脚本:设置自定义比例,导出为 PDF 时