Storage optimization using Ceph Autoscaler and a Target Size Ratio for PG Increase/Placement on Large Pools - OpenShift Data Foundation (ODF) v4.19+
Background:
Under the assumption that the majority of the workload consumes a single storage service, which is either Block, File, or Object, it's possible to optimize the OpenShift Data Foundation behavior by setting the target size ratio for any pool.
First, we will need to determine the desired ratio for storage usage
Second, we will need to follow the following two steps and set the right value.
Then, edit the CR for the pool to a new target size ratio value.
Determine the Desired Ratio
To optimize storage depending on the cluster usage, determine how you expect to fill the cluster between the three types of storage: Block, Shared Filesystem, and Object storage. A relative value of expected usage will then need to be assigned to each of the three storage types. The value is the “targetSizeRatio”.
For simplicity, the values can be chosen to add up to 1.0. Each value should also be non-zero if very small.
Requiring a small nonzero number is a defect - A value of zero is valid - See Jira This content is not included.DFBUGS-2657.
For unused Pools which should be 0, use 0.001 until the defect (Jira) is resolved.
Example 1: Optimize for 80% in block storage and 10% in each of the Filesystem and Object store
Block pool targetSizeRatio: 0.8
Filesystem targetSizeRatio: 0.1
Object store targetSizeRatio: 0.1
Example 2: Optimize for 98% of storage in the filesystem:
Block pool targetSizeRatio: 0.01
Filesystem targetSizeRatio: 0.98
Object store targetSizeRatio: 0.01
General Availability Steps in ODF v4.19+ Clusters:
-
Review the Changes to Target Ratio Settings in OpenShift Data Foundation (ODF) v4.21 Through ODF v5.x solution prior to any manual adjustments.
-
If manual adjustments are still warranted, follow the steps outlined in Chapter 21. Configuring Ceph target size ratios of the product documentation.