From: | Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at> |
---|---|
To: | "'Melvin Davidson *EXTERN*'" <melvin6925(at)gmail(dot)com>, Rob Brucks <rob(dot)brucks(at)rackspace(dot)com> |
Cc: | "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org> |
Subject: | Re: Enhancement Request |
Date: | 2016-04-20 07:28:30 |
Message-ID: | A737B7A37273E048B164557ADEF4A58B53841EE7@ntex2010i.host.magwien.gv.at |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Melvin Davidson wrote:
> On Tue, Apr 19, 2016 at 4:37 PM, Rob Brucks <rob(dot)brucks(at)rackspace(dot)com> wrote:
>> I'd like to propose two enhancements to the PostgreSQL code, but I'm not sure if this is the
>> correct mailing list. So if it's not then please let me know where I need to post this.
I'd post feature requests to the -hackers list, but -general is usually fine too.
>> * General monitoring:
>> We have a need for a "monitoring" role in PostgreSQL that has read-only access to any "pg_stat"
>> view. As of 9.4, only a super-user can read all columns of "pg_stat_activity", "pg_stat_replication",
>> and "pg_stat_archiver" (there may be other restricted views as well). These views provide critical
>> insight on how well the cluster is operating and what is going on.
>>
>> There appears to be only two ways to gain access to these views:
>>
>> 1. grant super-user to my monitoring user
>> 2. write custom functions owned by a super-user with "SECURITY DEFINER" and grant access to
>> my monitoring user
I think #2 is good enough.
To reduce the pain of deploying such a function, you can create it in
"template1" and CREATE DATABASE will automatically copy it.
>> * Streaming Replication Monitoring:
>> The only accurate method I have found to measure standby lag is to create a synthetic update
>> that runs periodically. This works, but is less than ideal and requires adding a table to every
>> cluster (which then has to be vacuumed frequently too) and writing and maintaining a process to update
>> it and purge it.
I second that, I have wished for something like that myself.
You don't actually have to create a table for this, a simple "SELECT txid_current()"
on the primary will do the trick. Still it is annoying.
> Enhancement or feature requests should probably go to Custormer Feedback
> <https://postgresql.uservoice.com/forums/21853-general>
I didn't know that site.
Was it ever announced?
Yours,
Laurenz Albe
From | Date | Subject | |
---|---|---|---|
Next Message | John R Pierce | 2016-04-20 07:37:54 | Re: Enhancement Request |
Previous Message | Mike Sofen | 2016-04-20 02:50:27 | Re: Function PostgreSQL 9.2 |