Re: Running with fsync=off

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Running with fsync=off
Дата
Msg-id 20051222080759.GB21783@svana.org
обсуждение исходный текст
Ответ на Running with fsync=off  (Benjamin Arai <barai@cs.ucr.edu>)
Ответы Re: [ADMIN] Running with fsync=off  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-general
On Wed, Dec 21, 2005 at 11:30:15PM -0800, Benjamin Arai wrote:
> I want to be able to do large updates on an existing backed up database
> with fsync=off but at the end of the updates how do I ensure that the
> data gets synced?

Do you know if that actually makes it much faster? Maybe you're better
off splitting WAL into a seperate disk.

> Somebody said running "sync ; sync; sync" from the console.  This seems
> reasonable but why not just "sync" or is there another command I should
> ruyn after the update either in postgres or the console?

The reason is partly historical. On some OSes running sync only starts
the process but returns immediatly. However, there can only be one sync
at a time so the second sync waits for the first the finish. The third
is just for show. However, on Linux at least the one sync is enough.

Don't you need to restart postgres to change that parameter anyway?

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> Patent. n. Genius is 5% inspiration and 95% perspiration. A patent is a
> tool for doing 5% of the work and then sitting around waiting for someone
> else to do the other 95% so you can sue them.

Вложения

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

Предыдущее
От: Richard Huxton
Дата:
Сообщение: Re: Funky template1 problem?
Следующее
От: John Sidney-Woollett
Дата:
Сообщение: Mem usage/leak - advice needed