# `2-DC` Multi-Active Solution

+ The application requests are separated and dispatched into 2 `DCs`
+ Each `DC` hosts one `TiDB` cluster and each cluster has two databases: 
  + A primary database to serve part of the application requests
  + A secondary database to act as the backup of the other primary database in the counterpart `DC`
+ Data written into the primary database is replicated via `Binlog` to the secondary database in the other `DC`, forming a loop of backup

------------------------------------------------------------
In addition, some users use this method to do multi-active solution with two data centers. Each data center hosts a TiDB cluster, and the business is divided into two databases. Each database serves a portion of the data. Each data center's business only accesses one database. The data changes in the database are synchronized to the opposite data center through binlog, forming a circular backup.

In this solution, only `binlog` is asynchronously replicated between data centers. When network latency between data centers is high, the amount of data that lags behind the primary cluster increases. When the primary cluster fails, data loss is possible, and the amount of lost data will be affected by factors such as networking delays.
