pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Michael Paquier <michael.paquier@gmail.com>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: kunschikov@gmail.com, PostgreSQL mailing lists <pgsql-bugs@postgresql.org>
Subject: Re: BUG #13888: pg_dump write error
Date: Tue, 26 Jan 2016 09:35:54 -0500
Message-ID: <40312.1453818954@sss.pgh.pa.us> (raw)
In-Reply-To: <CAB7nPqRsARVk_5T3pks3KEc+yusSdOirFNFzUiYPiG4KJDJPEA@mail.gmail.com>
References: <20160125143008.2539.2878@wrigleys.postgresql.org>
	<20160125160840.GA510163@alvherre.pgsql>
	<CAB7nPqRsARVk_5T3pks3KEc+yusSdOirFNFzUiYPiG4KJDJPEA@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

Michael Paquier <michael.paquier@gmail.com> writes:
> On Tue, Jan 26, 2016 at 1:08 AM, Alvaro Herrera
> <alvherre@2ndquadrant.com> wrote:
>> Yeah, I noticed this and similar lacks of error checks in pg_dump in
>> code review, which I didn't get around to patching.  Care to submit a
>> patch?

> Indeed, with a closer look there are things like tarWrite that can
> return 0 and trigger WRITE_ERROR_EXIT with the same thing. Couldn't we
> simply check for errno = 0 and generate a more generic error message
> instead? Or are you willing at replacing all those things with just
> exit_horribly()?

I do not understand these claims that there isn't an error check there.
There surely is.  But fwrite() didn't set errno.

The real question is why did he get a short write in the first place.
We don't make any attempt to support filesystems that require retries,
which seems to be what is going on here.  Should we?

			regards, tom lane


-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs



view thread (11+ messages)  latest in thread

Message-ID: <40312.1453818954@sss.pgh.pa.us>
Permalink:  ../40312.1453818954@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/40312.1453818954@sss.pgh.pa.us

 · 

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-bugs@postgresql.org
  Cc: tgl@sss.pgh.pa.us, michael.paquier@gmail.com, alvherre@2ndquadrant.com
  Subject: Re: BUG #13888: pg_dump write error
  In-Reply-To: <40312.1453818954@sss.pgh.pa.us>
  References: <20160125143008.2539.2878@wrigleys.postgresql.org> <20160125160840.GA510163@alvherre.pgsql> <CAB7nPqRsARVk_5T3pks3KEc+yusSdOirFNFzUiYPiG4KJDJPEA@mail.gmail.com> <40312.1453818954@sss.pgh.pa.us>

* 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