Received: from localhost (maia-4.hub.org [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id ADCBD9FB891 for ; Thu, 21 Jun 2007 14:17:46 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 17387-07 for ; Thu, 21 Jun 2007 14:17:39 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from main2.mycybernet.net (main2.mycybernet.net [209.222.63.140]) by postgresql.org (Postfix) with ESMTP id 3C2EC9FB853 for ; Thu, 21 Jun 2007 14:17:39 -0300 (ADT) Received: from 227-54-222-209.mycybernet.net ([209.222.54.227] helo=phlogiston.dydns.org) by main2.mycybernet.net with esmtp (Exim 4.62) (envelope-from ) id 1I1QHq-0004RF-HB for pgsql-performance@postgresql.org; Thu, 21 Jun 2007 13:17:38 -0400 Received: by phlogiston.dydns.org (Postfix, from userid 1000) id 31888404E; Thu, 21 Jun 2007 13:17:33 -0400 (EDT) Date: Thu, 21 Jun 2007 13:17:33 -0400 From: Andrew Sullivan To: pgsql-performance@postgresql.org Subject: Re: vacuum a lot of data when insert only Message-ID: <20070621171733.GD5500@phlogiston.dyndns.org> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.9i X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200706/477 X-Sequence-Number: 25510 On Thu, Jun 21, 2007 at 07:53:54PM +0300, Sabin Coanda wrote: > Reading different references, I understand there is no need to vacuum a > table where just insert actions perform. That's false. First, you must vacuum at least once every 2 billion transactions. Second, if a table is INSERTed to, but then the INSERTing transaction rolls back, it leaves a dead tuple in its wake. My guess, from your posted example, is that you have the latter case happening, because you have removable rows (that's assuming you aren't mistaken that there's never a delete or update to the table). A -- Andrew Sullivan | ajs@crankycanuck.ca Unfortunately reformatting the Internet is a little more painful than reformatting your hard drive when it gets out of whack. --Scott Morris