Re: Some thoughts about i/o priorities and throttling vacuum

From: Greg Stark <gsstark(at)mit(dot)edu>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Some thoughts about i/o priorities and throttling vacuum
Date: 2003-10-16 20:16:10
Message-ID: 87k7759bw5.fsf@stark.dyndns.tv
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us> writes:

> Of course, this makes VACUUM run longer, and if you are waiting for it
> to finish, it would be worse, like if you are running it at night or
> something.

My plan was that the time delay would be a parameter and pg_autovacuum would
set it based on the observed rate at which free space is accumulating.

Someone could manually specify a delay, but by default it would run with no
delay when run on the command line.

> I think the delay has to take into account the number of active
> transactions or something.

That's a possibility. That's actually what the linux-kernel folk suggested.
Someone there suggested using aio to do carefully schedule i/o only when no
i/o was pending from transactions.

But vacuum has no way to judge whether those transactions are really doing
much disk i/o or only reading cached blocks, or even whether the disk i/o
they're doing is on the same disk. They could also be waiting on the client or
on locks from other transactions.

--
greg

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2003-10-16 20:38:01 Bison 1.875 for SuSE Linux 8.1?
Previous Message Bruce Momjian 2003-10-16 18:54:06 Re: Still a few flaws in configure's default CFLAGS selection