Thread: unattended backups

unattended backups

From
"Andrew C. Uselton"
Date:
Greetings pgsql gurus,
  I have a pgsql database that uses md5 passwords.  When I want to back
it up the "pg_dumpall >dump_file" command prompts for the administrative
password, evidently via stderr.  I'd like to stick a "pg_dumpall" in a
cron job, and supply it with the password.  I don't mind having the
administrative password somewhere readable by root, but I am stumped how
to carry this out.  Has anyone been down this road ahead of me and found
an answer? (other than "abandon hope ...")
cheers,
Andrew


Re: unattended backups

From
Alan Hodgson
Date:
On Monday 27 August 2007 13:18, "Andrew C. Uselton" <acuselton@lbl.gov>
wrote:
> I'd like to stick a "pg_dumpall" in a
> cron job, and supply it with the password.  I don't mind having the
> administrative password somewhere readable by root, but I am stumped how
> to carry this out.

Put it in root's .pgpass file.

--
99 percent of lawyers give the rest a bad name