Re: pg_basebackup on slave running for a long time - Mailing list pgsql-general

From Subhankar Chattopadhyay
Subject Re: pg_basebackup on slave running for a long time
Date
Msg-id CAPg1NnHWA_VNbHepCNh813UrfYv7Ej1Acwt+1dEwuQp3Vfj33A@mail.gmail.com
Whole thread Raw
In response to Re: pg_basebackup on slave running for a long time  (Subhankar Chattopadhyay <subho.atg@gmail.com>)
Responses Re: pg_basebackup on slave running for a long time  (John R Pierce <pierce@hogranch.com>)
List pgsql-general
John,

Can you explain the Wal Archive procedure, how it can be setup so that
the slave never goes out of sync, even if master deletes the WAL
files?

On Tue, Nov 22, 2016 at 4:04 PM, Subhankar Chattopadhyay
<subho.atg@gmail.com> wrote:
> So, the question here is while I apply update on Slave, how do I know
> if if it will be able to catch up or I need Wal archive? Is there a
> way I can determine this? In my case, while applying update on slave,
> the db process will be stopped, so the query, even if it gives correct
> value, won't help. Can anybody help in here?
>
> On Mon, Nov 21, 2016 at 12:40 PM, John R Pierce <pierce@hogranch.com> wrote:
>> On 11/20/2016 11:00 PM, Subhankar Chattopadhyay wrote:
>>
>> Yes so if the slave is behind I need to start over pgbasebackup. I saw
>> according to the documentation this query gives us the replication state.
>> Can somebody tell me if this would be sufficient to know if I need to start
>> over the backup ?
>>
>>
>>
>>
>> if the slave is behind but is catching up, no, restarting replication would
>> be overkill.    only if the slave gets so far behind that it can't catch up,
>> and in that case, a wal archive would be a better choice than a new base
>> backup.
>>
>> I've never run into these problems as I run on dedicated hardware servers,
>> which don't have all these reliability and performance problems.   a
>> complete server failure requiring a full rebuild is something that would
>> happen less than annually.
>>
>>
>>
>> --
>> john r pierce, recycling bits in santa cruz
>
>
>
> --
>
>
>
>
> Subhankar Chattopadhyay
> Bangalore, India



--




Subhankar Chattopadhyay
Bangalore, India


pgsql-general by date:

Previous
From: Subhankar Chattopadhyay
Date:
Subject: Re: pg_basebackup on slave running for a long time
Next
From: marin@kset.org
Date:
Subject: pg_rewind and WAL size...