pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Rudi Starcevic <rudi@oasis.net.au>
Cc: Ganesan Kanavathy <ganesh@magnusquest.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: pg_dump.. auto backup
Date: Wed, 15 Oct 2003 23:36:35 -0400
Message-ID: <15877.1066275395@sss.pgh.pa.us> (raw)
In-Reply-To: <3F8DFCC9.5090603@oasis.net.au>
References: <000001c39385$f0491280$1300a8c0@headquarters.mq.com>
	<3F8DFCC9.5090603@oasis.net.au>

Rudi Starcevic <rudi@oasis.net.au> writes:
> Ganesan Kanavathy wrote:
>> The problem I am facing is the when running the cronjob it is asking 
>> for password.

> Just add:
> export PGPASSWORD=mypassword
> to your script.

A much better solution (assuming you are using a reasonably recent PG
release) is to put the needed password in ~/.pgpass, which can be set to
0600 permissions.  PGPASSWORD is insecure on many platforms because
other people can see your environment variables.

			regards, tom lane



view thread (6+ messages)  latest in thread

Message-ID: <15877.1066275395@sss.pgh.pa.us>
Permalink:  ../15877.1066275395@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/15877.1066275395@sss.pgh.pa.us

 · 

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: tgl@sss.pgh.pa.us, rudi@oasis.net.au, ganesh@magnusquest.com
  Subject: Re: pg_dump.. auto backup
  In-Reply-To: <15877.1066275395@sss.pgh.pa.us>
  References: <000001c39385$f0491280$1300a8c0@headquarters.mq.com> <3F8DFCC9.5090603@oasis.net.au> <15877.1066275395@sss.pgh.pa.us>

* 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