Re: Automatic backup with password

From: Neil Conway <neilc(at)samurai(dot)com>
To: Zengfa Gao <zfgao(at)yahoo(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Automatic backup with password
Date: 2002-12-11 19:35:40
Message-ID: 1039635340.854.1.camel@tokyo
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Wed, 2002-12-11 at 11:21, Zengfa Gao wrote:
> I am trying to write some code to do automatic backup
> for PgSQL with pg_dump tool. For safty reason, I still
> want the password protection.

> But pg_dump force password prompt. I don't find a way
> to give pg_dump with code. Does anyone have an idea?

Set the PGPASSWORD env var, or use the ~/.pgpass file (in 7.3). For more
info, see:

http://www.ca.postgresql.org/users-lounge/docs/7.3/postgres/libpq-envars.html
http://www.ca.postgresql.org/users-lounge/docs/7.3/postgres/libpq-files.html

Cheers,

Neil

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Frank Bax 2002-12-11 19:36:00 Re: INDEX suggestion needed
Previous Message Han Holl 2002-12-11 19:29:03 Re: Automatic backup with password