postgres backup script and popen2

Gabriel Genellina gagsl-py at yahoo.com.ar
Thu Feb 8 11:23:49 EST 2007


On 8 feb, 10:27, Maël Benjamin Mettler <m... at mediamonger.ch> wrote:

> flupke schrieb:
> > i made a backup script to backup my postgres database.
> > Problem is that it prompts for a password. It thought i
> > could solve this by using popen2.
>
> Use pexpect:http://pexpect.sourceforge.net/

pexpect could work. But a better way would be to supply the password
on the command line. I don't know how postgres does that things, but I
hope there is some way to automate the backup process...

--
Gabriel Genellina




More information about the Python-list mailing list