From: | Jesper Krogh <jesper(at)krogh(dot)cc> |
---|---|
To: | Michael Graziano <michael(dot)graziano(at)premierheart(dot)com> |
Cc: | Julius Tuskenis <julius(at)nsoft(dot)lt>, "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org> |
Subject: | Re: Practice of backups |
Date: | 2009-11-19 18:58:04 |
Message-ID: | 4B05953C.1070202@krogh.cc |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
Michael Graziano wrote:
> On Nov 18, 2009, at 2:45 AM, Julius Tuskenis wrote:
>
>> The question is what user should do backups. Is it good practice to
>> use superuser for that?
>
> If you're doing your backup with pg_dump (on an individual DB) you need
> a DB user who has read access to everything in that DB.
> If you're doing your backup with pg_dumpall (on the whole cluster) you
> need a DB user with read access to everything in the cluster (including
> roles/users), which pretty much demands a superuser...
>
> In either case when I do dumps using pg_dump or pg_dumpall I use a
> superuser account to make sure I don't miss anything.
>
>
>> If not - is there an easy way to let some backup user to access whole
>> database without setting permission on every database component
>> (tables, sequences, functions, etc)?
>
> None that I know of from within the database environment, but you can
> grab a copy of the data directory off the filesystem. Note that this
> requires stopping the DB server though, as a backup grabbed while the DB
> is running may have issues.
Not if you have enabled PITR and tell the database that you do so:
http://www.postgresql.org/docs/8.4/static/continuous-archiving.html
Works excellent..
Jesper
From | Date | Subject | |
---|---|---|---|
Next Message | Devrim GÜNDÜZ | 2009-11-19 19:02:29 | Re: Replication solution |
Previous Message | Joshua D. Drake | 2009-11-19 18:55:29 | Re: Replication solution |