Re: Postgres, fsync, and OSs (specifically linux)

Поиск
Список
Период
Сортировка
От Craig Ringer
Тема Re: Postgres, fsync, and OSs (specifically linux)
Дата
Msg-id CAMsr+YGq5CdhTB_OScCraSf0__vk6nFVhpp6fONOfOZAZKG=rQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: Postgres, fsync, and OSs (specifically linux)  (Andres Freund <andres@anarazel.de>)
Ответы Re: Postgres, fsync, and OSs (specifically linux)  (Craig Ringer <craig@2ndquadrant.com>)
Список pgsql-hackers
> Not quite sure what you're getting at with "a file we don't fsync" - if
> we don't, we don't care about durability anyway, no? Or do you mean
> where we fsync in a different process?

Right.

> Either way, the answer is mostly no: On NFS et al where close() implies
> an fsync you'll get the error at that time, otherwise you'll get it at
> the next fsync().

Thanks.

The reason I ask is that if we got notified of already-detected
writeback errors (on 4.13+) on close() too, it'd narrow the window a
little for problems, since normal backends could PANIC if close() of a
persistent file raised EIO. Otherwise we're less likely to see the
error, since the checkpointer won't see it - it happened before the
checkpointer open()ed the file. It'd still be no help for dirty
writeback that happens after we close() in a user backend / the
bgwriter and before we re-open(), but it'd be nice if the kernel would
tell us on close() if it knows of a writeback error.

-- 
 Craig Ringer                   http://www.2ndQuadrant.com/
 PostgreSQL Development, 24x7 Support, Training & Services


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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: Postgres, fsync, and OSs (specifically linux)
Следующее
От: Thomas Munro
Дата:
Сообщение: Accounting of zero-filled buffers in EXPLAIN (BUFFERS)