diff --git a/modules/lvms-about-scaling-storage-of-clusters.adoc b/modules/lvms-about-scaling-storage-of-clusters.adoc new file mode 100644 index 000000000000..dd4d4e7848bc --- /dev/null +++ b/modules/lvms-about-scaling-storage-of-clusters.adoc @@ -0,0 +1,18 @@ +// Module included in the following assemblies: +// +// storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc + +:_mod-docs-content-type: CONCEPT +[id="lvms-about-scaling-storage-of-cluster_{context}"] += Ways to scale up the storage of a {sno} cluster + +You can scale up the storage of a {sno} cluster by adding new devices to the existing node. + +To add a new device to the existing node on a {sno} cluster, you must add the path to the new device in the `deviceSelector` field of the `LVMCluster` custom resource (CR). + +[IMPORTANT] +==== +You can add the `deviceSelector` field in the `LVMCluster` CR only while creating the `LVMCluster` CR. If you have not added the `deviceSelector` field while creating the `LVMCluster` CR, you must delete the `LVMCluster` CR and create a new `LVMCluster` CR containing the `deviceSelector` field. +==== + +If you do not add the `deviceSelector` field in the `LVMCluster` CR, {lvms} automatically adds the new devices when the devices are available. diff --git a/modules/lvms-scaling-storage-of-clusters-using-cli.adoc b/modules/lvms-scaling-storage-of-clusters-using-cli.adoc new file mode 100644 index 000000000000..5c2619c14249 --- /dev/null +++ b/modules/lvms-scaling-storage-of-clusters-using-cli.adoc @@ -0,0 +1,30 @@ +// Module included in the following assemblies: +// +// storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc + +:_mod-docs-content-type: PROCEDURE +[id="lvms-scaling-storage-of-clusters-using-cli_{context}"] += Scaling up the storage of a {sno} cluster by using the CLI + +You can scale up the storage capacity of the existing node on a {sno} cluster by using the OpenShift CLI (`oc`). + +.Prerequisites + +* You have additional unused devices on the {sno} cluster to be used by {lvms-first}. +* You have installed the OpenShift CLI (`oc`). +* You have created an `LVMCluster` custom resource (CR). + +.Procedure + +. Edit the `LVMCluster` CR by running the following command: ++ +[source, terminal] +---- +$ oc edit -n +---- + +. Add the path to the new device in the `deviceSelector` field: ++ +include::snippets/lvms-scaling-up-storage-lvmcluster-cr-snippet.adoc[] + +. Save the `LVMCluster` CR. diff --git a/modules/lvms-scaling-storage-of-clusters-using-web-console.adoc b/modules/lvms-scaling-storage-of-clusters-using-web-console.adoc new file mode 100644 index 000000000000..54d55c8de96f --- /dev/null +++ b/modules/lvms-scaling-storage-of-clusters-using-web-console.adoc @@ -0,0 +1,27 @@ +// Module included in the following assemblies: +// +// storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc + +:_mod-docs-content-type: PROCEDURE +[id="lvms-scaling-storage-of-clusters-using-web-console_{context}"] += Scaling up the storage of a {sno} cluster by using the web console + +You can scale up the storage capacity of the existing node on a {sno} cluster by using the {product-title} web console. + +.Prerequisites + +* You have additional unused devices on the {sno} cluster to be used by {lvms-first}. +* You have created an `LVMCluster` custom resource (CR). + +.Procedure + +. Log in to the {product-title} web console. +. Click *Operators* -> *Installed Operators*. +. Click *LVM Storage* in the `openshift-storage` namespace. +. Click the *LVMCluster* tab to view the `LVMCluster` CR created on the cluster. +. From the *Actions* menu, select *Edit LVMCluster*. +. Click the *YAML* tab. +. Edit the `LVMCluster` CR to add the new device path in the `deviceSelector` field: ++ +include::snippets/lvms-scaling-up-storage-lvmcluster-cr-snippet.adoc[] +. Click *Save*. \ No newline at end of file diff --git a/modules/lvms-scaling-storage-of-single-node-open-concept.adoc b/modules/lvms-scaling-storage-of-single-node-open-concept.adoc deleted file mode 100644 index ecd59df9f7c0..000000000000 --- a/modules/lvms-scaling-storage-of-single-node-open-concept.adoc +++ /dev/null @@ -1,10 +0,0 @@ -// Module included in the following assemblies: -// -// storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc - -:_mod-docs-content-type: CONCEPT -[id="lvms-scaling-storage-of-single-node-openshift-cluster-con_{context}"] -= Scaling storage of {sno} clusters - -The {product-title} supports additional worker nodes for {sno} clusters on bare-metal user-provisioned infrastructure. -{lvms} detects and uses the new additional worker nodes when the nodes show up. \ No newline at end of file diff --git a/modules/lvms-scaling-storage-of-single-node-openshift-cluster.adoc b/modules/lvms-scaling-storage-of-single-node-openshift-cluster.adoc deleted file mode 100644 index ebc281fa3063..000000000000 --- a/modules/lvms-scaling-storage-of-single-node-openshift-cluster.adoc +++ /dev/null @@ -1,55 +0,0 @@ -// Module included in the following assemblies: -// -// storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc - -:_mod-docs-content-type: PROCEDURE -[id="lvms-scaling-storage-of-single-node-openshift-cluster_{context}"] -= Scaling up storage by adding capacity to your {sno} cluster - -To scale the storage capacity of your configured worker nodes on a {sno} cluster, you can increase the capacity by adding disks. - -.Prerequisites - -* You have additional unused disks on each {sno} cluster to be used by {lvms}. - -.Procedure - -. Log in to {product-title} console of the {sno} cluster. -. From the *Operators* -> *Installed Operators* page, click on the *LVM Storage Operator* in the `openshift-storage` namespace. -. Click on the *LVMCluster* tab to list the `LVMCluster` CR created on the cluster. -. Select *Edit LVMCluster* from the *Actions* drop-down menu. -. Click on the *YAML* tab. -. Edit the `LVMCluster` CR YAML to add the new device path in the `deviceSelector` section: - -+ -[NOTE] -==== -In case the `deviceSelector` field is not included during the `LVMCluster` creation, it is not possible to add the `deviceSelector` section to the CR. -You need to remove the `LVMCluster` and then create a new CR. -==== - -+ -[source,yaml] ----- -apiVersion: lvm.topolvm.io/v1alpha1 -kind: LVMCluster -metadata: - name: my-lvmcluster -spec: - storage: - deviceClasses: - - name: vg1 - default: true - deviceSelector: <1> - paths: - - /dev/disk/by-path/pci-0000:87:00.0-nvme-1 - - /dev/disk/by-path/pci-0000:88:00.0-nvme-1 - optionalPaths: - - /dev/disk/by-path/pci-0000:89:00.0-nvme-1 - - /dev/disk/by-path/pci-0000:90:00.0-nvme-1 - thinPoolConfig: - name: thin-pool-1 - sizePercent: 90 - overprovisionRatio: 10 ----- -<1> Optional. To control or restrict the volume group to your preferred devices, you can manually specify the local paths of the devices in the `deviceSelector` section of the `LVMCluster` YAML. The `paths` section refers to devices the `LVMCluster` adds, which means those paths must exist. The `optionalPaths` section refers to devices the `LVMCluster` might add. You must specify at least one of `paths` or `optionalPaths` when specifying the `deviceSelector` section. If you specify `paths`, it is not mandatory to specify `optionalPaths`. If you specify `optionalPaths`, it is not mandatory to specify `paths` but at least one optional path must be present on the node. If you do not specify any paths, it will add all unused devices on the node. diff --git a/snippets/lvms-scaling-up-storage-lvmcluster-cr-snippet.adoc b/snippets/lvms-scaling-up-storage-lvmcluster-cr-snippet.adoc new file mode 100644 index 000000000000..b5ff673d29f1 --- /dev/null +++ b/snippets/lvms-scaling-up-storage-lvmcluster-cr-snippet.adoc @@ -0,0 +1,32 @@ +:_mod-docs-content-type: SNIPPET +.Example `LVMCluster` CR +[source,yaml] +---- +apiVersion: 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 +# ... +---- +<1> Contains the configuration to specify the paths to the devices that you want to add to the Logical Volume Manager (LVM) volume group. +You can specify the device paths in the `paths` field, the `optionalPaths` field, or both. If you do not specify the device paths in both `paths` and `optionalPaths`, {lvms} adds the supported unused devices to the LVM volume group. {lvms} adds the devices to the LVM volume group only if the device path exists. +<2> Specify the device paths. If the device path specified in this field does not exist, the `LVMCluster` CR moves to the `Failed` state. +<3> Specify the optional device paths. If the device path specified in this field does not exist, {lvms} ignores the device without causing an error. ++ +[IMPORTANT] +==== +After a device is added to the LVM volume group, it cannot be removed. +==== + + diff --git a/storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc b/storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc index 03068a7b9ac3..332246d436a2 100644 --- a/storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc +++ b/storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc @@ -73,14 +73,21 @@ include::modules/lvms-adding-a-storage-class.adoc[leveloffset=+1] include::modules/lvms-provisioning-storage-using-logical-volume-manager-operator.adoc[leveloffset=+1] //Scaling -include::modules/lvms-scaling-storage-of-single-node-open-concept.adoc[leveloffset=+1] +include::modules/lvms-about-scaling-storage-of-clusters.adoc[leveloffset=+1] [role="_additional-resources"] .Additional resources * xref:../../../nodes/nodes/nodes-sno-worker-nodes.adoc[Adding worker nodes to {sno} clusters] -include::modules/lvms-scaling-storage-of-single-node-openshift-cluster.adoc[leveloffset=+2] +include::modules/lvms-scaling-storage-of-clusters-using-cli.adoc[leveloffset=+2] + +[role="_additional-resources"] +.Additional resources + +* xref:../../../storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc#lvms-reference-file_logical-volume-manager-storage[{lvms} reference YAML file] + +include::modules/lvms-scaling-storage-of-clusters-using-web-console.adoc[leveloffset=+2] [role="_additional-resources"] .Additional resources @@ -96,14 +103,14 @@ include::modules/lvms-scaling-storage-of-single-node-openshift-cluster-using-rha * xref:../../../storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc#lvms-reference-file_logical-volume-manager-storage[{lvms} reference YAML file] -include::modules/lvms-scaling-storage-expand-pvc.adoc[leveloffset=+2] +//Expanding PVCs + +include::modules/lvms-scaling-storage-expand-pvc.adoc[leveloffset=+1] [role="_additional-resources"] .Additional resources -* xref:../../../storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc#lvms-scaling-storage-of-single-node-openshift-cluster_logical-volume-manager-storage[Scaling up storage by adding capacity to your {sno} cluster] - -* xref:../../../storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc#lvms-scaling-storage-of-single-node-openshift-cluster-using-rhacm_logical-volume-manager-storage[Scaling up storage by adding capacity to your single-node OpenShift cluster using RHACM] +* xref:../../../storage/persistent_storage/persistent_storage_local/persistent-storage-using-lvms.adoc#lvms-about-scaling-storage-of-cluster_logical-volume-manager-storage[Ways to scale up the storage of clusters] * xref:../../../storage/expanding-persistent-volumes.adoc#add-volume-expansion_expanding-persistent-volumes[Enabling volume expansion support]