All Products
Search
Document Center

PolarDB:Multi-node deployment architecture

Last Updated:Mar 11, 2024

Multiple compute nodes are deployed in the primary zone of a PolarDB for MySQL cluster of Cluster Edition, including one primary node and one or more read-only nodes.

Limitations

Only PolarDB for MySQL clusters of Cluster Edition support multi-node deployment. For more information, see Editions.

Multi-node architecture

1

Each PolarDB for MySQL cluster contains 1 primary node and 1 to 15 read-only nodes.

The multi-node architecture ensures the high availability of PolarDB for MySQL clusters. If the primary node in a PolarDB for MySQL cluster fails, a read-only node automatically takes over as the new primary node.

In addition, PolarProxy can be used to implement features such as read/write splitting based on the multi-node deployment. For more information, see PolarProxy.

Specification requirements on nodes of a cluster

  • A PolarDB Enterprise Edition cluster can contain up to 15 read-only nodes. A PolarDB Standard Edition cluster can contain up to eight read-only nodes. To ensure high availability, each cluster must have at least one read-only node.
  • Limits for the specifications of new read-only nodes:
    • The memory size of a new read-only node must be at least half of the memory size of the primary node.
    • The minimum number of CPU cores allowed for a new read-only node varies based on the number of CPU cores of the primary node, as listed in the following table.
      CPU cores for the primary nodeMinimum CPU cores for a read-only node
      22
      44
      84
      168
      3216
      6432
      8832
    • Each cluster must contain at least one read-only node that has the same specifications of the primary node.
    • The specifications of the read-only nodes that serve as hot standby nodes must be the same as those of the primary node.
    • We recommend that you specify higher specifications for read-only column store nodes than the primary node. For more information, see Add a read-only column store node.

Add or remove read-only nodes

A PolarDB for MySQL cluster of Cluster Edition can contain up to 15 read-only nodes and must contain at least one read-only node. This ensures the high availability of the cluster.

You can manually add or remove read-only nodes to adjust the cluster performance based on your business requirements. For more information, see Add or remove read-only nodes.

Note
  • The system requires about five minutes to add a read-only node to a PolarDB for MySQL cluster. The amount of time that is consumed to add a read-only node to the cluster depends on multiple factors, such as the number of newly added nodes, the numbers of databases and tables, and the database loads. When PolarDB for MySQL adds read-only nodes to a PolarDB for MySQL cluster, the databases in the cluster are not affected.

  • When the system removes a read-only node from a PolarDB for MySQL cluster, connections to the read-only node are closed. The connections to other nodes in the cluster are not affected. We recommend that you remove read-only nodes during off-peak hours and make sure that your applications can automatically reconnect to the cluster.

  • We recommend that you connect your application to the cluster endpoint. This way, when you add read-only nodes to or remove read-only nodes from a PolarDB for MySQL cluster, you do not need to modify the application configurations, because the system will automatically re-create connections and balance the traffic among the read-only nodes in that cluster.