nerdexam
Google

PROFESSIONAL-CLOUD-DATABASE-ENGINEER · Question #68

You have a Cloud SQL instance (DB-1) with two cross-region read replicas (DB-2 and DB-3). During a business continuity test, the primary instance (DB-1) was taken offline and a replica (DB-2) was prom

The correct answer is D. Create DB-4 as a read replica in the same region as DB-1, and promote DB-4 to primary.. When a Cloud SQL read replica is promoted, it becomes a standalone independent primary instance - it is permanently detached from the original replication chain. DB-1, having been taken offline during the test, now has stale data and cannot simply be reinstated as the primary. Op

Implementing High Availability and Disaster Recovery

Question

You have a Cloud SQL instance (DB-1) with two cross-region read replicas (DB-2 and DB-3). During a business continuity test, the primary instance (DB-1) was taken offline and a replica (DB-2) was promoted. The test has concluded and you want to return to the pre-test configuration. What should you do?

Options

  • ABring DB-1 back online.
  • BDelete DB-1, and re-create DB-1 as a read replica in the same region as DB-1.
  • CDelete DB-2 so that DB-1 automatically reverts to the primary instance.
  • DCreate DB-4 as a read replica in the same region as DB-1, and promote DB-4 to primary.

How the community answered

(51 responses)
  • A
    4% (2)
  • B
    2% (1)
  • C
    12% (6)
  • D
    82% (42)

Explanation

When a Cloud SQL read replica is promoted, it becomes a standalone independent primary instance - it is permanently detached from the original replication chain. DB-1, having been taken offline during the test, now has stale data and cannot simply be reinstated as the primary. Options A and C are wrong because Cloud SQL provides no mechanism to demote a promoted instance or automatically revert a primary. Option B recreates DB-1 as a replica but doesn't restore it as the primary. The correct approach (D) is to create a new instance (DB-4) as a read replica of the current primary (DB-2) in the same region where DB-1 originally resided, then promote DB-4 to primary. This restores the functional pre-test topology - a primary in DB-1's original region - using up-to-date data from DB-2, which received all writes during the test period.

Topics

#Cloud SQL#Read Replicas#Failover#Disaster Recovery

Community Discussion

No community discussion yet for this question.

Full PROFESSIONAL-CLOUD-DATABASE-ENGINEER Practice