Bug #577
closedlighttpd terminally ceases serving connections when server.max-connections state reached
Description
With lighttpd 1.4.10 and server.max-connections=256 specified in lighttpd config, lighttpd ceased serving new connections (including server status page hits) when max connections was reached.
strace output of running process:
19:27:14.366461 epoll_wait(16, {}, 4087, 1000) = 0 19:27:15.366260 time(NULL) = 1142134035 19:27:15.366405 epoll_wait(16, {}, 4087, 1000) = 0 19:27:16.366213 time(NULL) = 1142134036 19:27:16.366365 epoll_wait(16, {}, 4087, 1000) = 0 19:27:17.366153 time(NULL) = 1142134037 19:27:17.366290 epoll_wait(16, {}, 4087, 1000) = 0 19:27:18.366251 time(NULL) = 1142134038 19:27:18.366433 epoll_wait(16, {}, 4087, 1000) = 0 19:27:19.366057 time(NULL) = 1142134039 19:27:19.366226 epoll_wait(16, {}, 4087, 1000) = 0 19:27:20.365993 time(NULL) = 1142134040 19:27:20.366137 epoll_wait(16, {}, 4087, 1000) = 0 19:27:21.366942 time(NULL) = 1142134041 19:27:21.367084 epoll_wait(16, {}, 4087, 1000) = 0 19:27:22.367893 time(NULL) = 1142134042 19:27:22.368064 epoll_wait(16, {}, 4087, 1000) = 0
error log data:
2006-03-11 19:14:02: (server.c.1218) [note] sockets disabled, connection limit reached 2006-03-11 19:17:03: (server.c.1126) NOTE: a request for [omitted] timed out after writing 18824 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle 2006-03-11 19:17:36: (server.c.1126) NOTE: a request for [omitted] timed out after writing 8305 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle
Server is still listening on ports and telnet to port succeeds, but no change in activity is shown in strace output. Commands entered via telnet ("GET /") receive no response from server.
-- moorman
Files
Updated by stbuehler over 17 years ago
Still there in 1.4.16; tested on a Debian system.
I think it just increases load; if you want you can try my patch below, it did stop the epoll_wait flooding on my system.
Updated by BamaStangGuy over 17 years ago
I am running into this as well.
2007-08-28 16:18:42: (server.c.1165) NOTE: a request for [omitted] timed out after writing 19488 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle 2007-08-28 16:23:07: (server.c.1165) NOTE: a request for [omitted] timed out after writing 8576 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle 2007-08-28 16:24:22: (server.c.1165) NOTE: a request for [omitted] timed out after writing 8576 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle 2007-08-28 16:25:29: (server.c.1165) NOTE: a request for [omitted] timed out after writing 15008 bytes. We waited 360 seconds. If this a problem increase server.max-write-idle
Lighty Config:
server.max-keep-alive-requests = 500 server.max-keep-alive-idle = 2 server.max-read-idle = 5 server.max-write-idle = 360 server.max-fds = 8192
Updated by Anonymous over 16 years ago
I am running into this problem on 1.4.19. I have not set server.max-connections in my config file; so presumably this is defaulting to 1024. It is not a particularly busy server and is running on very capable hardware.
I'm wondering why this patch hasn't been included in the main source? Is there something wrong with it? How should I tackle this problem - just increase server.max-connections? The load on my server is never above about 0.8, is it even likely i'm reaching server.max-connections?
Updated by stbuehler almost 16 years ago
- Status changed from New to Fixed
Applied in changeset r2387.
Also available in: Atom