[PATCH][CFT] new IO scheduler for 2.4.20

From: Neil Schemenauer (nas@arctrix.com)
Date: Thu Apr 17 2003 - 12:28:19 EST


Hi all,

Recently I was bitten badly by bad IO scheduler behavior on an important
Linux server. An easy way to trigger this problem is to start a
streaming write process:

    while :
    do
            dd if=/dev/zero of=foo bs=1M count=512 conv=notrunc
    done

and then try doing a bunch of small reads:

    time (find kernel-tree -type f | xargs cat > /dev/null)

With Linux 2.4.20, the reading takes a very long time to finish. I
looked at backporting Jen's deadline scheduler to 2.4 but decided it
would be too much work (especially for someone like me who doesn't know
much about kernel hacking).

I've come up with a fairly simple patch that seems to solve the
starvation problem. Perhaps it is simple enough to get merged into the
stable branch (after a little more polish). The basic idea is to give
reads a boost if there are lots of write requests in the queue. I think
my solution also prevents reads and writes from being starved
indefinitely.

Throughput also seems good although I have not done a lot of testing
yet. I would greatly appreciate it if people could give it a test.

  Neil



-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Wed Apr 23 2003 - 22:00:22 EST