Received: from maia.hub.org (unknown [200.46.204.183]) by mail.postgresql.org (Postfix) with ESMTP id 17A24632CA9 for ; Thu, 1 Apr 2010 10:53:20 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.183]) (amavisd-maia, port 10024) with ESMTP id 21175-08 for ; Thu, 1 Apr 2010 13:53:09 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from outbound.afilias.info (outbound.afilias.info [69.46.124.26]) by mail.postgresql.org (Postfix) with ESMTP id 9147B6334DB for ; Thu, 1 Apr 2010 10:53:09 -0300 (ADT) Received: from ms6.yyz2.afilias-ops.info ([10.50.129.112] helo=smtp.afilias.info) by outbound.afilias.info with esmtp (Exim 4.69) (envelope-from ) id 1NxKpL-0005Hd-90; Thu, 01 Apr 2010 13:52:55 +0000 Received: from tor-gateway.afilias.info ([199.15.87.4] helo=[10.10.46.12]) by smtp.afilias.info with esmtpsa (SSLv3:AES256-SHA:256) (Exim 4.69) (envelope-from ) id 1NxKpL-0005j6-8G; Thu, 01 Apr 2010 13:52:55 +0000 Subject: Re: How to fast the REINDEX From: Brad Nicholson To: raghavendra t Cc: Pierre C , Kevin Grittner , greg@2ndquadrant.com, hannu@2ndquadrant.com, sclark@netwolves.com, craig@postnewspapers.com.au, jorge_montero@homedecorators.com, pgsql-performance@postgresql.org In-Reply-To: References: <4BB3722F02000025000302BF@gw.wicourts.gov> <4BB40EE8.2080005@postnewspapers.com.au> <4BB47F15.4000307@netwolves.com> Content-Type: text/plain; charset="UTF-8" Date: Thu, 01 Apr 2010 09:52:55 -0400 Message-Id: <1270129975.5155.317.camel@bnicholson-desktop> Mime-Version: 1.0 X-Mailer: Evolution 2.26.1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.001 tagged_above=-10 required=5 tests=BAYES_50=0.001 X-Spam-Level: X-Archive-Number: 201004/7 X-Sequence-Number: 38257 On Thu, 2010-04-01 at 19:17 +0530, raghavendra t wrote: >=20 > Hi All, > =20 > System Config > --------------------- > CPU - Intel=C2=AE Xenon=C2=AE CPU > CPU Speed - 3.16 GHz > Server Model - Sun Fire X4150 > RAM-Size - 16GB >=20 > Steve: > So am I to understand I don't need to do daily reindexing as a > maintenance measure with 8.3.7 on FreeBSD. > =20 > My question is something like Steve's, why we should not do reindexing > as our maintenance task. I was doing reindex only to get > a best fit and not fall short of 90% hole, bcoz my table has lot of > updates and deletes. We also has the weekly maintance of VACUUM, but > still reindex takes lot of time.=20 This is your problem. You should enable autovaccuum, let the vacuums happen more frequently, and this problem will go away. You will still have to fix the underlying bloat a last time though. =20 --=20 Brad Nicholson 416-673-4106 Database Administrator, Afilias Canada Corp.