Received: from localhost (maia-2.hub.org [200.46.204.187]) by postgresql.org (Postfix) with ESMTP id B12319FBDC7 for ; Wed, 21 Feb 2007 16:51:37 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.187]) (amavisd-new, port 10024) with ESMTP id 67965-06 for ; Wed, 21 Feb 2007 16:51:30 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from lists.commandprompt.com (host-254.commandprompt.net [207.173.203.254]) by postgresql.org (Postfix) with ESMTP id 6627E9FBDF1 for ; Wed, 21 Feb 2007 16:51:33 -0400 (AST) Received: from perhan.alvh.no-ip.org (216-155-79-222.bk1-dsl.surnet.cl [216.155.79.222]) (authenticated bits=0) by lists.commandprompt.com (8.13.7/8.13.6) with ESMTP id l1LKpY8A022268; Wed, 21 Feb 2007 12:51:35 -0800 Received: by perhan.alvh.no-ip.org (Postfix, from userid 1000) id 59F3D329ED; Wed, 21 Feb 2007 17:51:30 -0300 (CLST) Date: Wed, 21 Feb 2007 17:51:30 -0300 From: Alvaro Herrera To: Mark Stosberg Cc: pgsql-performance@postgresql.org Subject: Re: Auto-Vacuum in 8.1 was ineffective for me. 8.2 may work better? Message-ID: <20070221205130.GD25424@alvh.no-ip.org> Mail-Followup-To: Mark Stosberg , pgsql-performance@postgresql.org References: <20070221185544.GX25424@alvh.no-ip.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.13 (2006-08-11) X-Virus-Scanned: ClamAV version 0.88.5, clamav-milter version 0.88.5 on projects.commandprompt.com X-Virus-Status: Clean X-Greylist: Sender succeded SMTP AUTH authentication, not delayed by milter-greylist-1.6 (lists.commandprompt.com [192.168.2.159]); Wed, 21 Feb 2007 12:51:35 -0800 (PST) X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.189 tagged_above=0 required=5 tests=AWL, BAYES_50, FORGED_RCVD_HELO X-Spam-Level: X-Archive-Number: 200702/223 X-Sequence-Number: 23277 Mark Stosberg wrote: > Alvaro Herrera wrote: > > Mark Stosberg wrote: > >> When I upgraded a busy database system to PostgreSQL 8.1, I was excited > >> about AutoVacuum, and promptly enabled it, and turned off the daily > >> vacuum process. > >> > >> ( > >> I set the following, as well as the option to enable auto vacuuming > >> stats_start_collector = true > >> stats_row_level = true > >> ) > >> > >> I could see in the logs that related activity was happening, but within > >> a few days, the performance became horrible, and enabling the regular > >> vacuum fixed it. > >> > >> Eventually autovacuum was completely disabled. > > This has been tracked down to a bug in 8.1's Windows port. See > > http://people.planetpostgresql.org/mha/index.php?/archives/134-8.1-on-win32-pgstat-and-autovacuum.html > > Thanks for the response Alvaro. This would have been on FreeBSD. Oh, maybe I misread your OP :-) With "completely disabled" I thought you meant it was "frozen", i.e., it ran, but did nothing. > Let me ask the question a different way: Is simply setting the two > values plus enabling autovacuuming generally enough, or is further > tweaking common place? I assume your FSM configuration is already good enough? What you should do is find out what tables are not getting vacuumed enough (e.g. by using contrib/pgstattuple repeteadly and seeing where is dead space increasing) and tweak the autovacuum settings to have them vacuumed more often. This is done by inserting appropriate tuples in pg_autovacuum. -- Alvaro Herrera http://www.CommandPrompt.com/ The PostgreSQL Company - Command Prompt, Inc.