promote a deferred standby without applying WALs - Mailing list pgsql-admin

From Zwettler Markus (OIZ)
Subject promote a deferred standby without applying WALs
Date
Msg-id GV0P278MB009978C3836E51677017D2998BA22@GV0P278MB0099.CHEP278.PROD.OUTLOOK.COM
Whole thread Raw
Responses Re: promote a deferred standby without applying WALs
List pgsql-admin

I have a standby database running 3 hours behind the primary (recovery_min_apply_delay = '3h').

 

In case of a logical error on the primary I want to promote the standby database which still has correct data.

 

The standby should not apply any more WAL in that case.

 

It seems that this can only be done manually:

 

  1. pg_ctl stop
  2. rm -rf standby.signal
  3. set primary_conninfo = ''
  4. pg_ctl start

 

Is there no single command on this?

 

 

 

 

pgsql-admin by date:

Previous
From: Kashif Zeeshan
Date:
Subject: Re: indexes on partitioned tables
Next
From: Laurenz Albe
Date:
Subject: Re: promote a deferred standby without applying WALs