pg_rewind could not find previous WAL record at 0/4B000060: invalid record length at 0/4B000060: wanted 24, got 0

From: Yong Zhang <hiscal(at)outlook(dot)com>
To: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: pg_rewind could not find previous WAL record at 0/4B000060: invalid record length at 0/4B000060: wanted 24, got 0
Date: 2017-07-06 08:10:53
Message-ID: HK2PR0301MB104359382242EFEEB934B3DEC0D50@HK2PR0301MB1043.apcprd03.prod.outlook.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi, all

I have 1 master and 2 slave PostgreSQL servers named e.g. server1(master), server2(slave) and server3(slave)

OS: Ubuntu 16.04
Postgresql version is 9.6.

Consider server1 down, then I touched a trigger file to server2, and then from server3 I run pg_rewind,

But still get below errors:

root(at)server3#: systemctl stop postgresql(at)9(dot)6-main(dot)service
root(at)server3#: runuser -s /bin/bash postgres -c '/usr/lib/postgresql/9.6/bin/pg_rewind --target-pgdata /var/lib/postgresql/9.6/main/ --source-server="host=10.10.4.7 port=5432 user=postgres dbname=postgres"'
servers diverged at WAL position 0/4B000060 on timeline 17

could not find previous WAL record at 0/4B000060: invalid record length at 0/4B000060: wanted 24, got 0
Failure, exiting

What is wrong here? Thanks.

Browse pgsql-general by date

  From Date Subject
Next Message Tim Uckun 2017-07-06 09:32:00 Re: Is PL-PGSQL interpreted or complied?
Previous Message Pavel Stehule 2017-07-06 04:55:57 Re: Is PL-PGSQL interpreted or complied?