Re: Permission select pg_stat_replication

From: "Gilberto Castillo" <gilberto(dot)castillo(at)etecsa(dot)cu>
To: "Stephen Frost" <sfrost(at)snowman(dot)net>
Cc: jesse(dot)waters(at)gmail(dot)com, pgsql-admin(at)postgresql(dot)org
Subject: Re: Permission select pg_stat_replication
Date: 2015-03-31 14:29:44
Message-ID: 45998.192.168.207.54.1427812184.squirrel@webmail.etecsa.cu
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin pgsql-hackers

> Jesse,
>
> * jesse(dot)waters(at)gmail(dot)com (jesse(dot)waters(at)gmail(dot)com) wrote:
>> Could someone tell me what permission is required to
>> select * from pg_stat_replication; ?
>
> Currently, you're required to have superuser rights.
>
>> I like to setup a monitor to query database with minimal privileges
>> necessary.
>
> I agree 110% and am actively working to fix exactly this issue. I hope
> to have a patch in the next day or so which will allow you to GRANT
> rights to such a monitor user which will allow that user to see all the
> contents of pg_stat_replication.
>
> One thing which would be really great is if you have time to test with
> the patch I'm working up (it's against 9.5, but this is strictly
> functionality testing and should be just in in a dev/test environment,
> I wouldn't suggest running 9.5 in production, of course!).

Hello,

This can functional?

SET SESSION AUTHORIZATION postgres;

GRANT SELECT ON pg_stat_replication TO usuario1;

¿?¿?¿?¿?¿?

Saludos,
Gilberto Castillo
La Habana, Cuba

Attachment Content-Type Size
unknown_filename text/plain 179 bytes

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message BRUNO CESAR BERNARDES 2015-03-31 14:35:06 Catalog permissions
Previous Message Stephen Frost 2015-03-31 13:44:40 Re: Permission select pg_stat_replication

Browse pgsql-hackers by date

  From Date Subject
Next Message Adam Brightwell 2015-03-31 14:34:45 Re: Bug fix for missing years in make_date()
Previous Message Greg Stark 2015-03-31 14:19:04 Re: Streaming replication