kangle跑wp程序报504 upstream protocol header size is too big
upstream protocol header size is too bigheader不合法,通过调试模式查看
https://i.imgur.com/OBYbXT6.png
导致头超过了4M限制。
在wp程序中有独立配置开启了display_errors,把它关闭
或者直接修改警告的这个文件/wwwroot/wp-includes/functions.php 1618行
https://i.imgur.com/KniAKB5.png
把is_dir前面加一个@就关了警告
结果就是cpu 100%
好好研究下,肯定能找到wp的bug提交给wp官方修复
https://core.trac.wordpress.org/timeline
https://core.trac.wordpress.org/ticket/43417
Index: src/wp-includes/functions.php
===================================================================
--- src/wp-includes/functions.php
+++ src/wp-includes/functions.php
@@ -1680,6 +1680,10 @@ function wp_mkdir_p( $target ) {
// We need to find the permissions of the parent folder that exists and inherit that.
$target_parent = dirname( $target );
while ( '.' != $target_parent && ! is_dir( $target_parent ) ) {
+ // Infinite loop protection (see https://core.trac.wordpress.org/ticket/43417)
+ if ( dirname( $target_parent ) === $target_parent ) {
+ break;
+ }
$target_parent = dirname( $target_parent );
}
页:
[1]