Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id CECCD64FD1A for ; Fri, 22 Aug 2008 18:31:18 -0300 (ADT) Received: from postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 14389-04 for ; Fri, 22 Aug 2008 18:31:09 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from gwmta.wicourts.gov (gwmta.wicourts.gov [165.219.244.99]) by postgresql.org (Postfix) with ESMTP id C8F5C64FCDF for ; Fri, 22 Aug 2008 18:31:11 -0300 (ADT) Received: from Courts-MTA by gwmta.wicourts.gov with Novell_GroupWise; Fri, 22 Aug 2008 16:31:08 -0500 Message-Id: <48AEE9C3.EE98.0025.0@wicourts.gov> X-Mailer: Novell GroupWise Internet Agent 7.0.3 Date: Fri, 22 Aug 2008 16:30:59 -0500 From: "Kevin Grittner" To: "Fernando Hevia" , Subject: Re: Big delete on big table... now what? References: <042c01c90496$ca8725f0$8f01010a@iptel.com.ar> In-Reply-To: <042c01c90496$ca8725f0$8f01010a@iptel.com.ar> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 8bit Content-Disposition: inline X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200808/287 X-Sequence-Number: 31168 >>> "Fernando Hevia" wrote: > I have a table with over 30 million rows. Performance was dropping steadily > so I moved old data not needed online to an historic table. Now the table > has about 14 million rows. I don't need the disk space returned to the OS > but I do need to improve performance. Will a plain vacuum do or is a vacuum > full necessary? > *Would a vacuum full improve performance at all? If this database can be out of production for long enough to run it (possibly a few hours, depending on hardware, configuration, table width, indexes) your best option might be to CLUSTER and ANALYZE the table. It gets more complicated if you can't tolerate down-time. -Kevin