What do I know about computers? I mean, really. So I build this rather big machine, to read along a couple of million weblogs. Needs storage. Sure. I get a 3ware raid controller. Works like a charm btw. There are more blogs, there is more spam, nothing surprising or new. The machine start to have a load of a solid 95-100%. Well, linux can deal with that, and it can. Today I tune another server, and look at parameters. One of them is the scheduler that is used to do the actual IO. The default for my kernel was anticipatory
. I changed that, so that
cat /sys/block/sda/queue/scheduler
reads now
noop anticipatory [deadline] cfq
And, what a surprise, the IO load starts to decline and the CPU is idle for 10-15% again! Of course this makes only sense on a server with lots of IO and database activity. That poor machine had to do stupid things for years.
As I said: what do I know about computers? Academic, yet interesting question would be how many CPU cycles are actually wasted on things like this, how many are needed?