Static Group Move
If you need to decommission a YDB cluster host that contains part of the static group, you need to move it to another host.
Warning
Errors in metadata subsystem configuration (including the domains_config section) or an incorrect sequence of changes can lead to YDB cluster unavailability.
As an example, consider a YDB cluster where a static node is configured and running on the host with node_id:1. This node serves part of the static group.
Static group configuration fragment:
...
blob_storage_config:
...
service_set:
...
groups:
...
rings:
...
fail_domains:
- vdisk_locations:
- node_id: 1
path: /dev/vda
pdisk_category: SSD
...
...
...
...
...
To replace node_id:1, we added a new host with node_id:10 to the cluster and deployed a static node on it.
To move part of the static group from host node_id:1 to node_id:10:
-
Stop the cluster static node on the host with
node_id:1.Note
A YDB cluster is fault-tolerant. Temporary node shutdown does not lead to cluster unavailability. For more details, see YDB Cluster Topology.
-
In the configuration file
config.yaml, change thenode_idvalue, replacing the identifier of the host being removed with the identifier of the host being added:... blob_storage_config: ... service_set: ... groups: ... rings: ... fail_domains: - vdisk_locations: - node_id: 10 path: /dev/vda pdisk_category: SSD ... ... ... ... ...Change the
pathand diskpdisk_categoryif they differ on the host withnode_id: 10. -
Update the configuration files
config.yamlfor all cluster nodes, including dynamic ones. -
Using the rolling-restart procedure, restart all static cluster nodes.
-
Go to the Embedded UI monitoring page and ensure that the static group VDisk appeared on the target physical disk and is replicating. For more details, see Monitoring static groups.
-
Using the rolling-restart procedure, restart all dynamic cluster nodes.