X-Original-To: pgsql-admin-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id 2100B9FA3A0 for ; Wed, 13 Sep 2006 13:15:45 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 55269-02 for ; Wed, 13 Sep 2006 13:15:34 -0300 (ADT) X-Greylist: delayed 00:08:26.147404 by SQLgrey- Received: from wolf.urban.csuohio.edu (wolf.urban.csuohio.edu [137.148.96.16]) by postgresql.org (Postfix) with ESMTP id 8E1C89FA0CC for ; Wed, 13 Sep 2006 13:15:32 -0300 (ADT) Received: from [137.148.93.10] (UB-LL-01137-148-93-10.dhcp.csuohio.edu [137.148.93.10]) by wolf.urban.csuohio.edu (8.13.7/8.13.7) with ESMTP id k8DG6PqK003512 for ; Wed, 13 Sep 2006 12:06:25 -0400 (EDT) Message-ID: <45082C83.5040206@urban.csuohio.edu> Date: Wed, 13 Sep 2006 12:06:27 -0400 From: Ellen Cyran User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7.11) Gecko/20050728 X-Accept-Language: en-us, en MIME-Version: 1.0 To: "pgsql-admin@postgresql.org" Subject: After how many updates should a vacuum be performed? Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-MGLCUA-CSU-MailScanner-Information: Please contact the help desk (x2200) for more information X-MGLCUA-CSU-MailScanner: Found to be clean X-MGLCUA-CSU-MailScanner-SpamCheck: not spam, SpamAssassin (notcached, score=-4.399, required 6, autolearn=not spam, ALL_TRUSTED -1.80, BAYES_00 -2.60) X-MGLCUA-CSU-MailScanner-From: ellen@urban.csuohio.edu X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0 tagged_above=0 required=5 tests= X-Spam-Level: X-Archive-Number: 200609/109 X-Sequence-Number: 23023 We have a database that periodically we perform large updates, around a million records, after that the vacuum will run for 12 hours without completing. After that, I typically remove the 2 indexes and 1 constraint on the largest table, 7 million records, and the vacuum will complete in a couple of hours and the indexes can be recreated in a half hour. After how many updates should a vacuum be performed? Do indexes need to be recreated periodically? Would auto vacuuming help in this case? Any suggestions on tuning? The database is in PostgreSQL 8.0.7. Thanks. Ellen