Re: [HACKERS] Create replication slot in pg_basebackup if requestedand not yet present - Mailing list pgsql-hackers

From Michael Banck
Subject Re: [HACKERS] Create replication slot in pg_basebackup if requestedand not yet present
Date
Msg-id 1490141755.32520.34.camel@credativ.de
Whole thread Raw
In response to Re: [HACKERS] Create replication slot in pg_basebackup if requestedand not yet present  (Michael Banck <michael.banck@credativ.de>)
List pgsql-hackers
Hi,

Am Mittwoch, den 22.03.2017, 00:40 +0100 schrieb Michael Banck:
> I guess if we decide (physical) slots should not be created implicitly,
> then using the same UI as pg_receivewal makes sense for the sake of
> consistency, i.e. "--slot=name --create-slot [--if-not-exists]". That is
> rather verbose though and I don't think the --if-not-exists is great UX,
> but maybe there is some use-case for erroring out if a slot already
> exists that I haven't thought of.

Thinking about this some more, there's the case of somebody accidentally
using an already existing slot that was meant for another standby which
happens to be down just at that moment.

From some quick testing, that makes replication fail once the other
standby is started up again, but soon after the new standby is taken
down, replication picks up without apparent problems for the other
standby.


Michael

-- 
Michael Banck
Projektleiter / Senior Berater
Tel.: +49 2166 9901-171
Fax:  +49 2166 9901-100
Email: michael.banck@credativ.de

credativ GmbH, HRB Mönchengladbach 12080
USt-ID-Nummer: DE204566209
Trompeterallee 108, 41189 Mönchengladbach
Geschäftsführung: Dr. Michael Meskes, Jörg Folz, Sascha Heuer





pgsql-hackers by date:

Previous
From: Stephen Frost
Date:
Subject: Re: [HACKERS] increasing the default WAL segment size
Next
From: Peter Geoghegan
Date:
Subject: Re: [HACKERS] GUC for cleanup indexes threshold.