Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bNlla-0002R8-JT for pgsql-hackers@arkaria.postgresql.org; Thu, 14 Jul 2016 18:53:46 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84_2) (envelope-from ) id 1bNlla-0004rN-3R for pgsql-hackers@arkaria.postgresql.org; Thu, 14 Jul 2016 18:53:46 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bNllY-0004oz-4S; Thu, 14 Jul 2016 18:53:44 +0000 Received: from out5-smtp.messagingengine.com ([66.111.4.29]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84_2) (envelope-from ) id 1bNllV-0001Lt-54; Thu, 14 Jul 2016 18:53:42 +0000 Received: from compute2.internal (compute2.nyi.internal [10.202.2.42]) by mailout.nyi.internal (Postfix) with ESMTP id 77F3E20924; Thu, 14 Jul 2016 14:53:40 -0400 (EDT) Received: from frontend2 ([10.202.2.161]) by compute2.internal (MEProxy); Thu, 14 Jul 2016 14:53:40 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-sasl-enc:x-sasl-enc; s=smtpout; bh=ryBXwP2aJoI+nmE My+D1up9FMyw=; b=CwQCeXTvajVOsZsVQxi9BgXZvyfdeh//e9AHCGw8CHraoMw 4ETbYHDCgbcb2pnk3SRskHwDR1DdZzTXujSTgnw8BzuzTTH++LkG4ZAxHRXHHWk4 Q+vCaBb/NoqVUvZcM/4s0WwbN4NoMtGopRzhsmdFLOz7mvk8KWTFk5K++CGs= X-Sasl-enc: 3dSM2OqvedAci7NSkHIgtCXzjwsq0MltRy1fXpjxSVN2 1468522420 Received: from intern.anarazel.de (somacentral1.static.monkeybrains.net [162.217.75.74]) by mail.messagingengine.com (Postfix) with ESMTPA id D760ECCDB2; Thu, 14 Jul 2016 14:53:39 -0400 (EDT) Date: Thu, 14 Jul 2016 11:53:38 -0700 From: Andres Freund To: Vladimir Borodin Cc: pgsql-performance@postgresql.org, PostgreSQL-development Subject: Re: [PERFORM] 9.4 -> 9.5 regression with queries through pgbouncer on RHEL 6 Message-ID: <20160714185338.yo236a4rxkvlsmon@alap3.anarazel.de> References: <26239E39-A838-4611-B7BA-0E96D2DF3253@simply.name> <20160609222855.irpszcpo6qn4skq2@alap3.anarazel.de> <20160612215140.znmnl4mpzvgxjmgn@alap3.anarazel.de> <8C22C550-A2C3-48E1-AA00-07EB06EF0269@simply.name> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: X-Pg-Spam-Score: -2.6 (--) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-hackers Precedence: bulk Sender: pgsql-hackers-owner@postgresql.org On 2016-07-04 16:30:51 +0300, Vladimir Borodin wrote: > > > 13 июня 2016 г., в 21:58, Vladimir Borodin написал(а): > > > >> > >> 13 июня 2016 г., в 0:51, Andres Freund > написал(а): > >> > >> Hi Vladimir, > >> > >> Thanks for these reports. > >> > >> On 2016-06-13 00:42:19 +0300, Vladimir Borodin wrote: > >>> perf report -g -i pg9?_all.data >/tmp/pg9?_perf_report.txt > >> > >> Any chance you could redo the reports with --no-children --call-graph=fractal > >> added? The mode that includes child overheads unfortunately makes the > >> output hard to interpet/compare. > > > > Of course. Not sure if that is important but I upgraded perf for that (because --no-children option was introduced in ~3.16), so perf record and perf report were done with different perf versions. > > > > > > > > > > > > Also I’ve done the same test on same host (RHEL 6) but with 4.6 > > kernel/perf and writing perf data to /dev/shm for not loosing > > events. Perf report output is also attached but important thing is > > that the regression is not so significant: FWIW, you can instead use -F 300 or something to reduce the sampling frequency. > > root@pgload05g ~ # uname -r > > 4.6.0-1.el6.elrepo.x86_64 > > root@pgload05g ~ # cat /proc/sys/kernel/sched_autogroup_enabled > > 1 > > root@pgload05g ~ # /tmp/run.sh > > RHEL 6 9.4 71634 0.893 > > RHEL 6 9.5 54005 1.185 > > RHEL 6 9.6 65550 0.976 > > root@pgload05g ~ # echo 0 >/proc/sys/kernel/sched_autogroup_enabled > > root@pgload05g ~ # /tmp/run.sh > > RHEL 6 9.4 73041 0.876 > > RHEL 6 9.5 60105 1.065 > > RHEL 6 9.6 67984 0.941 > > root@pgload05g ~ # > > > > > > > > > > Andres, is there any chance that you would find time to look at those results? Are they actually useful? I don't really see anything suspicious in the profile. This looks more like a kernel scheduler issue than a postgres bottleneck one. It seems that somehow using nonblocking IO (started in 9.5) causes scheduling issues when pgbouncer is also local. Could you do perf stat -ddd -a sleep 10 or something during both runs? I suspect that the context switch ratios will be quite different. Andres -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers