From: | Greg Smith <gsmith(at)gregsmith(dot)com> |
---|---|
To: | Kyle Cordes <kyle(at)kylecordes(dot)com> |
Cc: | pgsql <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Decreasing WAL size effects |
Date: | 2008-10-30 21:10:08 |
Message-ID: | Pine.GSO.4.64.0810301657390.28733@westnet.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general pgsql-hackers |
On Thu, 30 Oct 2008, Kyle Cordes wrote:
> It sure would be nice if there was a way for PG itself to zero the unused
> portion of logs as they are completed, perhaps this will make it in as part
> of the ideas discussed on this list a while back to make a more "out of the
> box" log-ship mechanism?
The overhead of clearing out the whole thing is just large enough that it
can be disruptive on systems generating lots of WAL traffic, so you don't
want the main database processes bothering with that. A related fact is
that there is a noticable slowdown to clients that need a segment switch
on a newly initialized and fast system that has to create all its WAL
segments, compared to one that has been active long enough to only be
recycling them. That's why this sort of thing has been getting pushed
into the archive_command path; nothing performance-sensitive that can slow
down clients is happening there, so long as your server is powerful enough
to handle that in parallel with everything else going on.
Now, it would be possible to have that less sensitive archive code path
zero things out, but you'd need to introduce a way to note when it's been
done (so you don't do it for a segment twice) and a way to turn it off so
everybody doesn't go through that overhead (which probably means another
GUC). That's a bit much trouble to go through just for a feature with a
fairly limited use-case that can easily live outside of the engine
altogether.
--
* Greg Smith gsmith(at)gregsmith(dot)com http://www.gregsmith.com Baltimore, MD
From | Date | Subject | |
---|---|---|---|
Next Message | Kyle Cordes | 2008-10-30 21:16:43 | Re: Decreasing WAL size effects |
Previous Message | Berend Tober | 2008-10-30 21:05:46 | Re: Schema Upgrade Howto |
From | Date | Subject | |
---|---|---|---|
Next Message | Kyle Cordes | 2008-10-30 21:16:43 | Re: Decreasing WAL size effects |
Previous Message | Jason Long | 2008-10-30 20:51:18 | Re: Decreasing WAL size effects |