Thread: how to cron pg_dump and vaccum
Hi I want to program pg_dump in crontab but with authentification of user pg_dump prompt a user name and password. how can i backup my database automatic (one backup for a day). pg_version :7.0 Thanks -- _______________________________ Fouad Fezzi Ingenieur R�seau IUP Institut Universitaire Professionnalis� Universite d'Avignon et des Pays de Vaucluse 339 ch. des Meinajaries tel : (+33/0) 4 90 84 35 50 BP 1228 - 84911 AVIGNON CEDEX 9 fax : (+33/0) 4 90 84 35 01 http://www.iup.univ-avignon.fr _________________________________
> I want to program pg_dump in crontab but with authentification of user > pg_dump prompt a user name and password. > how can i backup my database automatic (one backup for a day). > pg_version :7.0 This is my backup script: (1 line) su -c "PGPASSWORD=;export PGPASSWORD;pg_dumpall>/var/lib/pgsql/postgres_backup" postgres PGPASSWORD is your postgreSQL administrator password. I use pg_dumpall to dump all databases in one time.