On Wed, 27 Feb 2008, Tena Sakai wrote:

Hi Jeff,

Thanks for your reply, but I think you might
have missed an earlier thread.  I am afraid
I have tried what you suggest.  Below's my
previous post.


 filename=`date +%G%m%d.%w`.gz
 /usr/local/pgsql/bin/pg_dumpall > $filename

Here's what I get back as output is:

 Password:
 pg_dumpall: could not connect to database "template1": fe_sendauth: no 
password supplied

This is not what happened on 8.2.4.  I read 8.3.0 man
page on pg_dumpall.  Here's what it told me:

 The file .pgpass in a user's home directory or the file referenced
 by PGPASSFILE can contain passwords to be used if the connection
 requires a password (and no password has been specified otherwise).

I have .pgpass in /usr/local/pgsql and when I type
 psql dbname
It lets me in without asking the password.  So I don't
understand why I get what I get: fe_sendauth: no password supplied


Please reply-all and don't top-post. :-)

I bet the $HOME environment variable isn't being set by your cron implementation. Is this gentoo perhaps? Try putting an echo $HOME in your script and see if it's defined.

--
Jeff Frost, Owner       <[EMAIL PROTECTED]>
Frost Consulting, LLC   http://www.frostconsultingllc.com/
Phone: 650-780-7908     FAX: 650-649-1954

---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?

              http://archives.postgresql.org

Reply via email to