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 1iD9if-0004H3-Et for pgsql-general@arkaria.postgresql.org; Wed, 25 Sep 2019 16:00:45 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1iD9ie-0007ek-3y for pgsql-general@arkaria.postgresql.org; Wed, 25 Sep 2019 16:00:44 +0000 Received: from makus.postgresql.org ([2001:4800:3e1:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1iD9id-0007Rk-Kf for pgsql-general@lists.postgresql.org; Wed, 25 Sep 2019 16:00:43 +0000 Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1iD9ib-0003Jd-BT for pgsql-general@lists.postgresql.org; Wed, 25 Sep 2019 16:00:42 +0000 Received: from sss1.sss.pgh.pa.us (localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.4/8.14.4) with ESMTP id x8PG0dEg018539; Wed, 25 Sep 2019 12:00:39 -0400 From: Tom Lane To: Ron cc: pgsql-general@lists.postgresql.org Subject: Re: Upgrading old server In-reply-to: References: <8818b028-bd2d-412e-d4e3-e29c49ffee17@zunibal.com> <20190925142933.GH6888@msg.df7cb.de> Comments: In-reply-to Ron message dated "Wed, 25 Sep 2019 10:37:36 -0500" MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <18537.1569427239.1@sss.pgh.pa.us> Content-Transfer-Encoding: quoted-printable Date: Wed, 25 Sep 2019 12:00:39 -0400 Message-ID: <18538.1569427239@sss.pgh.pa.us> List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk Ron writes: > On 9/25/19 9:29 AM, Christoph Berg wrote: >> Re: Ekaterina Amez 2019-09-25 <8818b028-bd2d-412e-d4e3-e29c49ffee17@zun= ibal.com> >>> We've decided to upgrade our PostgreSQL production servers. First task= is >>> remove an old v7.14 version. It was supposed to be upgraded to a v8.4 >>> server. The server was installed, several databases where released her= e but >>> v7.4 was never migrated. The plan is pg_dump this database and psql it= to >>> existing 8.4 server. After this, we'll pg_upgrade. >> If you doing dump-restore anyway, why not restore into v11 rightaway? > Since it's recommend to run the newer pg_dump on the older database, I'v= e = > got to wonder if v11 pg_dump can read the v7.4 on-disk structures. We dropped support for pre-8.0 source servers in pg_dump sometime recently, though I forget if v11 is affected by that or not. You could try just dumping with 7.4's pg_dump and seeing if the output will load into v11 --- ideally it would, but I'd not be surprised if there are issues that have to be resolved manually. Or, if you have 8.4's pg_dump at hand, try using that. 7.4 to 11 is a big jump to be doing in one step. There's definitely something to be said for porting to an intermediate release, just to break down the work into smaller chunks. But I'd go for halfway between, which if I counted releases correctly would be about 9.1, not 8.4. regards, tom lane