Re: Does PostgreSQL use atomic file creation of FS?
От | Dmitry Lazurkin |
---|---|
Тема | Re: Does PostgreSQL use atomic file creation of FS? |
Дата | |
Msg-id | eb710719-3a2a-522a-39c9-2ebcdc24bb1b@gmail.com обсуждение исходный текст |
Ответ на | Re: Does PostgreSQL use atomic file creation of FS? (Karsten Hilbert <Karsten.Hilbert@gmx.net>) |
Ответы |
Re: Does PostgreSQL use atomic file creation of FS?
|
Список | pgsql-general |
Thank you. But I have read this. I said about network file system only for example. I would like to known how PostgreSQL handles this specific case (of course if someone knowns a answer): fd = open(file, "w"); write(fd, data); // crash and now I have empty file which isn't correct fsync(fd); PS. I think PostgreSQL doesn't have this problem. On 12/12/18 15:37, Karsten Hilbert wrote: > On Wed, Dec 12, 2018 at 02:48:12PM +0300, Dmitry Lazurkin wrote: > >> Does PostgreSQL use atomic file creation on FS? How does PostgreSQL >> catch situation when system crashes between open call and write call? I >> am interesting in this because I would like use PostgreSQL on network >> file system. > I doubt we can get more certainty than this: > > https://www.postgresql.org/docs/devel/creating-cluster.html#CREATING-CLUSTER-NFS > > Best, > Karsten
В списке pgsql-general по дате отправления: