Re: pg_restore fails

From: Karsten Hilbert <Karsten(dot)Hilbert(at)gmx(dot)net>
To: pgsql-general(at)postgresql(dot)org
Subject: Re: pg_restore fails
Date: 2016-03-13 00:01:16
Message-ID: 20160313000116.GD11080@hermes.hilbert.loc
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sun, Mar 13, 2016 at 12:37:02AM +0100, Karsten Hilbert wrote:

> > > pg_restore: [Archivierer (DB)] Fehler in Phase PROCESSING TOC:
> > > pg_restore: [Archivierer (DB)] Fehler in Inhaltsverzeichniseintrag 8; 2615 2200 SCHEMA public postgres
> > > pg_restore: [Archivierer (DB)] could not execute query: FEHLER: Schema „public“ existiert bereits
> > > Die Anweisung war: CREATE SCHEMA public;
> > >
> > >I am sure I am doing something wrong, but what ?
> >
> > Did it actually fail or did it just throw an error?
> > In other words did the restore continue past the error?
>
> Good question. I'll remove the --exit-on-error and retry :-)

It actually went through with the last line saying

WARNING: 1 error during restor was ignored

pg_restore does not return exit code 0 anymore, however, and
offhand I can't find documentation as to whether pg_restore
returns different error codes between success and
success-with-ignored-errors. It does not seem to return 0
when it "ignores" errors.

Karsten
--
GPG key ID E4071346 @ eu.pool.sks-keyservers.net
E167 67FD A291 2BEA 73BD 4537 78B9 A9F9 E407 1346

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Karsten Hilbert 2016-03-13 00:18:17 Re: pg_restore fails
Previous Message David G. Johnston 2016-03-12 23:59:59 Re: pg_restore fails