LVMCluster
CRapiVersion: lvm.topolvm.io/v1alpha1
kind: LVMCluster
metadata:
name: my-lvmcluster
spec:
storage:
deviceClasses:
# ...
deviceSelector: (1)
paths: (2)
- /dev/disk/by-path/pci-0000:87:00.0-nvme-1
- /dev/disk/by-path/pci-0000:88:00.0-nvme-1
optionalPaths: (3)
- /dev/disk/by-path/pci-0000:89:00.0-nvme-1
- /dev/disk/by-path/pci-0000:90:00.0-nvme-1
# ...
-
Contains the configuration to specify the paths to the devices that you want to add to the LVM volume group. You can specify the device paths in the
paths
field, theoptionalPaths
field, or both. If you do not specify the device paths in bothpaths
andoptionalPaths
, {lvms-first} adds the supported unused devices to the LVM volume group. {lvms} adds the devices to the LVM volume group only if the following conditions are met:-
The device path exists.
-
The device is supported by {lvms}. For information about unsupported devices, see "Devices not supported by {lvms}".
-
-
Specify the device paths. If the device path specified in this field does not exist, or the device is not supported by {lvms}, the
LVMCluster
CR moves to theFailed
state. -
Specify the optional device paths. If the device path specified in this field does not exist, or the device is not supported by {lvms}, {lvms} ignores the device without causing an error.
ImportantAfter a device is added to the LVM volume group, it cannot be removed.