Re: QUERY: autovacuum: VACUUM ANALYZE table versus QUERY: autovacuum: VACUUM table - Mailing list pgsql-general

From Tom Lane
Subject Re: QUERY: autovacuum: VACUUM ANALYZE table versus QUERY: autovacuum: VACUUM table
Date
Msg-id 19520.1572704547@sss.pgh.pa.us
Whole thread Raw
In response to QUERY: autovacuum: VACUUM ANALYZE table versus QUERY: autovacuum:VACUUM table  (Jason Ralph <jralph@affinitysolutions.com>)
List pgsql-general
Jason Ralph <jralph@affinitysolutions.com> writes:
> I am trying to find out if the naming convention from autovacuum does what its command line equivalent does, or at
leastwhat I think it does. 

> QUERY: autovacuum: VACUUM ANALYZE table versus autovacuum: VACUUM ANALYZE table.

> I have been getting my autovacuum tuned and I have the settings where I see 2 types of queries running now and doing
theirjobs. I know vacuum alone will mark dead tuples ready for use again, and analyze alone will update statistics for
thequery planner. 

> 1. QUERY: autovacuum: VACUUM ANALYZE table
> 2. QUERY: autovacuum: VACUUM table

> My question is do we need both?

Some autovacuum runs will do only VACUUM on a given table, some will do
only ANALYZE, and some will do both.  The decisions about which of
these operations are needed are related but not identical (one's based
on n_dead_tup and the other on n_mod_since_analyze, plus you can set
different threshold parameters to compare those to).  The pg_stat_activity
report of what's happening does match the command-line syntax.

            regards, tom lane



pgsql-general by date:

Previous
From: Adrian Klaver
Date:
Subject: Re: QUERY: autovacuum: VACUUM ANALYZE table versus QUERY: autovacuum:VACUUM table
Next
From: M Tarkeshwar Rao
Date:
Subject: RE: Getting following error in using cursor to fetch the records froma large table in c language(current transaction is aborted, commands ignoreduntil end of transaction block)