| From: | Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at> |
|---|---|
| To: | "'Andrew Beverley *EXTERN*'" <andy(at)andybev(dot)com>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Creating a user for pg_start_backup |
| Date: | 2015-07-21 12:43:02 |
| Message-ID: | A737B7A37273E048B164557ADEF4A58B50F7491C@ntex2010a.host.magwien.gv.at |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Andrew Beverley wrote:
> I'm setting up hot backups on my database server. As such, I'd like to set up a
> Postgres user that has access to only pg_start_backup and pg_stop_backup.
>
> I'm unable to work out how to do this with the various GRANT options. Can someone
> point me in the right direction please? Or is there a better way to achieve this,
> rather than having a dedicated user?
If you want to be as restrictive as possible, you could create functions
owned by a superuser with SECURITY DEFINER that do only these things
and give execution rights only to a user that has no other privileges.
Youes,
Laurenz Albe
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Ramesh T | 2015-07-21 13:33:00 | Re: Postgres Recovery |
| Previous Message | Geoff Winkless | 2015-07-21 11:05:04 | Re: INSERT ... ON CONFLICT DO UPDATE |