pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Gourish Singbal <gourish@gmail.com>
To: pgsql-admin@postgresql.org <pgsql-admin@postgresql.org>
Subject: Re: Autovacuuming
Date: Mon, 24 Apr 2006 18:39:38 +0530
Message-ID: <674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com> (raw)
In-Reply-To: <20060424124155.GA13361@surnet.cl>
References: <674d1f8a0604232251v4649b456xc542fd831f8db4@mail.gmail.com>
	<20060424124155.GA13361@surnet.cl>

Show autovacuum displays 'on'.

db1=# select datname, datvacuumxid, datfrozenxid from pg_database;
       datname       | datvacuumxid | datfrozenxid
---------------------+--------------+--------------
 postgres            |          499 |          499
 db1           |     71677296 |   3292902769
 db2 |     99962197 |   3321187670
 db3       |     72274322 |   3293587302
 template1           |          499 |          499
 template0           |          499 |          499
(6 rows)

db1=# SELECT datname, age(datfrozenxid) FROM pg_database;
       datname       |    age
---------------------+------------
 postgres            |  143239306
 db1          | 1145304332
 db2 | 1117019431
 db3       | 1144619799
 template1           |  143239306
 template0           |  143239306
(6 rows)

Since we are currently 465208401 transactions away from the 1610512733.

Can i safely sit back and wait for the autovacuum deamon to do its job
without any issues ?.


On 4/24/06, Alvaro Herrera <alvherre@commandprompt.com> wrote:
>
> Gourish Singbal wrote:
> > The Age of the database is 1144759836 . We have enabled autovacuuming .
> > The details are:-
> > autovacuum = on
>
> Are you sure autovacuum is enabled?  Do a "SHOW autovacuum" just to be
> sure.
>
> The test for database-wide vacuum is:
>
> database age > big_constant
>
> where:
>
> big_constant = (MaxTransactionId >> 3) * 3 - 100000) = 1610512733
> MaxTransactionId = 0xFFFFFFFF
> database age = Max(frozen age, vacuum age)
> frozen age = next Transaction id - pg_database.datfrozenxid
> vacuum age = next Transaction id - pg_database.datvacuumxid
>
>
> Your database is still 465752897 transactions away from that apparently.
>
> --
> Alvaro Herrera
> http://www.CommandPrompt.com/
> The PostgreSQL Company - Command Prompt, Inc.
>



--
Best,
Gourish Singbal

view thread (11+ messages)  latest in thread

Message-ID: <674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com>
Permalink:  ../674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com/
Also on:    postgresql.org/message-id/674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-admin@postgresql.org
  Cc: gourish@gmail.com
  Subject: Re: Autovacuuming
  In-Reply-To: <674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com>
  References: <674d1f8a0604232251v4649b456xc542fd831f8db4@mail.gmail.com> <20060424124155.GA13361@surnet.cl> <674d1f8a0604240609m3e2d75a2m89c0654ba94df785@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox