AI摘要
修改nginx配置文件,将client_max_body_size设为512M并重启服务,即可支持上传小于512M的文件。
1)首先打开配置文件
vim /etc/nginx/nginx.conf
2)在http{}里面添加下面配置
# set client body size to 2M #
client_max_body_size 512M;
3)重启nginx
sudo systemctl restart nginx
这样就可以正常上传小于512M的文件了。

暂无评论
要发表评论,您必须先 登录