Carlos Mennens wrote:
>> 0 4 * * * /usr/bin/pg_dumpall> pg_dumpall.$DATE.sql
>>
>> that'll run at 4am every day.
> When I run the command in my shell (not in Cron), I'm prompted for my
> login password. Should I change the permissions in pg_hba.conf and
> enable INHERIT grants on my user? Should I place this in who's Cron
> line? Postgres? Carlos? or Root?
I'd use the postgres user and allow "trust" authentication for that
user on local connections in pg_hba.conf. No grants are required.
If you have write activity during the backup and you need all data
of a database to be consistent, consider using pg_dump's
--serializable-deferrable flag.
Yours,
Laurenz Albe