Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i5PUo-0007XO-V3 for pgsql-general@arkaria.postgresql.org; Wed, 04 Sep 2019 07:14:27 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1i5PUn-0008Tc-Oh for pgsql-general@arkaria.postgresql.org; Wed, 04 Sep 2019 07:14:25 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1i5PUn-0008TV-FP for pgsql-general@lists.postgresql.org; Wed, 04 Sep 2019 07:14:25 +0000 Received: from serveurmail01.codata.be ([82.146.123.190]) by magus.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1i5PUl-0001BI-DJ for pgsql-general@lists.postgresql.org; Wed, 04 Sep 2019 07:14:25 +0000 Received: from localhost (localhost.localdomain [127.0.0.1]) by serveurmail01.codata.be (Postfix) with ESMTP id E8A40900CC for ; Wed, 4 Sep 2019 09:14:22 +0200 (CEST) X-Virus-Scanned: amavisd-new at serveurmail01.codata.be Received: from serveurmail01.codata.be ([127.0.0.1]) by localhost (serveurmail01.codata.be [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 2yUGMOPSdnTt for ; Wed, 4 Sep 2019 09:14:22 +0200 (CEST) Received: from [10.0.0.100] (38-179-112-217.fix.adsl.belcenter.be [217.112.179.38]) by serveurmail01.codata.be (Postfix) with ESMTPSA id 0957C900B8 for ; Wed, 4 Sep 2019 09:14:21 +0200 (CEST) Subject: Re: Slow statement using parallelism after 9.6>11 upgrade To: pgsql-general@lists.postgresql.org References: <872bffe7-82d0-86db-e3d6-2e20b1a72c4b@codata.eu> <23865.1567518191@sss.pgh.pa.us> <12ad6d06-6897-c3f1-a681-62191fadfa90@codata.eu> Reply-To: arnaud.listes@codata.eu From: "Arnaud L." Message-ID: <76820bc0-b570-3f00-1335-51d85f5012e5@codata.eu> Date: Wed, 4 Sep 2019 09:14:21 +0200 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <12ad6d06-6897-c3f1-a681-62191fadfa90@codata.eu> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: fr Content-Transfer-Encoding: 8bit List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Le 04/09/2019 à 09:04, Arnaud L. a écrit : > Tom, I can confirm that with up to date statistics the planner is still > lost. > I did a REINDEX to rule out a broken index and the estimate is still in > the 100k+ range. Sorry, I meant 1M+ range. EXPLAIN ANALYZE select id from planet_osm_ways WHERE nodes && ARRAY[123456789::bigint]; (parallel_workers = 0 on the table as per Paul's recommandation) : Bitmap Heap Scan on planet_osm_ways (cost=11582.45..3535447.30 rows=1419000 width=8) (actual time=0.198..0.199 rows=1 loops=1) Recheck Cond: (nodes && '{123456789}'::bigint[]) Heap Blocks: exact=1 -> Bitmap Index Scan on planet_osm_ways_nodes_idx (cost=0.00..11227.70 rows=1419000 width=0) (actual time=0.151..0.151 rows=1 loops=1) Index Cond: (nodes && '{123456789}'::bigint[]) Planning Time: 0.260 ms Execution Time: 0.249 ms Regards -- Arnaud