Skip to content

how to perform a manual failover without applying any outstanding WAL? #3957

Open
@mzwettler2

Description

@mzwettler2

We have a simple configuration with 2 replicas (1 primary + 1 standby).

We configured the standby to run 3 hours behind the primary:

  • recovery_min_apply_delay: '3h' # standby 3 hours behind
  • synchronous_mode: false # asynchron

In case there is a logical problem on the primary (wrong data processing, misleaded application upgrade,…) we want to perform a manual failover to the standby, which still contains the old, correct data status. That means the standby should not apply any more WALs within the 3 hour residue in the event of a manual failover.

I could not find any working solution. Whatever I tried the standby first applied all outstanding WALs (which I don't want) and only then promoted the standby. Any idea how to get this working?

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions