Re: mount -o async - is it safe?

Поиск
Список
Период
Сортировка
От Jim C. Nasby
Тема Re: mount -o async - is it safe?
Дата
Msg-id 20060119151518.GF78403@pervasive.com
обсуждение исходный текст
Ответ на Re: mount -o async - is it safe?  (Doug McNaught <doug@mcnaught.org>)
Список pgsql-general
On Thu, Jan 19, 2006 at 09:34:00AM -0500, Doug McNaught wrote:
> Shane Wright <shane.wright@edigitalresearch.com> writes:
>
> > Actually I thought that *all* the database had to have fsync() work correctly;
> > not for integrity on failed transactions, but to maintain integrity during
> > checkpointing as well.  But I could well be wrong!

You're correct; if the OS or drives lie about fsync'ing the base tables
during a checkpoint you can end up with a corrupted database. The only
'upside' here is that checkpoints don't happen as often, so the risk is
slightly less, but it's still there.

And all the debate about filesystem options is pointless unless they
have also turned off any unsafe write caching by the drives.

> I dimly recall this sort of thing being discussed in the past, but I
> don't know offhand whether PG does its WAL writes in small chunks or
> page-at-a-time.

It's done in pages, but remember that every commit requires an fsync of
WAL.
--
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461

В списке pgsql-general по дате отправления:

Предыдущее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: [HACKERS] No heap lookups on index
Следующее
От: Axel Straschil
Дата:
Сообщение: PostgreSQL - a ORDBMS?