Received: from localhost (unknown [200.46.204.183]) by postgresql.org (Postfix) with ESMTP id 2B6992E003B for ; Tue, 25 Mar 2008 09:24:04 -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 58362-10 for ; Tue, 25 Mar 2008 09:24:01 -0300 (ADT) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.5 Received: from gv-out-0910.google.com (gv-out-0910.google.com [216.239.58.190]) by postgresql.org (Postfix) with ESMTP id DA1BD2E002C for ; Tue, 25 Mar 2008 09:24:00 -0300 (ADT) Received: by gv-out-0910.google.com with SMTP id y18so609316gvf.7 for ; Tue, 25 Mar 2008 05:23:59 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=qBPz0aQpzHrkY2rfJ+uWIAc8Ds0wM9YCZBaSOtnbsOw=; b=Ob+rqkBcOsiOsGjfczhLO/5IZ6NyRxr0oYlEyxOZLM3SjHCV61gsZF2Ox3sxncPjH6wKl57fNCkSNlptZd4t9bKjpIVkzkN5t8ClLMgitaa1754Vsvrm4H83w9WvMdZ3rbbGqYHGkS38lrZw6aiP159BNV2bi8kD/fPGCn1V8WM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=pmK4kZCDLuDQbYWoED/a1/yOhvNAGfSeXRwIpkY2JRJZDSG7TEZMMlxmlEM2Gtde/HUo4weGZnNQ4Q4HLbTnKtuPIEmBSWinX2MS0irx+wYpaf/zUsMbBgKrR5oKz0IPJD5F/6jlxvecdGedLr0wNkZXetDjuK8f+S2ta7i92C4= Received: by 10.150.229.16 with SMTP id b16mr3948876ybh.115.1206447838946; Tue, 25 Mar 2008 05:23:58 -0700 (PDT) Received: by 10.150.97.21 with HTTP; Tue, 25 Mar 2008 05:23:58 -0700 (PDT) Message-ID: <2e78013d0803250523w28a16315w3e5ec0846155c8b7@mail.gmail.com> Date: Tue, 25 Mar 2008 17:53:58 +0530 From: "Pavan Deolasee" To: "Andreas Kretschmer" Subject: Re: increasing shared buffer slow downs query performance. Cc: pgsql-performance@postgresql.org In-Reply-To: <20080324100718.GA7822@KanotixBox> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <20080324100718.GA7822@KanotixBox> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200803/468 X-Sequence-Number: 29422 On Mon, Mar 24, 2008 at 3:37 PM, Andreas Kretschmer wrote: > petchimuthu lingam schrieb: > > > > Hi friends, > > > > I am using postgresql 8.1, I have shared_buffers = 50000, now i execute the > > query, it takes 18 seconds to do sequential scan, when i reduced to 5000, it > > takes one 10 seconds, Why. > > Wild guess: the second time the data are in the filesystem cache. > Another wild possibility is that the first query sets the hint bits for the rows involved and hence the second time it runs fast. May be you want to run the query few times in both the settings and then compare. Thanks, Pavan -- Pavan Deolasee EnterpriseDB http://www.enterprisedb.com