Re: standby database crash

From: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>
To: "Seong Son (US)" <Seong(dot)Son(at)datapath(dot)com>
Cc: "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: standby database crash
Date: 2017-08-01 18:32:27
Message-ID: CAB7nPqSY17pzRGyEHz_E5rb=ZHZcNEVH2CVwS1xBq2skHBpvyQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Mon, Jul 31, 2017 at 11:15 PM, Seong Son (US) <Seong(dot)Son(at)datapath(dot)com> wrote:
> So my questions are, could an old WAL segment being resent through the
> network cause crash like this? Shouldn’t Postgresql be able to handle out
> of order WAL segments instead of just crashing?

When the streaming connection between a standby and a primary is cut,
the WAL receiver would restart and try to stream from the beginning of
the last segment it was in the middle of. See RequestXLogStreaming in
walreceiverfuncs.c.

> And what would be the best way to recover the standby server? Resynching
> the entire database seems to be too time consuming.

You may want to check the validity of the so-said WAL segment as well.
Corrupted data could come from it.
--
Michael

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Dan Cooperstock at Software4Nonprofits 2017-08-01 18:35:11 Re: Problem compiling a C function on Windows - not finding _palloc0@4
Previous Message Tom Lane 2017-08-01 16:58:50 Re: [GENERAL] Not able to create collation on Windows