pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Dmitry Lazurkin <dilaz03@gmail.com>
To: pgsql-general@lists.postgresql.org
Subject: Re: Does PostgreSQL use atomic file creation of FS?
Date: Wed, 12 Dec 2018 22:26:36 +0100
Message-ID: <c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at> (raw)
In-Reply-To: <f4703403-9c8e-6a21-a7cc-0e7137bdccdf@gmail.com>
References: <f4703403-9c8e-6a21-a7cc-0e7137bdccdf@gmail.com>

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.

If there is a crash, the file would be left behind.
This is slightly annoying, but shouldn't be a major problem.
Persisting such information in a crash-safe way would require
fsyncs that hurt I/O performance.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com





view thread (5+ messages)  latest in thread

Message-ID: <c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at>
Permalink:  ../c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at/
Also on:    postgresql.org/message-id/c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-general@postgresql.org
  Cc: laurenz.albe@cybertec.at, dilaz03@gmail.com
  Subject: Re: Does PostgreSQL use atomic file creation of FS?
  In-Reply-To: <c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at>
  References: <f4703403-9c8e-6a21-a7cc-0e7137bdccdf@gmail.com> <c2f14b0954fc276e5583d0f7dc940925575c86a3.camel@cybertec.at>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox