From: | Mario Splivalo <mario(dot)splivalo(at)megafon(dot)hr> |
---|---|
To: | pgsql-admin(at)postgresql(dot)org |
Subject: | Re: Reseting statistics, cluster wide |
Date: | 2011-04-21 07:51:12 |
Message-ID: | 4DAFE1F0.6030508@megafon.hr |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-admin |
On 04/20/2011 10:49 PM, raghu ram wrote:
> On Thu, Apr 21, 2011 at 1:01 AM, Mario Splivalo
> <mario(dot)splivalo(at)megafon(dot)hr <mailto:mario(dot)splivalo(at)megafon(dot)hr>> wrote:
> I have set up munin monitoring that plots nice graphs using
> pg_stat_bgwriter and pg_stat_database views. It has been on for
> quite some time now, and the numbers those views return are too big
> for munin to handle. I would like to reset those statistics. As
> explained by manual, pg_stat_reset() resets only db-related
> statistics, not the ones used cluster-wide. Is there a way to reset
> those? I don't mind stopping the server if I need to, but I'd realy
> like to have those started all over again.
> Currently we don't have such feature to reset statistics on cluster
> level. You have to use two PostgreSQL functions like
> pg_stat_reset_shared(text), pg_stat_reset ().
> There are a few statistics that are only kept on a per-cluster basis,
> such as those reported in pg_stat_database and pg_stat_bgwriter. Since
> pg_stat_reset only resets per-database statistics.
>
>
> psql=# select pg_stat_reset();
>
>
> psql=# select pg_stat_reset_shared('bgwritter'); -- It will reset the
> statistics shown by pg_stat_bgwritter.
>
Heh, I've neglected to mention that i'm using postgres 8.4.5 on Debian
Stable. Is there a way to reset statistics on pg8.4? I've tested it on
9.0 and it works there.
Mario
From | Date | Subject | |
---|---|---|---|
Next Message | Kevin Grittner | 2011-04-21 14:55:02 | Re: How to uninstall PostgreSQL 8.4 on both Windows XP and Windows 7 |
Previous Message | Thomas Kellerer | 2011-04-21 06:43:48 | Re: ERROR: column "time" cannot be cast to type bigint |