Placement groups
The placement groups are predefined sets of disks over which volume objects will be replicated (see Disk and Volumes). It is possible to specify which individual disks to add to the group.
Placement group usage
When using the replication mechanism (see Redundancy), each disk in the cluster is part of one or more placement groups. Placement groups are used to define how data will be distributed on disks. There are three placement groups defined for each volume:
In the CLI they are called
placeHead
,placeAll
, andplaceTail
.Within this documentation, they are referred to as “Head”, “All”, and “Tail”, respectively.
When a client requests to write to an object (see Disk objects), StorPool takes care to send the data first to the disk in the “Head” placement group, then to the disc in the “All” group, and finally to the disk in the “Tail” group. The writing operation is completed when all disks acknowledge the data is written.
StorPool performs read operations only on disk in a “Tail” group. If the “Tail” disk is missing, reads are performed from the previous disk in the disk set.
Operations
To display the defined placement groups in the cluster:
# storpool placementGroup list
name
default
hdd
ssd
To display details about a placement group:
# storpool placementGroup ssd list
type | id
disk | 1101 1201 1301 1401
Creating a new placement group or extending an existing one requires specifying its name and providing one or more disks to be added:
# storpool placementGroup ssd addDisk 1102
OK
# storpool placementGroup ssd addDisk 1202
OK
# storpool placementGroup ssd addDisk 1302 addDisk 1402
OK
# storpool placementGroup ssd list
type | id
disk | 1101 1102 1201 1202 1301 1302 1401 1402
To remove one or more disks from a placement group:
# storpool placementGroup ssd rmDisk 1402
OK
# storpool placementGroup ssd list
type | id
disk | 1101 1102 1201 1202 1301 1302 1401
To rename a placement group:
# storpool placementGroup ssd rename M500DC
OK
The unused placement groups can be removed. To avoid accidents, the name of the group must be entered twice:
# storpool placementGroup ssd delete ssd
OK