0

Hello i have setup streaming replication using PostgreSQL 11 on Windows working OK. How can i manually use the replica ( it is hot_standby=on ) in case Master fails ? What are the steps i have to perform to the replica ?

asked May 5, 2020 at 12:38
4
  • Do you want to access the standby or do you want to fail over? Please be more specific. Commented May 5, 2020 at 14:01
  • Thank You for your reply. I want to access standby ( Its critical for me to use the standby as master and have available database for read/write. Commented May 6, 2020 at 9:11
  • Do you want to promote the standby? Your question is still unclear. Commented May 6, 2020 at 11:32
  • Yes i want to promote the standy Commented May 6, 2020 at 11:51

1 Answer 1

0

Like the documentation says, there are three ways to promote a standby server:

  1. run pg_ctl promote on the command line.

  2. create a trigger file (if you have configured the standby server accordingly).

  3. from v12 on, you can also execute

    SELECT pg_promote();
    
answered May 6, 2020 at 12:27

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.