pg.ddx.io  pgsql-bugs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: lalbin@fhcrc.org
To: pgsql-bugs@postgresql.org
Subject: BUG #8257: Multi-Core Restore fails when containing index comments
Date: Wed, 26 Jun 2013 23:43:00 +0000
Message-ID: <E1UrzMa-0007Ns-KX@wrigleys.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-bugs>

The following bug has been logged on the website:

Bug reference:      8257
Logged by:          Lloyd Albin
Email address:      lalbin@fhcrc.org
PostgreSQL version: 9.2.4
Operating system:   SUSE Linux (64-bit)
Description:        

I have found the restore will fail when using pg_restore's -j option, with
more than one core, on a dump that contains a COMMENT INDEX.


I have tried this using both Postgres 9.0.12 & 9.2.4


I have created a test case that shows the problem.


Create a database called test_db.


CREATE DATABASE test_db
  WITH OWNER = postgres
    ENCODING = 'UTF8'
    TEMPLATE = template0;


Run this next section to add the table, index, and index comment to the
test_db database.


CREATE TABLE public.tbl_test (
  pkey TEXT NOT NULL,
  CONSTRAINT tbl_test_pkey PRIMARY KEY(pkey)
);


COMMENT ON INDEX public.tbl_test_pkey
IS 'Index Comment';


Once this test database is created, create a backup of the database.


pg_dump -Fc test_db > test_db.dump


Drop the test database and now lets restore it.


pg_restore -C -j 3 -d postgres -Fc test_db.dump


pg_restore: [archiver (db)] Error while PROCESSING TOC:
pg_restore: [archiver (db)] Error from TOC entry 2525; 0 0 COMMENT INDEX
tbl_test_pkey postgres
pg_restore: [archiver (db)] could not execute query: ERROR:  relation
"tbl_test_pkey" does not exist
    Command was: COMMENT ON INDEX tbl_test_pkey IS 'Index Comment';






pg_restore: [archiver] worker process failed: exit code 1


If you use -j 1 or skip the -j option the restore will restore without any
errors.


Lloyd Albin
Statistical Center for HIV/AIDS Research and Prevention (SCHARP)
Vaccine and Infectious Disease Division (VIDD)
Fred Hutchinson Cancer Research Center (FHCRC)




-- 
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 (6+ messages)  latest in thread

Message-ID: <E1UrzMa-0007Ns-KX@wrigleys.postgresql.org>
Permalink:  ../E1UrzMa-0007Ns-KX@wrigleys.postgresql.org/
Also on:    postgresql.org/message-id/E1UrzMa-0007Ns-KX@wrigleys.postgresql.org

 · 

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: lalbin@fhcrc.org
  Subject: Re: BUG #8257: Multi-Core Restore fails when containing index comments
  In-Reply-To: <E1UrzMa-0007Ns-KX@wrigleys.postgresql.org>
  References: <E1UrzMa-0007Ns-KX@wrigleys.postgresql.org>

* 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