Re: PQputline error with pg_restore

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jennifer Drake <drakeji(at)vcu(dot)edu>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: PQputline error with pg_restore
Date: 2006-02-09 17:09:43
Message-ID: 2261.1139504983@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Jennifer Drake <drakeji(at)vcu(dot)edu> writes:
> I am running PostgreSQL 7.3.2 on Mandrake 9.1

You should really update to something more current than 7.3.2 :-(

> pg_restore: [archiver(db)] error returned by PQputline
> pg_restore: *** aborted because of error

The first thing to do is get more info about the error, but
unfortunately that release of pg_restore isn't going to tell you what
the error message from PQputline is. So you'll have to try to find
out from the postmaster's log.

> I tried checking the log for the postmaster
> (I assumed to be in /var/log), but no such file existed.

You'll need to look at the startup script Mandrake uses for postgres
to see where it sends the postmaster's stderr, but I wouldn't be
surprised to find that it sends to /dev/null :-(. You can change the
script to redirect to some real file and then restart the postmaster and
then try the restore again. Or reconfigure things so that the
postmaster sends its log messages to syslog --- though this may take
some fooling with syslog's configuration as well as with postgresql.conf.
(Syslog is probably a better choice for production purposes --- if you
redirect to a file, that file will continue to grow as long as the
postmaster runs.)

Once you've managed to see the underlying error message, if it doesn't
make things clear then pass the info along and we'll try to help.

BTW, another thing you could try is having pg_restore just generate
a SQL script, and then feed the SQL script to psql. psql will probably
be more cooperative about showing the underlying message.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Redefined Horizons 2006-02-09 17:09:48 Debian Packages For PostgreSQL
Previous Message Scott Marlowe 2006-02-09 16:43:06 Re: Is there a way to limit CPU usage per user