Re: High load average on disk I/O on 2.6.17-rc3

From: Martin J. Bligh
Date: Mon May 08 2006 - 12:01:48 EST


Erik Mouw wrote:
On Mon, May 08, 2006 at 05:31:29PM +0200, Arjan van de Ven wrote:

On Mon, 2006-05-08 at 17:22 +0200, Erik Mouw wrote:

... except that any kernel < 2.6 didn't account tasks waiting for disk
IO.

they did. It was "D" state, which counted into load average.


They did not or at least to a much lesser extent. That's the reason why
ZenIV.linux.org.uk had a mail DoS during the last FC release and why we
see load average questions on lkml.

I've seen it on our servers as well: when using 2.4 and doing 50 MB/s
to disk (through NFS), the load just was slightly above 0. When we
switched the servers to 2.6 it went to ~16 for the same disk usage.

Looks like both count it, or something stranger is going on.

2.6.16:

static unsigned long count_active_tasks(void)
{
return (nr_running() + nr_uninterruptible()) * FIXED_1;
}

2.4.0:

static unsigned long count_active_tasks(void)
{
struct task_struct *p;
unsigned long nr = 0;

read_lock(&tasklist_lock);
for_each_task(p) {
if ((p->state == TASK_RUNNING ||
(p->state & TASK_UNINTERRUPTIBLE)))
nr += FIXED_1;
}
read_unlock(&tasklist_lock);
return nr;
}

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