Re: [ADMIN] backing and restoring whole database server - how does this script look

2009-04-10 Thread Kevin Bailey
Tom Lane wrote: Peter Koczan writes: On Fri, Apr 10, 2009 at 4:34 AM, Kevin Bailey wrote: Just to make thigs more interesting, we have to do this for a version 8.1 server and an older 7.4 server which has blobs in it. If I remember correctly, pg_dumpall only allows text

Re: [ADMIN] connectivity problem

2009-04-10 Thread Tena Sakai
Hi Scott, > export PGHOST=vixen > psql canon > OR > psql -h vixen canon Yes, yes, yes! That is it. Many thanks. Regards, Tena Sakai [email protected] -Original Message- From: Scott Mead [mailto:[email protected]] Sent: Fri 4/10/2009 1:03 PM To: Tena Sakai Cc:

Re: [ADMIN] connectivity problem

2009-04-10 Thread Tena Sakai
Hi Scott, Thank you for your reply, but... postgresql.conf has: listen_addresses = '*' Is there anything else I am missing? Tena Sakai [email protected] -Original Message- From: Scott Marlowe [mailto:[email protected]] Sent: Fri 4/10/2009 12:42 PM To: Tena Sakai Cc: pgsql-

Re: [ADMIN] connectivity problem

2009-04-10 Thread Scott Mead
On Fri, Apr 10, 2009 at 3:39 PM, Tena Sakai wrote: > Hi Everybody, > > I am having difficulty connecting to postgres service from > a remote machine on the network. > > My postgres (8.3.6, on Linux) is running on a machine > (vixen) and I would like to connect to it from another host. > > The ho

Re: [ADMIN] connectivity problem

2009-04-10 Thread Plugge, Joe R.
Check out using a .pgpass file in your home directory on blitzen: http://www.postgresql.org/docs/current/static/libpq-pgpass.html From: [email protected] [mailto:[email protected]] On Behalf Of Tena Sakai Sent: Friday, April 10, 2009 2:40 PM To: pgsql-admin@postgr

Re: [ADMIN] backing and restoring whole database server - how does this script look

2009-04-10 Thread Tom Lane
Peter Koczan writes: > On Fri, Apr 10, 2009 at 4:34 AM, Kevin Bailey > wrote: >> Just to make thigs more interesting, we have to do this for a version 8.1 >> server and an older 7.4 server which has blobs in it. > If I remember correctly, pg_dumpall only allows text format dumps, and > blobs nee

Re: [ADMIN] connectivity problem

2009-04-10 Thread Scott Marlowe
On Fri, Apr 10, 2009 at 1:39 PM, Tena Sakai wrote: > Hi Everybody, > > I am having difficulty connecting to postgres service from > a remote machine on the network. > > My postgres (8.3.6, on Linux) is running on a machine > (vixen) and I would like to connect to it from another host. > > The host

[ADMIN] connectivity problem

2009-04-10 Thread Tena Sakai
Hi Everybody, I am having difficulty connecting to postgres service from a remote machine on the network. My postgres (8.3.6, on Linux) is running on a machine (vixen) and I would like to connect to it from another host. The host (named blitzen, runs linux as well) appears in pg_hba.conf of vixe

Re: [ADMIN] backing and restoring whole database server - how does this script look

2009-04-10 Thread Peter Koczan
On Fri, Apr 10, 2009 at 4:34 AM, Kevin Bailey wrote: > We're trying to get a script to backup and restore a whole database server. > > So far we're looking at something like > ... > which is obviously a rough-cut - and the main problem we have is that a > client has set up a DB where the owner nam

Re: [ADMIN] backing and restoring whole database server - how does this script look

2009-04-10 Thread P Kapat
i had a similar (though not as complicated) question: On Fri, Apr 10, 2009 at 5:34 AM, Kevin Bailey wrote: > We're trying to get a script to backup and restore a whole database server. > > So far we're looking at something like > > for db in `psql -U postgres -At -c 'select datname from pg_databa

Re: [ADMIN] Finding out on exactly what I am stuck

2009-04-10 Thread Kevin Grittner
Péter Kovács wrote: > It appears nobody is waiting for a lock (all current locks are > granted): Then I would run the UPDATE on another connection with EXPLAIN in front of it. That would show you the plan it will use, which might give a clue why it is running so long. Also, a connection whic

[ADMIN] backing and restoring whole database server - how does this script look

2009-04-10 Thread Kevin Bailey
We're trying to get a script to backup and restore a whole database server. So far we're looking at something like for db in `psql -U postgres -At -c 'select datname from pg_database where not datistemplate' -d template1`; do pg_dump -U ${PGSQL_USER} -h localhost --blobs --format=c --file="

[ADMIN] Further question RE dumping and reloading whole database server

2009-04-10 Thread Kevin Bailey
Further to an earlier question.. I've tried pg_dumpall --inserts --clean -h $REMOTE -U admin | psql -U postgres template1 To extract a whole database from a remote server and to reload it into a local DB but this produces tons of errors. ERROR: role "admin" cannot be dropped because some