I've been trying to figure out why our web servers have loads of 30-60+ and I
think I just found the culprit: rotatelogs.
Removing rotatelogs the load immediately dropped to 10 and hovered around
10-12. That's actually a reasonable level given my calculations about the
database latency and the number of processes we have.
Why would rotatelogs cause high cpu usage? Does the httpd spin waiting to
acquire some lock on the pipe? Or does the write fail and it keeps retrying?
I don't really believe either of these hypotheses though, and I've run strace
which of course doesn't help much.
Actually, I replaced the |rotatelogs with /dev/null. So it's possible it's
some other portion of the logging code. But it still seems wrong to me that it
would cause high cpu usage.
--
greg
think I just found the culprit: rotatelogs.
Removing rotatelogs the load immediately dropped to 10 and hovered around
10-12. That's actually a reasonable level given my calculations about the
database latency and the number of processes we have.
Why would rotatelogs cause high cpu usage? Does the httpd spin waiting to
acquire some lock on the pipe? Or does the write fail and it keeps retrying?
I don't really believe either of these hypotheses though, and I've run strace
which of course doesn't help much.
Actually, I replaced the |rotatelogs with /dev/null. So it's possible it's
some other portion of the logging code. But it still seems wrong to me that it
would cause high cpu usage.
--
greg