Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 9D7E01337C00 for ; Tue, 29 Mar 2011 13:01:42 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 13642-06 for ; Tue, 29 Mar 2011 16:01:24 +0000 (UTC) X-Greylist: delayed 00:05:17.29084 by SQLgrey-1.7.6 Received: from out3.smtp.messagingengine.com (out3.smtp.messagingengine.com [66.111.4.27]) by mail.postgresql.org (Postfix) with ESMTP id 572FF1337BB7 for ; Tue, 29 Mar 2011 13:01:24 -0300 (ADT) Received: from compute2.internal (compute2.nyi.mail.srv.osa [10.202.2.42]) by gateway1.messagingengine.com (Postfix) with ESMTP id B672220E2A for ; Tue, 29 Mar 2011 11:56:05 -0400 (EDT) Received: from web1.messagingengine.com ([10.202.2.211]) by compute2.internal (MEProxy); Tue, 29 Mar 2011 11:56:05 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d=messagingengine.com; h=message-id:from:to:mime-version:content-transfer-encoding:content-type:subject:date; s=smtpout; bh=MUOcwwF9GZFhWmO1/u43rB/wHT4=; b=Vnbj1FeVXIE4mahB81SC4SZgRDEZYNQSkY7Tr1ghtrNKNKcNnvZSvlJ+HDXSnVJustUYIstkxof2J4sRLSui8VN6jk0TOuT0LtdjDyz3LpbMfHoIMDtkBC0H2x/wPOZIxng5Cgagy1UZn1mk6jD/874I5YyJmDxay/tjfm4AlO8= Received: by web1.messagingengine.com (Postfix, from userid 99) id 97D673CD271; Tue, 29 Mar 2011 11:56:05 -0400 (EDT) Message-Id: <1301414165.2351.1435136873@webmail.messagingengine.com> X-Sasl-Enc: yl5PXjHa8EN/+yz4mNuWiLJ2B1kTd/4VViGeqb87EoaQ 1301414165 From: "Nic Chidu" To: pgsql-admin@postgresql.org MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii" X-Mailer: MessagingEngine.com Webmail Interface Subject: full vacuum of a very large table Date: Tue, 29 Mar 2011 11:56:05 -0400 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201103/256 X-Sequence-Number: 37128 Got a situation where a 130 mil rows (137GB) table needs to be brought down in size to 10 mil records (most recent) with the least amount of downtime. Doing a full vacuum would be faster on: - 120 mil rows deleted and 10 mil active (delete most of them then full vacuum) - 10 mil deleted and 120 mil active. (delete small batches and full vacuum after each delete). Any other suggestions? Thanks, Nic