Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VYH3N-00085w-GZ for pgsql-performance@arkaria.postgresql.org; Mon, 21 Oct 2013 15:05:57 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.80) (envelope-from ) id 1VYH3N-0007t0-0P for pgsql-performance@arkaria.postgresql.org; Mon, 21 Oct 2013 15:05:57 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VYH3L-0007sr-VS for pgsql-performance@postgresql.org; Mon, 21 Oct 2013 15:05:56 +0000 Received: from sam.nabble.com ([216.139.236.26]) by magus.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1VYH33-0000Ra-GA for pgsql-performance@postgresql.org; Mon, 21 Oct 2013 15:05:54 +0000 Received: from [192.168.236.26] (helo=sam.nabble.com) by sam.nabble.com with esmtp (Exim 4.72) (envelope-from ) id 1VYH2z-0007FC-Pz for pgsql-performance@postgresql.org; Mon, 21 Oct 2013 08:05:33 -0700 Date: Mon, 21 Oct 2013 08:05:33 -0700 (PDT) From: sparikh To: pgsql-performance@postgresql.org Message-ID: <1382367933794-5775257.post@n5.nabble.com> In-Reply-To: <526460B7.3020008@fuzzy.cz> References: <1381869626548-5774673.post@n5.nabble.com> <1382291901534-5775181.post@n5.nabble.com> <526460B7.3020008@fuzzy.cz> Subject: Re: Hot Standby performance issue MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Pg-Spam-Score: -0.8 (/) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-performance Precedence: bulk Sender: pgsql-performance-owner@postgresql.org Stupid question - when you say that a query is fast on primary but slow on standby, are you referring to exactly the same query, including parameter values? Yes . It is exactly and exactly the same query with the same parameters. Yes, it sounds stupid but that is what happening. Though plan says it is 18ms it runs for more than 15-20 mins and finally returns with conflict error : " ERROR: canceling statement due to conflict with recovery " Even the to run execute plan itself takes very long on standby. Just to get the execute plan on standby is turning out big deal. Regarding IO spike, yes I can understand that if data is not available in the memory then it has to get it from disk. But the thing is it remains there as much time until query returns with Query conflict error. Thanks again. -- View this message in context: http://postgresql.1045698.n5.nabble.com/Hot-Standby-performance-issue-tp5774673p5775257.html Sent from the PostgreSQL - performance mailing list archive at Nabble.com. -- Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance