All Products
Search
Document Center

ApsaraDB for OceanBase:Overview

Last Updated:Mar 21, 2023

ApsaraDB for OceanBase allows you to add standby cluster instances for a primary cluster instance to form a cluster network. In this cluster network, data is synchronized between the primary and standby instances to further improve the high availability of the database.

When the primary instance expectedly or unexpectedly becomes unavailable for reasons such as the failure of the majority of replicas, a standby instance can take over the services. OceanBase Database provides two disaster recovery solutions to minimize service downtime, which are lossless failover with an RPO of 0 and lossy failover with an RPO greater than 0. Both the primary and standby instances support data reads. However, only the primary instance supports data writes. The primary-standby architecture is used mainly in the following two scenarios:

  • Zone-disaster recovery

Some regions of Alibaba Cloud provide only two zones. This makes it impossible for the three replicas of a single OceanBase Database instance to provide disaster recovery capabilities at the IDC (zone) level. In this case, you can create primary and standby instances in two zones to achieve cross-IDC high availability of the database. When one IDC fails, you can manually switch the business to the standby instance.

  • Geo-disaster recovery

If the business is deployed in multiple regions, you can create primary and standby instances in multiple regions to achieve cross-region high availability of the database. When one region fails, you can manually switch the business to the standby instance.

The primary-standby architecture consists of a primary instance and multiple standby instances (Physical_Standby). You cannot add standby instances to a standby instance in cascading mode. The primary and standby instances maintain data consistency by performing asynchronous log replication, which does not affect the stability and performance of the primary instance.

A primary-standby architecture
Note

The switchover between the primary and standby instances takes about 5 minutes. In this process, transient disconnections may occur. We recommend that you perform primary-standby switchover during off-peak hours and use techniques such as a connection pool to implement automatic reconnection.