pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@commandprompt.com>
To: Gnanakumar <gnanam@zoniac.com>
Cc: pgsql-admin@postgresql.org
Subject: Re: Autovacuum daemon functionality questions
Date: Fri, 9 Apr 2010 11:02:40 -0400
Message-ID: <20100409150240.GB4384@alvh.no-ip.org> (raw)
In-Reply-To: <001701cad7b7$7f1e2730$7d5a7590$@com>
References: <00c001cad728$22f92f20$68eb8d60$@com>
	<20100408145328.GB4126@alvh.no-ip.org>
	<001701cad7b7$7f1e2730$7d5a7590$@com>

Gnanakumar wrote:

> >There are two separate counters for live and dead tuples, IIRC (though
> >they may not be exposed in the pg_stat views)
> 
> I've a stop/start of PostgreSQL service on a daily basis.  Since these 2
> counters are not stored/saved in tables and not available in pg_stat views
> also, will these values be persisted/retained even after stop/start/restart?

Yes, they persist.

> >There are two separate counters for live and dead tuples
> As per documentation, live tuples can always be obtained from
> pg_class.reltuples.  So, the question/answer here again would be to have
> only counter on dead tuples since last VACUUM.  Is my understanding right?
> Is there some other/alternative way where I can check obsolete tuples at any
> time since last VACUUM?

reltuples is only updated by VACUUM and ANALYZE, which is why pgstats
keeps track of numbers of tuples inserted/deleted/updated for a more
accurate dead and live tuple counts, for autovacuum purposes.

> >> 3. Is there a way to see autovacuum daemon log entries? 
> 
> >Not in 8.2.
> 
> From which next version of PostgreSQL is it available?   Any pointers to
> relevant documentation are appreciated.

8.3
http://www.postgresql.org/docs/8.3/static/runtime-config-autovacuum.html

-- 
Alvaro Herrera                                http://www.CommandPrompt.com/
The PostgreSQL Company - Command Prompt, Inc.



view thread (4+ messages)

Message-ID: <20100409150240.GB4384@alvh.no-ip.org>
Permalink:  ../20100409150240.GB4384@alvh.no-ip.org/
Also on:    postgresql.org/message-id/20100409150240.GB4384@alvh.no-ip.org

 · 

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 using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: alvherre@commandprompt.com, gnanam@zoniac.com
  Subject: Re: Autovacuum daemon functionality questions
  In-Reply-To: <20100409150240.GB4384@alvh.no-ip.org>

* 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