OceanBase Database supports multiple deployment models. This enables flexibility in choosing the most suitable model based on IDC specification and requirements on performance and availability.
Three IDCs in the same city
If you only have IDCs in one city and do not have stringent requirements for high availability, you may deploy your OceanBase Database cluster in three IDCs in the same city. This deployment mode offers excellent performance because network latency between IDCs in the same city is between 0.5 and 2 ms in general. It is even possible to achieve disaster recovery at the rack level by deploying three zones on different racks in the IDC.
Three replicas in three IDCs across two regions
"Three IDCs across two regions" is a deployment mode that supports both high availability and limited geo-disaster recovery. One replica is deployed in each of the three IDCs across two regions, with two replicas located in the same city. Generally, transactions are only committed to and synchronized between the two replicas in the same city, offering the same performance as the that of the "three IDCs in the same city" mode. No service interruption or data loss will arise in the OceanBase Database cluster if a regional failure occurs in the city with only one replica. However, when a regional failure affecting the city with two replicas occurs, the OceanBase Database cluster becomes unavailable. Despite the significant improvement in availability compared with the same-city mode, this mode only ensures IDC-level disaster recovery.
Five replicas in three IDCs across two regions
In this mode, the OceanBase Database cluster is deployed in two cities, with one serving as the primary city and the other as the standby city. The primary city has two IDCs with two replicas hosted in each IDC. The standby city has only one IDC and one replica. This mode evolves from the "three replicas in three IDCs across two regions" mode. Its purpose is to eliminate cross-city transaction committing in the event of an IDC failure in the city with more replicas. Assume that the leader is located in IDC 1 of the primary city. When IDC 2 experiences a total failure, the Paxos protocol reduces the group from 5 replicas to 3 by removing the two replicas in IDC 2 from the member list. Subsequent synchronizations will only occur between 2 of the 3 remaining replicas. In most cases, synchronization can be done within IDC 1 to avoid cross-city synchronization. Likewise, if a total failure happens at IDC 1, the Paxos protocol will switch the leader to IDC 2, and then reduce the group from 5 replicas to 3. Synchronization will then occur within IDC 2 to avoid cross-city synchronization.
To reduce the cost, you can deploy one replica in IDC 1 and one in IDC 2 as the log replicas. Log replicas do not provide services. They only replicate logs for disaster recovery. Only 3 copies of data will be stored and served in this case.

Five replicas in three IDCs across three regions
The "three IDCs across two regions" mode does not support lossless geo-disaster recovery. Based on the principle of the Paxos protocol, you need to deploy your cluster in at least three regions to achieve lossless geo-disaster recovery. OceanBase Database adopts a variant of the "three IDCs across two regions" mode, which involves five replicas in three IDCs across three regions. This model includes three cities with one IDC each. The IDC in the first two cities has two replicas each, while the third IDC only has one replica. Unlike the "three IDCs across two regions" mode, this mode requires each transaction to be synchronized to at least two cities. Business applications must be tolerant of the latency introduced by cross-region replication.
Five replicas in five IDCs across three regions
This is similar to five replicas in three IDCs across three regions, with the exception that each replica is deployed to a different IDC to improve disaster recovery at the IDC level.