Re: WAL write of full pages - Mailing list pgsql-hackers

From Dennis Haney
Subject Re: WAL write of full pages
Date
Msg-id 40570BD8.1010906@diku.dk
Whole thread Raw
In response to WAL write of full pages  (Bruce Momjian <pgman@candle.pha.pa.us>)
Responses Re: WAL write of full pages  (Shridhar Daithankar <shridhar@frodo.hserus.net>)
List pgsql-hackers
Bruce Momjian wrote: <blockquote cite="mid200403151922.i2FJMWb18195@candle.pha.pa.us" type="cite"><pre wrap="">Our
currentWAL implementation writes copies of full pages to WAL before
 
modifying the page on disk.  This is done to prevent partial pages from
being corrupted in case the operating system crashes during a page
write.   </pre></blockquote> InnoDB uses a doublebuffer system instead.<br /><a class="moz-txt-link-freetext"
href="http://www.innodb.com/ibman.php#File.space.management">http://www.innodb.com/ibman.php#File.space.management</a><br
/><br/> quote:<br /><p>Starting from 3.23.40b, InnoDB uses a novel file flush technique called <q>doublewrite</q>. It
addssafety to crash recovery after an operating system crash or a power outage, and improves performance on most Unix
flavorsby reducing the need for <code class="c">fsync()</code> operations.<p>Doublewrite means that InnoDB before
writingpages to a data file first writes them to a contiguous tablespace area called the doublewrite buffer. Only after
thewrite and the flush to the doublewrite buffer has completed, InnoDB writes the pages to their proper positions in
thedata file. If the operating system crashes in the middle of a page write, InnoDB will in recovery find a good copy
ofthe page from the doublewrite buffer.<br /><br /><pre class="moz-signature" cols="72">-- 
 
Dennis
</pre>

pgsql-hackers by date:

Previous
From: Shridhar Daithankar
Date:
Subject: Re: WAL write of full pages
Next
From: Shridhar Daithankar
Date:
Subject: Re: WAL write of full pages