Re: [OT] Re: enabling autovacuum

From: Greg Smith <gsmith(at)gregsmith(dot)com>
To: Ow Mun Heng <Ow(dot)Mun(dot)Heng(at)wdc(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: [OT] Re: enabling autovacuum
Date: 2008-01-29 01:57:02
Message-ID: Pine.GSO.4.64.0801282053190.24862@westnet.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Tue, 29 Jan 2008, Ow Mun Heng wrote:

> Can you let me know what is the sql used to generate such a nice summary
> of the tables?

Might as well dupe the old text; this went out to the performance list:

Greg Sabino Mullane released a Nagios plug-in for PostgreSQL that you can
grab at http://bucardo.org/nagios_postgres/ , and while that is itself
nice the thing I found most remarkable is the bloat check. The majority of
that code is an impressive bit of SQL that anyone could use even if you
have no interest in Nagios, which is why I point it out for broader
attention. Look in check_postgres.pl for the "check_bloat" routine and the
big statement starting at the aptly labled "This was fun to write"
section. If you pull that out of there and replace $MINPAGES and
$MINIPAGES near the end with real values, you can pop that into a
standalone query and execute it directly.

That's what gives the summary Jeremy included in his message.

--
* Greg Smith gsmith(at)gregsmith(dot)com http://www.gregsmith.com Baltimore, MD

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Ow Mun Heng 2008-01-29 02:28:10 Re: [OT] Re: enabling autovacuum
Previous Message Ow Mun Heng 2008-01-29 01:40:52 [OT] Re: enabling autovacuum