Re: autovacuum, exclude table

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 12.12.2011 16:25, Anibal David Acosta wrote:
I have a couple of tables with about 400millions of records increasing about
5 millions per day.

I think that disabling autovac over those tables, and enabling daily manual
vacuum (in some idle hour) will be better.

I am right?

Possibly. If the system is otherwise idle, it sounds sensible to do routine maintenance at that time.

Is possible to exclude autovacuum over some tables?

Sure, see http://www.postgresql.org/docs/9.1/static/sql-createtable.html#SQL-CREATETABLE-STORAGE-PARAMETERS

ALTER TABLE foo SET (autovacuum_enabled=false, toast.autovacuum_enabled = false);

It might be better, though, to let autovacuum enabled, and just do the additional manual VACUUM in the idle period. If the daily manual VACUUM is enough to keep the bloat within the autovacuum thresholds, autovacuum will never kick in. If it's not enough, then you probably want autovacuum to run.

--
  Heikki Linnakangas
  EnterpriseDB   http://www.enterprisedb.com

--
Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance


[Postgresql General]     [Postgresql PHP]     [PHP Users]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Yosemite]

  Powered by Linux