nginx上传文件超过限制大小、响应超时、反向代理请求超时等问题解决

1、文件大小超过限制

相关配置:

client_max_body_size:

|----------|----------------------------------|
| Syntax: | client_max_body_size size; |
| Default: | client_max_body_size 1m; |
| Context: | http, server, location |

2、连接超时:

proxy_read_timeout:

| Syntax: | proxy_read_timeout time; |
| Default: | proxy_read_timeout 60s; |

Context: http, server, location

定义从代理服务器读取响应的超时时间。超时仅在两个连续的读取操作之间设置,而不是针对整个响应的传输。如果代理服务器在此时间内没有传输任何内容,则连接将关闭。

fastcgi_connect_timeout:

| Syntax: | fastcgi_connect_timeout time; |
| Default: | fastcgi_connect_timeout 60s; |

Context: http, server, location

定义与FastCGI服务器建立连接的超时时间。应该注意,此超时通常不能超过75秒。

fastcgi_send_timeout:

| Syntax: | fastcgi_send_timeout time; |
| Default: | fastcgi_send_timeout 60s; |

Context: http, server, location

设置向FastCGI服务器传输请求的超时时间。超时仅在两个连续的写入操作之间设置,而不是针对整个请求的传输。如果FastCGI服务器在此时间内未收到任何内容,则连接将关闭。

fastcgi_read_timeout:

| Syntax: | fastcgi_read_timeout time; |
| Default: | fastcgi_read_timeout 60s; |

Context: http, server, location

定义从FastCGI服务器读取响应的超时时间。超时仅在两个连续的读取操作之间设置,而不是针对整个响应的传输。如果FastCGI服务器在此时间内没有传输任何内容,则连接将关闭。

相关推荐
代码游侠7 小时前
ARM开发——阶段问题综述(二)
运维·arm开发·笔记·单片机·嵌入式硬件·学习
Mr.朱鹏8 小时前
Nginx路由转发案例实战
java·运维·spring boot·nginx·spring·intellij-idea·jetty
java_logo8 小时前
OpenCode 企业级 Docker 部署完整指南
运维·docker·容器·opencode·opencode本地化部署·opencode部署手册·opencode部署方案
TTBIGDATA10 小时前
【knox】User: knox is not allowed to impersonate admin
大数据·运维·ambari·hdp·trino·knox·bigtop
佑白雪乐10 小时前
<Linux基础第10集>复习前面内容
linux·运维·服务器
春日见10 小时前
自动驾驶规划控制决策知识点扫盲
linux·运维·服务器·人工智能·机器学习·自动驾驶
玉树临风江流儿11 小时前
docker镜像加速器配置步骤
运维·docker·容器
China_Yanhy12 小时前
我的区块链运维日记 · 第 11 日:生死时速 —— 闪电贷攻击与“红色按钮”
运维·区块链
2401_8401922712 小时前
怎么把运维能力沉淀下来?
运维