Received: from malur.postgresql.org ([2a02:16a8:dc51::56]) by arkaria.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g4cxG-0006ne-Sk for pgsql-performance@arkaria.postgresql.org; Tue, 25 Sep 2018 02:20:03 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g4cxF-0005nj-BJ for pgsql-performance@arkaria.postgresql.org; Tue, 25 Sep 2018 02:20:01 +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_SHA384:256) (Exim 4.89) (envelope-from ) id 1g4cxF-0005nc-00 for pgsql-performance@lists.postgresql.org; Tue, 25 Sep 2018 02:20:01 +0000 Received: from mail-it1-x144.google.com ([2607:f8b0:4864:20::144]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1g4cxC-00058F-Do for pgsql-performance@lists.postgresql.org; Tue, 25 Sep 2018 02:20:00 +0000 Received: by mail-it1-x144.google.com with SMTP id f14-v6so13446544ita.4 for ; Mon, 24 Sep 2018 19:19:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=telsasoft-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=oL0RaZBYdyyupARKnC9EBukbJmdxmNWoyHcYevH8E5I=; b=jXxXHKhefuJI04D4KQOWFnKTSJbZjOrqP6oJXobEDKSo/lW4B0Vaf0cMsN6XJiT3sS ybIMD0W81yMhnRH85O9+Wtaa1v75dK16EAHnPuzFU8bSsNFosXy7rfsnOxhbsb8E/W6a NvFXuSFzQzHsPTvGoUxsHL5MaIhkScnV75ONBY0jv/3Zpqj8eHf9eFfUBAI2BigLk/+U pAyy60+B03M/6OMqFtSnAXJH8Eow8UKEoz1dz1y5fYOxb9nv7MFGsnRGFvi6s6/ZKuYd U8+V6FwVVXRYId4YF+yqf/obLL2YdgdV5EIOtaVskgM7m0wajdjUs+ESgTDwCcWaA2Xv u+eQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=oL0RaZBYdyyupARKnC9EBukbJmdxmNWoyHcYevH8E5I=; b=RAv99NhWvjv26vly8qpTwZo7z4Ok/awy099ChE1Hydctl5bkONXSCR7dmwi4Y1W/ZD oCoCAA4LSrvnc3P8DmtKX1Q0s5sSce7PBL9KVWFvzytJq3dzoc1m+4u4ZGdgAbV6vMsd 0/PottcM/hCeC+c4YKjg5VJRRQg/9jO9aQlpJ4u5pUBh5o2K0gpgIlb+t6ocKLe95Spu 5+b6OnV1OTn/Ani6tW1u37PYOjj01BsW2Eb/SALHu0ly+Hw2+s89l8zetN6D+VXkLRRS 6OZct3rA1xbf03MupHwXBQwG9fgKC4RlsUqAmhm+EiIfN0ArOjZoUleq01ZJNrFm4wRe WaRg== X-Gm-Message-State: ABuFfojcfAZ/owiDx+suiqCsBSAn72WbcWgueX6id043R8UMGBcrR+WO 5ZDXE4HCFxp3dqrDcx6OPCc7vQ== X-Google-Smtp-Source: ACcGV61TCBkKv8KNIui9kpXelMr94Zp4yHL/Pl0Iv0DLAiZ1VSIYDPWYzdhuOdbC3OhIxV9CyNITsQ== X-Received: by 2002:a24:d485:: with SMTP id x127-v6mr1022569itg.82.1537841996399; Mon, 24 Sep 2018 19:19:56 -0700 (PDT) Received: from pryzbyj (charmander.telsasoft.com. [50.244.222.1]) by smtp.gmail.com with ESMTPSA id a63-v6sm438496itc.38.2018.09.24.19.19.55 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 24 Sep 2018 19:19:55 -0700 (PDT) Received: by pryzbyj (Postfix, from userid 1000) id CC3D68025FB; Mon, 24 Sep 2018 21:19:54 -0500 (CDT) Date: Mon, 24 Sep 2018 21:19:54 -0500 From: Justin Pryzby To: Vladimir Ryabtsev Cc: f.pardi@portavita.eu, pgsql-performance@lists.postgresql.org Subject: Re: Why could different data in a table be processed with different performance? Message-ID: <20180925021954.GW2471@telsasoft.com> References: <4dbb8bea-bea3-74d8-a537-36bb9864cb9f@portavita.eu> <20180924233423.GV2471@telsasoft.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.23 (2014-03-12) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk On Mon, Sep 24, 2018 at 05:59:12PM -0700, Vladimir Ryabtsev wrote: > > I *suspect* VACUUM FULL won't help, since (AIUI) it copies all "visible" ... > I am going copy the slow range into a table nearby and see if it reproduces > (I hope "INSERT INTO t2 SELECT * FROM t1 WHERE ..." will keep existing > order of rows). Then I could try the same after CLUSTER. If it does an index scan, I think that will badly fail to keep the same order of heap TIDs - it'll be inserting rows in ID order rather than in (I guess) reverse ID order. Justin