Re: Cost of XLogInsert CRC calculations

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Simon Riggs <simon@2ndquadrant.com>
Cc: Greg Stark <gsstark@mit.edu>, Mark Cave-Ayland <m.cave-ayland@webbased.co.uk>, "'Manfred Koizar'" <mkoi-pg@aon.at>, "'Bruce Momjian'" <pgman@candle.pha.pa.us>, pgsql-hackers@postgresql.org
Date: 2005-06-01T02:36:29Z
Lists: pgsql-hackers
Simon Riggs <simon@2ndquadrant.com> writes:
> Hmmm. I seem to recall asking myself why xl_prev existed if it wasn't
> used, but passed that by. Damn.

I couldn't believe it'd been overlooked this long, either.  It's the
sort of thing that you assume got done the first time :-(

> PreAllocXLog was already a reason to have somebody prepare new xlog
> files ahead of them being used. Surely the right solution here is to
> have that agent prepare fresh/zeroed files prior to them being required.

Uh, why?  That doubles the amount of physical I/O required to maintain
the WAL, and AFAICS it doesn't really add any safety that we can't get
in a more intelligent fashion.

			regards, tom lane