Passwords and batch processes (was Re: Problem with Dump)

From: "David F(dot) Skoll" <dfs(at)roaringpenguin(dot)com>
To: pgsql-admin(at)postgresql(dot)org
Subject: Passwords and batch processes (was Re: Problem with Dump)
Date: 2002-08-23 15:47:54
Message-ID: Pine.LNX.4.44.0208231146100.2481-100000@shishi.roaringpenguin.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

On Fri, 23 Aug 2002, Ian Barwick wrote:

> AFAIK utilities such as pg_dump prompt for the password but
> won't accept it as a command line option, which makes password-based
> authentication almost unusable when calling these utilities from a script.

This really should be Question #1 in the FAQ.

You can set the environment variable PGPASSWORD to the password, and avoid
prompts. This assumes the same username/password has access to all the
databases for pg_dumpall.

I didn't find this documented anywhere. It probably is, but somewhere
buried...

--
David.

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message sonia sanchez diaz 2002-08-23 16:00:36 Problems with array
Previous Message Ian Barwick 2002-08-23 15:33:58 Re: Problem with Dump