Skip site navigation (1) Skip section navigation (2)

Re: Clearing global statistics

From: Rafael Martinez <r(dot)m(dot)guerrero(at)usit(dot)uio(dot)no>
To: Greg Smith <greg(at)2ndquadrant(dot)com>
Cc: Magnus Hagander <magnus(at)hagander(dot)net>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Clearing global statistics
Date: 2010-01-14 13:42:59
Message-ID: (view raw or whole thread)
Lists: pgsql-hackers
Hash: SHA1

Greg Smith wrote:
> Magnus Hagander wrote:
>> I have on my TODO to implement the ability to do stats reset on a
>> single object (say, one table only). Please take this into
>> consideration when you design/name this, so theres no unnecessary
>> overlap :-) Same goes for the stats message itself.
> Any comments before I update my patch to do that?


One thing I miss from the statistics you can get via pg_stat_* is
information about how long we have been collecting stats (or in other
words, when was the last time the stats were reset)

Statistics without time period information are unfortunately not very
usefull for a DBA :-(

Before 8.3, we had the stats_reset_on_server_start parameter and the
pg_postmaster_start_time() function. This was an easy way of resetting
*all* statistics delivered by pg_stat_* and knowing when this was done.
We were able to produce stats with information about sec/hours/days
average values in an easy way.

I tried to discuss this some time ago but we did not get anywhere,

Maybe this time? :-)

Is there any chance of implementing a way of knowing when was the last
time statistics delivered via pg_stat_* were reset?

- --
 Rafael Martinez, <r(dot)m(dot)guerrero(at)usit(dot)uio(dot)no>
 Center for Information Technology Services
 University of Oslo, Norway

 PGP Public Key:
Version: GnuPG v1.2.7 (GNU/Linux)


In response to


pgsql-hackers by date

Next:From: Dave PageDate: 2010-01-14 13:46:09
Subject: Re: mailing list archiver chewing patches
Previous:From: Dimitri FontaineDate: 2010-01-14 13:39:44
Subject: Re: mailing list archiver chewing patches

Privacy Policy | About PostgreSQL
Copyright © 1996-2015 The PostgreSQL Global Development Group