Re: postgresql transaction id monitoring with nagios

From: "Jim C(dot) Nasby" <jnasby(at)pervasive(dot)com>
To: Tony Wasson <ajwasson(at)gmail(dot)com>
Cc: Vivek Khera <vivek(at)khera(dot)org>, Pgsql performance <pgsql-performance(at)postgresql(dot)org>
Subject: Re: postgresql transaction id monitoring with nagios
Date: 2006-05-02 21:46:37
Message-ID: 20060502214637.GH97354@pervasive.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-performance

On Tue, May 02, 2006 at 12:06:30PM -0700, Tony Wasson wrote:
> Ah thanks, it's a bug in my understanding of the thresholds.
>
> "With the standard freezing policy, the age column will start at one
> billion for a freshly-vacuumed database."
>
> So essentially, 1B is normal, 2B is the max. The logic is now..
>
> The script detects a wrap at 2 billion. It starts warning once one or
> more databases show an age over 1.5 billion transactions. It reports
> critical at 1.75B transactions.
>
> If anyone else understands differently, hit me with a clue bat.

You should take a look at the code in -HEAD that triggers autovacuum to
do a XID-wrap-prevention vacuum, as well as the code that warns that
we're approaching wrap. From memory, the limit for the later is

max_transactions << 3

Where max_transactions should be 4B on most platforms.

I'm intending to submit a patch to clean some of that code up (put all
the thresholds in one .h file rather than how they're spread through
source code right now); if you drop me an email off-list I'll send you
info once I do that.
--
Jim C. Nasby, Sr. Engineering Consultant jnasby(at)pervasive(dot)com
Pervasive Software http://pervasive.com work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf cell: 512-569-9461

In response to

Browse pgsql-performance by date

  From Date Subject
Next Message Chris Mckenzie 2006-05-02 21:47:15 Re: Postgres 7.4 and vacuum_cost_delay.
Previous Message Jim C. Nasby 2006-05-02 21:42:36 Re: postgresql transaction id monitoring with nagios