Project

General

Profile

empty response body but http status 200 reported

Added by dannynoonan over 14 years ago

I'm having issues where lighttpd logs a 200 for both GET and POST requests, but the body length logged shows a 0 or '-'. This is pretty hard to duplicate as it only occurs less than 1/sec on servers that perform up to 200 requests/sec.

I've tried to correlate the occurrences with load, but it's hard to prove causation if an increased number of requests increases this empty 200 occurrence.

I've tried gthread-aio, enabled log_timing and gnuplotted the various stages of the gthread, but I'm not sure it's telling me anything useful -just that all time spent on requests are in 'write'.

Our long-standing configuration has been max-workers = 25, but I've been fighting to move back to a single process since my involvement in the project. This empty 200 manifests itself with max-worker = 0, 4, 8, 25...so that's not related I think.

Any help would be much appreciated. My boss has been able to reduce the occurrences in the log files by reverse proxying haproxy to 5 separate instances of lighttpd on the same machine, but all 5 processes are writing to the log file...so consider adopting this approach an intellectual fail. Am I misinformed to think that simply round-robining connections from 1 process to 5 others should not be as efficient as a single, event-driven process with a threaded read pool?

Anyway, sorry for rambling. We've been following a somewhat weak assumption that a lack of available CPU and high number of context switches causes this problem and so our goal has been to reduce CPU footprint and context switching. Can anybody point me in a more informed direction?

most of the traffic is rapid, small-file transfer of images. a small subset of the traffic is dynamic php across a fast-cgi socket.

lighttpd is version 1.5.0 compiled from an svn checkout back in March. Fedora 5,6,7,8 machines all exude this problem.

I can try out a stable 1.4.x version if that is helpful.