module | 指令 | 默认 | 作用域 | 说明 |
---|---|---|---|---|
ngx_http_core_module
|
client_body_timeout |
60s |
http, server, location |
定义读取客户端请求正文的超时。超时是指相邻两次读操作之间的最大时间间隔,而不是整个请求正文完成传输的最大时间。 如果客户端在这段时间内没有传输任何数据,nginx将返回408 (Request Time-out)错误到客户端。 |
client_header_timeout |
60s |
http, server |
定义读取客户端请求头部的超时。如果客户端在这段时间内没有传送完整的头部到nginx, nginx将返回错误408 (Request Time-out)到客户端。 |
|
keepalive_timeout |
75s |
http, server, location |
设置客户端的长连接在服务器端保持的最长时间 |
|
lingering_time |
30s |
http, server, location |
lingering_close生效时,这条指令定义nginx处理(读取但忽略)客户端额外数据的最长时间。 超过这段时间后,nginx将关闭连接,不论是否还有更多数据待处理。 |
|
lingering_timeout |
5s |
http, server, location |
lingering_close生效时,这条指令定义nginx等待客户端更多数据到来的最长时间。 如果在这段时间内,nginx没有接收到数据,nginx将关闭连接。否则,nginx将接收数据,忽略它,然后再等待更多数据。 这个“等待——接收——忽略”的循环一直重复,但总时间不会超过lingering_time指令定义的时间。 |
|
resolver_timeout |
30s |
http, server, location |
为名字解析设置超时 |
|
send_timeout |
60s |
http, server, location |
设置向客户端传输响应的超时。超时仅指两次相邻写操作之间的时间间隔,而非整个响应的传输时间。 如果客户端在这段时间中没有收到任何数据,连接将关闭。 |
|
ngx_http_ssl_module |
ssl_session_timeout |
5m |
http, server |
指定一个时间,在此期间客户端可以重复使用存储在一个高速缓存中的会话参数。 |
ngx_http_proxy_module
|
proxy_cache_lock_timeout |
5s |
http, server, location |
为proxy_cache_lock指令设置锁的超时。 |
proxy_connect_timeout |
60s |
http, server, location |
设置与后端服务器建立连接的超时时间。应该注意这个超时一般不可能大于75秒。 |
|
proxy_read_timeout |
60s |
http, server, location |
定义从后端服务器读取响应的超时。此超时是指相邻两次读操作之间的最长时间间隔,而不是整个响应传输完成的最长时间。如果后端服务器在超时时间段内没有传输任何数据,连接将被关闭。 |
|
proxy_send_timeout |
60s |
http, server, location |
定义向后端服务器传输请求的超时。此超时是指相邻两次写操作之间的最长时间间隔,而不是整个请求传输完成的最长时间。如果后端服务器在超时时间段内没有接收到任何数据,连接将被关闭。 |
|
ngx_http_fastcgi_module
|
fastcgi_cache_lock_timeout |
5s |
http, server, location |
为fastcgi_cache_lock指令设置锁的超时。 |
fastcgi_connect_timeout |
60s |
http, server, location |
设置与fastcgi服务器建立连接的超时时间。应该注意这个超时一般不可能大于75秒。 |
|
fastcgi_read_timeout |
60s |
http, server, location |
定义从fastcgi服务器读取响应的超时。此超时是指相邻两次读操作之间的最长时间间隔,而不是整个响应传输完成的最长时间。如果fastcgi服务器在超时时间段内没有传输任何数据,连接将被关闭。 |
|
fastcgi_send_timeout |
60s |
http, server, location |
定义向fastcgi服务器传输请求的超时。此超时是指相邻两次写操作之间的最长时间间隔,而不是整个请求传输完成的最长时间。如果fastcgi服务器在超时时间段内没有接收到任何数据,连接将被关闭。 |
常用nginx超时参数
猜你喜欢
转载自blog.51cto.com/tenderrain/2141115
今日推荐
周排行