Re: Poor desktop responsiveness with background I/O-operations

Mike Galbraith
2009-09-21T08:06:06Z

On Mon, 2009-09-21 at 09:48 +0200, Ulrich Lukas wrote:
> Hi and thanks for your reply!

Hi.

> Mike Galbraith wrote:
> > nicing a shell or the dd should (and does) help a LOT.
>
> If this is the only way to influence this, maybe the default settings
> for the niceness of interactive and non-interactive tasks are not the
> best choice. (Maybe a distribution problem in this case)

There is no knowledge in the CPU nor IO scheduler wrt interactive vs
non-interactive. I've tinkered many times with a SCHED_INTERACTIVE
class, but it's not at all an easy problem, so keeps landing on the
trash heap. I could ramble on _for ever_ about that subject, but it's
thankfully irrelevant to this thread ;-)

> > reads are sync, more heavily affected by seek latency than writes.
>
> But how does this explain the seconds-long delays?

Seek latencies are cumulative is my (wild arsed) theory.

> If an interactive process causes a lot of seeks because of reads/writes
> which "are sync", I see how this can greatly slow down otherwise
> pipelined write operations, but the other way around?

If you seek between tiny reads, the more little reads you do, the more
seeks hurt. Readahead is supposed to help, but.. the pain is there.

-Mike