You are managing a Cloud SQL for PostgreSQL instance in Google Cloud. You need to test the high availability of your Cloud SQL instance by performing a failover. You want to use the cloud command. What should you do?
A.
Use gcloud sql instances failover <PrimaryInstanceName>.
B.
Use gcloud sql instances failover <ReplicaInstanceName>.
C.
Use gcloud sql instances promote-replica <PrimaryInstanceName>.
D.
Use gcloud sql instances promote-replica <ReplicaInstanceName>.
A.
We are not promoting a read replica to be the primary instance. Eliminate C and D. When HA is enabled you only deal with the primary instance name, so B doesn’t make sense. That leaves A.
correct answer is B! When you initiate the failover on the replica instance, it will be promoted to the primary instance, simulating a high-availability failover event. option A is not the recommended!
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
dynamic_dba
Highly Voted 1 year, 1 month agochelbsik
Highly Voted 1 year, 4 months ago887ad17
Most Recent 3 months agoPime13
5 months, 3 weeks agolearnazureportal
7 months, 2 weeks agopk349
1 year, 4 months ago