Unix Technical Forum

Error on pg_dumpall

This is a discussion on Error on pg_dumpall within the pgsql Admins forums, part of the PostgreSQL category; --> Greetings, I'm having a problem that I hope you can help me with. I am getting the following error ...


Go Back   Unix Technical Forum > Database Server Software > PostgreSQL > pgsql Admins

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 04-29-2008, 09:30 PM
Carol Walter
 
Posts: n/a
Default Error on pg_dumpall

Greetings,

I'm having a problem that I hope you can help me with. I am getting
the following error when I try to run pg_dumpall.

postgres@machine1:~$ /usr/local/pgsql/bin/pg_dumpall
pg_dumpall: could not connect to database "template1": could not
connect to server: No such file or directory
Is the server running locally and accepting
connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

If I run the command "psql template1", I can connect to template1
just fine. It looks like pg_dumpall may be looking for template1 in
the wrong place.

This is a new installation of postgresql 8.3 on a Debian Linux
machine. All my other machines are Solaris 10 running PostgreSQL 8.2.

Thanks,

Carol Walter

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 04-29-2008, 09:30 PM
Tom Lane
 
Posts: n/a
Default Re: Error on pg_dumpall

Carol Walter <walterc@indiana.edu> writes:
> I'm having a problem that I hope you can help me with. I am getting
> the following error when I try to run pg_dumpall.


> postgres@machine1:~$ /usr/local/pgsql/bin/pg_dumpall
> pg_dumpall: could not connect to database "template1": could not
> connect to server: No such file or directory
> Is the server running locally and accepting
> connections on Unix domain socket "/tmp/.s.PGSQL.5432"?


> If I run the command "psql template1", I can connect to template1
> just fine.


Does "which psql" say that you're using the psql in
/usr/local/pgsql/bin?

It sounds to me a bit like you have two sets of PG programs with
different default port numbers compiled into them. Which port is
the server actually listening on?

> This is a new installation of postgresql 8.3 on a Debian Linux
> machine.


Debian is a rather nasty environment for custom-built PG installations,
because they have their own ideas of where to put the PG programs
and what port numbers they should run on. I'm thinking you are
connecting to a Debian-supplied postmaster on a non-standard port,
and not to your own installation at all.

regards, tom lane

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #3 (permalink)  
Old 04-29-2008, 09:30 PM
Julian v. Bock
 
Posts: n/a
Default Re: Error on pg_dumpall

Hi

>>>>> "CW" == Carol Walter <walterc@indiana.edu> writes:


CW> postgres@machine1:~$ /usr/local/pgsql/bin/pg_dumpall pg_dumpall:
CW> could not connect to database "template1": could not connect to
CW> server: No such file or directory Is the server running locally
CW> and accepting connections on Unix domain socket
CW> "/tmp/.s.PGSQL.5432"?

CW> If I run the command "psql template1", I can connect to template1
CW> just fine. It looks like pg_dumpall may be looking for template1
CW> in the wrong place.

Debian uses /var/run/postgresql instead of /tmp as directory for unix
domain sockets. Try
/usr/local/pgsql/bin/pg_dumpall -h /var/run/postgresql

--
Julian v. Bock Projektleitung Software-Entwicklung
OpenIT GmbH Tel +49 211 239 577-0
Jahnstr. 18 Fax +49 211 239 577-10
D-40215 Düsseldorf http://www.openit.de
__________________________________________________ ______________
HRB 38815 Amtsgericht Düsseldorf USt-Id DE 812951861
Geschäftsführer:
Susanne Schultz, Oliver Haakert, Maurice Kemmann

--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #4 (permalink)  
Old 05-02-2008, 06:06 AM
Carol Walter
 
Posts: n/a
Default Re: Error on pg_dumpall

This turned out to be a wrapper versus binary issue. psql was
running under the wrapper. It ran fine. pg_dump wasn't but when we
corrected this it worked fine too.
This is the first time I've run into this and it's the first time
I've dealt with PostgreSQL on any but a Sparc running Solaris. I
don't know if the same thing happens with Solaris, but I'm going to
investigate just for interest.

Carol

On Apr 29, 2008, at 10:45 AM, Tom Lane wrote:

> Carol Walter <walterc@indiana.edu> writes:
>> I'm having a problem that I hope you can help me with. I am getting
>> the following error when I try to run pg_dumpall.

>
>> postgres@machine1:~$ /usr/local/pgsql/bin/pg_dumpall
>> pg_dumpall: could not connect to database "template1": could not
>> connect to server: No such file or directory
>> Is the server running locally and accepting
>> connections on Unix domain socket "/tmp/.s.PGSQL.5432"?

>
>> If I run the command "psql template1", I can connect to template1
>> just fine.

>
> Does "which psql" say that you're using the psql in
> /usr/local/pgsql/bin?
>
> It sounds to me a bit like you have two sets of PG programs with
> different default port numbers compiled into them. Which port is
> the server actually listening on?
>
>> This is a new installation of postgresql 8.3 on a Debian Linux
>> machine.

>
> Debian is a rather nasty environment for custom-built PG
> installations,
> because they have their own ideas of where to put the PG programs
> and what port numbers they should run on. I'm thinking you are
> connecting to a Debian-supplied postmaster on a non-standard port,
> and not to your own installation at all.
>
> regards, tom lane



--
Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 10:40 AM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0
www.UnixAdminTalk.com