pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Dario <dario_d_s@unitech.com.ar>
To: pgsql-admin@postgresql.org
Subject: postgres 7.2.1 pg_restore large objects
Date: Wed, 30 Mar 2005 18:41:43 -0300
Message-ID: <opsogzvtrcinmy3h@dariop> (raw)

Problem: Not being able to restore a database with lo. I have already read  
forums and doc. Probably I'm loosing something, but I just can figure.

Reading forums I though I finally got a "right" way to do it.
I'm running this as OS user "postgres" which is a super user

pg_dump -Ft -o -b base > base.tar 2>log_err2 # If I untar the file, i see  
table data, and blob data, toc and restore.sql.

createdb base2 //from OS shell

/usr/local/pgsql/bin/pg_restore -Ft -s -v -d base2 base.tar  2>elogerr     
#creates schema

psql -f src/contrib/lo.sql base2    #creates lo type and functions... my  
base.tar includes lo type definition. O also tried to delete the type  
previously, and did not make any difference. If I do not do this,  
pg_restore claims that I lo and oid must be explicity casted. One more  
thing, I can't make lo_manage to work (trigger type doesn't exist). I don  
use it anyway, since I manage lo updates and delete from app. I delete  
blobs from app.

/usr/local/pgsql/bin/pg_restore -Ft -a -v -d base2 base.tar 2>flogerr

the pg_restore fails with the following error.

----------------------------------
pg_restore log (flogerr file)
pg_restore: [archiver (db)] error while updating column "tca_texto" of  
table "tca": server closed the connection unexpectedly
         This probably means the server terminated abnormally
         before or while processing the request.
pg_restore: *** aborted because of error

----------------------------------
postgres log file
DEBUG:  server process (pid 25276) was terminated by signal 11
DEBUG:  terminating any other active server processes
NOTICE:  Message from PostgreSQL backend:
         The Postmaster has informed me that some other backend
         died abnormally and possibly corrupted shared memory.
         I have rolled back the current transaction and am
         going to terminate your database system connection and exit.
         Please reconnect to the database system and repeat your query.
DEBUG:  all server processes terminated; reinitializing shared memory and  
semaphores
----------------------------------

No table is updated.

I tried to create a table with oid column instead of lo, restore (worked  
in this way), I renamed table, I created a table with lo datatype, but  
when I tried to insert into ... , same error occurs.

server closed the connection unexpectedly
This probably means the server terminated abnormally
before or while processing the request.


I have two different versions of postgres, one compiled by someone here,  
and another version, installed via rpm.
unlikely, upgrading to a different version, is not an option, I probably  
update to 7.2.(last version), but only if this specific problem is solved.  
I have read the release section of the doc and did not apeared explicity...

greetings.

TIA to all

"Hoy es un buen dia para morir" (today is a good day to die, Klingon en  
espaƱol)!



view thread (7+ messages)  latest in thread

Message-ID: <opsogzvtrcinmy3h@dariop>
Permalink:  ../opsogzvtrcinmy3h@dariop/
Also on:    postgresql.org/message-id/opsogzvtrcinmy3h@dariop

 · 

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-admin@postgresql.org
  Cc: dario_d_s@unitech.com.ar
  Subject: Re: postgres 7.2.1 pg_restore large objects
  In-Reply-To: <opsogzvtrcinmy3h@dariop>
  References: <opsogzvtrcinmy3h@dariop>

* 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