Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jZa9R-000664-5J for pgsql-general@arkaria.postgresql.org; Fri, 15 May 2020 13:13:21 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jZa9P-00067J-C0 for pgsql-general@arkaria.postgresql.org; Fri, 15 May 2020 13:13:19 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jZa9P-00067A-3z for pgsql-general@lists.postgresql.org; Fri, 15 May 2020 13:13:19 +0000 Received: from aart.rice.edu ([168.7.56.48]) by magus.postgresql.org with esmtp (Exim 4.92) (envelope-from ) id 1jZa9J-0004K7-Uu for pgsql-general@lists.postgresql.org; Fri, 15 May 2020 13:13:18 +0000 Received: by aart.rice.edu (Postfix, from userid 18612) id 91571427F342; Fri, 15 May 2020 08:13:11 -0500 (CDT) Date: Fri, 15 May 2020 08:13:11 -0500 From: Kenneth Marshall To: Chris Withers Cc: pgsql-general@lists.postgresql.org Subject: Re: surprisingly slow creation of gist index used in exclude constraint Message-ID: <20200515131311.GR20002@aart.rice.edu> References: <789b3464-9bfc-2157-f4f4-71eb1da1050d@withers.org> <20200514151653.Horde.pMpsKZFmvfY6NTOOhfRssA2@webmail.rice.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk > > > >Hi Chris, > > > >This sounds like a candidate for pg_logical replicating from the > >old to new system. > > Can you point me to a good guide as to how to easily set this up for > one database and would work between pg 9.4 and pg 11.5? > > cheers, > > Chris Hi Chris, Here is on for 9.4 to 10.3: https://hunleyd.github.io/posts/Upgrading-PostgreSQL-from-9.4-to-10.3-with-pglogical/ and another article: https://www.depesz.com/2016/11/08/major-version-upgrading-with-minimal-downtime/ It is a pretty straightforward procedure and really cuts the time needed for an upgrade. Although, as Tom mentioned maybe just bumping your maintenance_work_mem up to 1g or so may make the index create time reasonable. Regards, Ken