Re: 8192 BLCKSZ ?
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-hackers@postgresql.org
Date: 2000-11-28T21:24:34Z
Lists: pgsql-hackers
Nathan Myers <ncm@zembu.com> writes: > In the event of a power outage, the drive will stop writing in > mid-sector. Really? Any competent drive firmware designer would've made sure that can't happen. The drive has to detect power loss well before it actually loses control of its actuators, because it's got to move the heads to the safe landing zone. If it checks for power loss and starts that shutdown process between sector writes, never in the middle of one, voila: atomic writes. Of course, there's still no guarantee if you get a hardware failure or sector write failure (recovery from the write failure might well take longer than the drive has got). But guarding against a plain power-failure scenario is actually simpler than doing it the wrong way. But, as you say, customary page sizes are bigger than a sector, so this is all moot for our purposes anyway :-( regards, tom lane