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 1g390S-0007Qh-2T for pgsql-general@arkaria.postgresql.org; Fri, 21 Sep 2018 00:09:12 +0000 Received: from localhost ([127.0.0.1] helo=malur.postgresql.org) by malur.postgresql.org with esmtp (Exim 4.89) (envelope-from ) id 1g390Q-00041I-JG for pgsql-general@arkaria.postgresql.org; Fri, 21 Sep 2018 00:09:10 +0000 Received: from makus.postgresql.org ([2001:4800:1501:1::229]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g390Q-00041A-7l for pgsql-general@lists.postgresql.org; Fri, 21 Sep 2018 00:09:10 +0000 Received: from out1-smtp.messagingengine.com ([66.111.4.25]) by makus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.89) (envelope-from ) id 1g390N-00075b-Sp for pgsql-general@lists.postgresql.org; Fri, 21 Sep 2018 00:09:09 +0000 Received: from compute4.internal (compute4.nyi.internal [10.202.2.44]) by mailout.nyi.internal (Postfix) with ESMTP id 2AE5421FC2; Thu, 20 Sep 2018 20:09:07 -0400 (EDT) Received: from mailfrontend1 ([10.202.2.162]) by compute4.internal (MEProxy); Thu, 20 Sep 2018 20:09:07 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paquier.xyz; h= cc:content-type:date:from:in-reply-to:message-id:mime-version :references:subject:to:x-me-sender:x-me-sender:x-sasl-enc; s= fm2; bh=QWOoZ1jJanZGGVuIdRUBzZpaG1RcYcFIOMR8RjHy6p0=; b=aMg8dINi MaGe5SO6G9yN0blNvFpd4LaJ6Whp8Jr4IIf+xusjmUucwLsF4jwD+lYJaj/z79AN i1kdGYMpKcNhsDjI+0oYEL4XEnu8ILr8/WA+WXzs+HallzFLS4UEbmMIuv+fPo2T o1d+0z21XLuqXSgmS0z/CRhFcf1NuUj/PNCxkKeWC/EMVBCVyLgbPUVsKFs483QF ylyL/sW7FkxlFs/3h/5jFNnXTu3QrqQ+VoRbVuyt89JST5Jr8FIlV16pWyj5H2Q3 3awDx1xRrtnlf7+v6C95ypePGNabyb+wKx5YxAxWhoJmOmqjQpMmMnkenHFSH5gK u7YnVz58V30sKw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-sender :x-me-sender:x-sasl-enc; s=fm3; bh=QWOoZ1jJanZGGVuIdRUBzZpaG1RcY cFIOMR8RjHy6p0=; b=DbVDJ2r1+dkP0IReRMi+si+mAE8N0jORtG++Bzj2yMmEO MmyJyIr5GFCQcmBGMhus2MavM0P9f/BQ/Qouti21yFVR5ZABVN26cdg2zPbbT2az xUl+t016e/sJgyT5nWvoCK5hSlVK+VMaliJIeK9t+ilsBtFfzUnExu0/q+EbniI9 JHb+mOKgEHriydINTMy23tvaBpwYXYNPnO628nUEikpKVc0KmoJ8yt8ChN7wQPOv oPhC8sdL2R+CrrJfCWTOjkr9o0Xn8wrfqHaawfxc2LK3z3CeoZXCvXkx/qxqhvzU ITYZ0ruKREVMqIiZ4yIu7nWFJSHcT/cflsY+g3WAg== X-ME-Proxy: X-ME-Sender: Received: from paquier.xyz (c137162.net61215.cablenet.ne.jp [61.215.137.162]) by mail.messagingengine.com (Postfix) with ESMTPA id 4BBB7E462B; Thu, 20 Sep 2018 20:09:05 -0400 (EDT) Date: Fri, 21 Sep 2018 09:09:02 +0900 From: Michael Paquier To: Dylan Luong Cc: "pgsql-general@lists.postgresql.org" Subject: Re: help with startup slave after pg_rewind Message-ID: <20180921000902.GE1338@paquier.xyz> References: MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="oFbHfjnMgUMsrGjO" Content-Disposition: inline In-Reply-To: List-Id: List-Help: List-Subscribe: List-Post: List-Owner: List-Archive: Precedence: bulk --oFbHfjnMgUMsrGjO Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Wed, Sep 19, 2018 at 10:29:44PM +0000, Dylan Luong wrote: > After promoting slave to master, I completed a pg_rewind of the slave > (old master) to the new master. But when I try to start the slave I am > getting the following error. > > I tried to run pg_rewind again, but now it says I cannot do it as its > already same timeline. What did pg_rewind tell you after the first run? If you remove the set of WAL segments on the rewound instance and let it replay only segments =66rom the archive, are you able to get past? There is an inconsistency in the WAL records you are trying to replay. In this case a contrecord refers to a WAL record split across multiple pages. The WAL reader is expecting one, and cannot find it. And that's not normal. My bet is that something is wrong in your failover flow which you think is right. It is hard to get that right. -- Michael --oFbHfjnMgUMsrGjO Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEG72nH6vTowiyblFKnvQgOdbyQH0FAlukNp4ACgkQnvQgOdby QH3mzQ/+NnqV/EcrNE9TGg8hIraLC55v2PeVi6Fh2zNVS4Tfgj7ctBTUTXb+WY8z 1WeDVJ/xGOP8EwASoNDc8N0UWt0A6QvUork7q3216moa8lWHr00TqiPVLB0SEAMc NuYy+sDdePROMicXpA0Zf39JNM0KHTjEqPD24hIh9m1n06zbhTe3PjYGo7+ZNtQj Rmm6RfOSSN8KDRRiTR+wXxgn0perCuV+t8tOLjUq3FbXqHxUA7fVN0NJrFzlTjib PO434V6sDKAtovkfRBrsGQqstic6hWxi7vb5h103kgJLj1leiBnlT405ltapbwhP UFfDGTU4wOgtWjp1bXVMWX9n4jdx6JfZjOhsPD7QA+fUQjXRhtqeWvE1AK1iusnM muBw222A7Hp7IhQmWrAATuZid7fLv5e4iElIwcX9mKtn1fVB/uWm2MENpwfVDees wqhuROJkWPOK6M9quRSaysPp5BN8BbL/danCHY/eVeN/TxbULdSs0iV1BqDX1yxH Np9UbXQDuSSxHm2bzdiVK5ZxqzbHSQFugod9P5IyJ5ZzcwB7IvVC4IOsbCP6g7UF GqND1vMcbvolMAqYzPm6XDnm6fZhNUGVOBrkYU8btF4DQys0ZuZ20iKLIIwM8aR/ UQcdvLAxWuvGyx4fD12Lx13Qp6NNMVv4pGYCnn7bvKO40YH1KCs= =wzkq -----END PGP SIGNATURE----- --oFbHfjnMgUMsrGjO--