X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id A175D529FC for ; Fri, 29 Jul 2005 10:34:03 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 40225-05 for ; Fri, 29 Jul 2005 13:33:52 +0000 (GMT) Received: from nproxy.gmail.com (nproxy.gmail.com [64.233.182.194]) by svr1.postgresql.org (Postfix) with ESMTP id A1D5D529D6 for ; Fri, 29 Jul 2005 10:33:48 -0300 (ADT) Received: by nproxy.gmail.com with SMTP id g2so140650nfe for ; Fri, 29 Jul 2005 06:33:52 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:reply-to:to:subject:cc:in-reply-to:mime-version:content-type:references; b=rBwgqqMoFA6gvpsDA/lgdqxwbvndWR/SyTfIlGh0BJ61kbic4Mthf6Dzit/2LdoUaV/kJSQsY4tUq6SU2pt2jtG03G67jAkE1CmTw8QuNQNp8iLMbORd2SgBSKeR1RDr+PPu+fvi9Bqpfszgtf17oy+eJOa8hV59nzdEP4ueiX4= Received: by 10.48.143.9 with SMTP id q9mr111386nfd; Fri, 29 Jul 2005 06:33:52 -0700 (PDT) Received: by 10.48.144.16 with HTTP; Fri, 29 Jul 2005 06:33:52 -0700 (PDT) Message-ID: Date: Fri, 29 Jul 2005 14:33:52 +0100 From: Guido Barosio Reply-To: Guido Barosio To: John Abel Subject: Re: Speed Up clean_pending.pl? Cc: pgsql-admin@postgresql.org In-Reply-To: <42E9F889.10604@plus.net> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_Part_4641_9001175.1122644032518" References: <42E9F889.10604@plus.net> X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.188 tagged_above=0 required=5 tests=AWL, HTML_30_40, HTML_MESSAGE, RCVD_BY_IP X-Spam-Level: X-Archive-Number: 200507/241 X-Sequence-Number: 18297 ------=_Part_4641_9001175.1122644032518 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline sql `set enable_seqscan to off;` may help here? Regards, g On 7/29/05, John Abel wrote: >=20 > Hi, >=20 > The company I'm at is running dbmirror, and we've found a problem with > clean_pending,pl, in that it takes an age to run. I've done some > looking about, and came with up this: >=20 > http://www.postgresql.org/docs/7.4/interactive/indexes.html >=20 > After reading the comments on that page, I explain'd the query that > clean_pending runs, and found that it is performing a sequential scan on > each of the tables. >=20 > Is there a way to make it use the indexes? >=20 > Any help would be appreciated. >=20 > Thanks >=20 > John >=20 > ---------------------------(end of broadcast)--------------------------- > TIP 6: explain analyze is your friend >=20 --=20 "Adopting the position that you are smarter than an automatic optimization algorithm is generally a good way to achieve less performance, not more" - Tom Lane. ------=_Part_4641_9001175.1122644032518 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Content-Disposition: inline sql `set enable_seqscan to off;` may help here?

Regards,
g



On 7/29/05, John Abel <jabel@plus.net<= /a>> wrote:
Hi,

The company I'm at is running dbmirror, and we've found a proble= m with
clean_pending,pl, in that it takes an age to run.  I've= done some
looking about, and came with up this:

http://www.postgresql.org/docs/7.4/interactive/indexes.html

Afte= r reading the comments on that page, I explain'd the query that
clean_pe= nding runs, and found that it is performing a sequential scan on
each of= the tables.

Is there a way to make it use the indexes?

Any help would be= appreciated.

Thanks

John

---------------------------(= end of broadcast)---------------------------
TIP 6: explain analyze is y= our friend



--
"Adopting the = position that you are smarter than an automatic
optimization algorithm i= s generally a good way to achieve less
performance, not more" - Tom= Lane. ------=_Part_4641_9001175.1122644032518--