Nginx 报错 413 Request Entity Too Large 的解决方法

报错信息

413 Request Entity Too Large

解决方法

修改 php 的配置文件 /etc/php5/fpm/php.ini

upload_max_filesize = 20M  
post_max_size = 20M

修改 Nginx 的配置文件

server {  
    ...  
    client_max_body_size 20m;  
    ...  
}

重启 Nginx 服务和 php-fpm 服务即可。


猜你喜欢

转载自blog.csdn.net/lamp_yang_3533/article/details/80428153