ALTER CLUSTER ADD

Overview

In 23.09, 6.1:

Adds node(s) to an Xpand cluster with the UNCOORDINATED option by default.

In 6.1:

Adds node(s) to an Xpand cluster with the UNCOORDINATED option by default.

In 6.0, 5.3:

Adds node(s) to an Xpand cluster with the COORDINATE option by default.

USAGE

Common Syntax:

ALTER CLUSTER ADD <node_name> [, <node_name> ...]
  [COORDINATE | UNCOORDINATED]

Supported Syntax:

ALTER CLUSTER ADD <node_name> [, <node_name> ...]
   {COORDINATE | UNCOORDINATED}

DETAILS

This statement is used to add a new Xpand node to a cluster.

For information on how to perform the scale-out procedure that uses this statement, see "Scale-Out with MariaDB Xpand".

This statement can't be used to add Xpand nodes to a cluster in SkySQL.

For information on how to add Xpand nodes to a cluster in SkySQL, see "Scale Up/Down".

Group Changes

In MariaDB Xpand 5.3 and 6, this statement causes a full group change by default.

In MariaDB Xpand 6.1, this statement adds nodes online with the following behavior:

  • "Late" nodes will move to the "normal" sub-state in the next full group change. ALTER CLUSTER REFORM can be used to initiate a group change to move nodes from "late" to "normal".

  • A full group change occurs when the new cluster is more than twice the size of the old cluster. This is because the old cluster has less than a quorum of nodes for the new cluster.

  • If desired, use the COORDINATE option to ensure that there are no late nodes.

COORDINATE | UNCOORDINATED

The COORDINATE and UNCOORDINATED options can be specified to control the group change behavior:

  • When the COORDINATE option is specified, Xpand waits for all nodes being added to join the cluster before forming the group. This results in a full group change.

  • When the UNCOORDINATED option is specified, Xpand adds each node to the cluster as soon as it can, and performs an online group change when possible. Online group changes can only occur if the resulting cluster has fewer than half of the nodes in the "late" sub-state.

In MariaDB Xpand 6.0 and earlier, a full group change occurs by default, which matches the behavior of the COORDINATE option.

In MariaDB Xpand 6.1, an online group change occurs by default when possible, which matches the behavior of the UNCOORDINATED option.

The COORDINATE option is recommended when forming a new cluster.

SYNONYMS

SCHEMA

PARAMETERS

SKYSQL

PRIVILEGES

EXAMPLES

Scaling

For an example that shows how to scale an Xpand cluster using this statement, see "Scale-Out with MariaDB Xpand".

This statement can't be used to add Xpand nodes to a cluster in SkySQL.

For information on how to scale an Xpand cluster in SkySQL, see "Scale Up/Down".

ERROR HANDLING

FEATURE INTERACTION

RESPONSES

DIAGNOSIS

ISO 9075:2016

CHANGE HISTORY

Release Series

History

23.09

  • Present starting in MariaDB Xpand 23.09.1.

6.1

  • Present starting in MariaDB Xpand 6.1.0.

6.0

  • Present starting in MariaDB Xpand 6.0.3.

5.3

  • Present starting in MariaDB Xpand 5.3.13.

Release Series

History

6.0

  • Present starting in MariaDB Xpand 6.0.3.

5.3

  • Present starting in MariaDB Xpand 5.3.13.

Release Series

History

6.1

  • Present starting in MariaDB Xpand 6.1.0.

EXTERNAL REFERENCES