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 1gvpN3-0000qd-1e for pgsql-general@arkaria.postgresql.org; Mon, 18 Feb 2019 20:18:33 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1gvpE1-0001mg-HX for pgsql-general@arkaria.postgresql.org; Mon, 18 Feb 2019 20:09:13 +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 1gvpE1-0001mT-58 for pgsql-general@lists.postgresql.org; Mon, 18 Feb 2019 20:09:13 +0000 Received: from mail-it1-x12e.google.com ([2607:f8b0:4864:20::12e]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA1:256) (Exim 4.89) (envelope-from ) id 1gvpDy-0000GA-IV for pgsql-general@lists.postgresql.org; Mon, 18 Feb 2019 20:09:11 +0000 Received: by mail-it1-x12e.google.com with SMTP id y184so898501itc.1 for ; Mon, 18 Feb 2019 12:09:10 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:date:message-id:from:to:subject; bh=HrBd6cjAt/ERVljw6vMWQIb0aM9IV5QKwCeAV7jpfko=; b=mIlB4yVL7VOQAdJUKmrUTcUC2B8ZloNr9xB9DivEStXKpDdF0y9qCYkz3WJO4LSjEg ysKnPPqE7BOc9yPz4iw8V0Cwh74AwNJCK7R4evNrFmmVCTIQcurP59bb67ZGM5OQ0hPR 4+/v1O1P4gYYD4mSdF+exGGvurXs5oR4ogvDtA2RoMElHe77H375tfS+WCurZ8h4M0iU 3i3nYtD+3GyDU5CPKclLsY6ybi/YZstBAfAxN2lqB3ZrkWtB5fmjy5SBD+TRP3ahRHwo 52BZZPnD/wG5UeqXfuGzklJZCiAAVhxeXU/9lTded1EcJeStNrH5U4Exy31/Ejt8H+xD mACg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:date:message-id:from:to:subject; bh=HrBd6cjAt/ERVljw6vMWQIb0aM9IV5QKwCeAV7jpfko=; b=j0V/xhKhQB1o3nsYDut1X8NEwHHFlVyiAjn5NDLhMzE1nOdsI9N/5SQOTtMi3FYcSa 7TPmJcoX53Key3kDzT5V9uu5Ipiw3tXYXcJKFmJRtJO1ChfPiz8Z7G4ew1xzZf89UYtO wZ9iWIRMyTEjFg/fyb9ubFMkheX+uQg/2ohRWYWZs3XLgA9PlnBUGHwSgd0hQ4cE7SWT ckV/MY8T4gOhpon1XwtUE5Epax3YwFGPND/LBheSZtEeQwpmYT20SScDDhOfwT7KgP85 1AFUtYoPM6sbDTlgVzZqUVT/ddWLFeVgBUtY5Q4FO5nXLJHPLxP4va9iT+8O4Gf5ziVP nGAQ== X-Gm-Message-State: AHQUAuaaW72fqi+LeeIe9G/tGyVXGjc5Kib9Fj9zG7JyglthhUpx1mpm 4tjmtbRtUCdLk87Sbo4sz+fT2iNG X-Google-Smtp-Source: AHgI3IaYu9pWA38w5jtWRHq05bL8P/FVQUyO/Sh/RlWdHzPTs7g7m7RJNcAeXJKCzj3on0WHU4Kgeg== X-Received: by 2002:a02:b806:: with SMTP id o6mr13603719jam.128.1550520549430; Mon, 18 Feb 2019 12:09:09 -0800 (PST) Received: from localhost (166.193.193.35.bc.googleusercontent.com. [35.193.193.166]) by smtp.gmail.com with ESMTPSA id c31sm157282itd.25.2019.02.18.12.09.08 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 18 Feb 2019 12:09:08 -0800 (PST) Mime-Version: 1.0 Date: Mon, 18 Feb 2019 12:08:59 -0800 X-Mailer: Polymail Message-ID: <5c6b0bc5828e9f3dde000002@polymail.io> From: =?UTF-8?q?Mart=C3=ADn_Fern=C3=A1ndez?= To: "pgsql-generallists.postgresql.org" X-Polymail-Id: <5c6b0bc5828e9f3dde000002@polymail.io> Subject: PG Upgrade with hardlinks, when to start/stop master and replicas Content-Type: multipart/alternative; boundary=44253934f1c3b51537b1b98a0af4e809db15b956df1260ff07ef0b0e4565 List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --44253934f1c3b51537b1b98a0af4e809db15b956df1260ff07ef0b0e4565 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Hello everyone! We are about to upgrade a 6 instance cluster from pg92 to pg10 using pg_upg= rade with hardlinks and rsync. Our preliminary tests are working really good so far but on question has po= pped up that we feel is really critical because it has an important impact = on our failover plan. After reading the pg_upgrade documentation multiple times, it seems that af= ter running pg_upgrade on the=C2=A0primary=C2=A0instance, we can't start it= until we run rsync from the=C2=A0primary=C2=A0to the=C2=A0standby. I'm und= erstanding this from the following section in the pg_upgrade manual page. ``` You will not be running pg_upgrade on the standby servers, but rather rsync= on the =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0primary. Do not start any servers = yet. ``` I'm understanding the `any` as=C2=A0primary=C2=A0and=C2=A0standbys. On the other hand, we've been doing tests that start the=C2=A0primary=C2=A0= instance as soon as pg_upgrade is done. This tests have worked perfectly fi= ne so far. We make the rsync call with the=C2=A0primary=C2=A0instance runni= ng and the=C2=A0standby=C2=A0can start later on after rsync is done and we = copy the new configuration files. If what we are doing is wrong, we need to run `rsync` before starting the p= rimary=C2=A0instance, that would mean that the primary and the=C2=A0standby= =C2=A0are not usable if pg10 doesn't start correctly in the primary right ?= =C2=A0 I hope my question is clear enough!=C2=A0 Best, Mart=C3=ADn --44253934f1c3b51537b1b98a0af4e809db15b956df1260ff07ef0b0e4565 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=UTF-8 3D""
Hello everyone!
We are about to upgrade a 6 instance cluster from pg92 to pg10 using = pg_upgrade with hardlinks and rsync.

Our preliminary tests are worki= ng really good so far but on question has popped up that we feel is really = critical because it has an important impact on our failover plan.

Af= ter reading the pg_upgrade documentation multiple times, it seems that afte= r running pg_upgrade on the pr= imary instance, we can't start it until we run rsync from the&n= bsp;primary to the = ;standby. I'm understanding = this from the following section in the pg_upgrade manual page.


`= ``
You will not be running pg_upgrade on the standby servers, but r= ather rsync on the
           prima= ry. Do not start any servers yet.
```

I'm understanding the `an= y` as primary and&= nbsp;standbys.

On th= e other hand, we've been doing tests that start the primary instance as soon as pg_upgrade is= done. This tests have worked perfectly fine so far. We make the rsync call= with the primary = instance running and the stand= by can start later on after rsync is done and we copy the new c= onfiguration files.

If what we are doing is wrong, we need to run `r= sync` before starting the primary instance, that would mean that the p= rimary and the standby&= nbsp;are not usable if pg10 doesn't start correctly in the primary right ?&= nbsp;

I hope my question is clear enough! 

Best,
Mart=C3=ADn
--44253934f1c3b51537b1b98a0af4e809db15b956df1260ff07ef0b0e4565--