Tailor your storage class configuration with mount options
Leverage mount options for tailored storage control with the CSI Plugin.
Overview
The CSI Plugin empowers you with mount options, allowing you to customize how WekaFS volumes are presented to pods. This enables granular control over storage behavior, optimizing performance and data management for containerized workloads.
Mount options are key-value pairs specified during volume mounting that modify the default filesystem or storage provider behavior. These settings influence caching, data integrity, filesystem limits, and more.
When to use mount options:
Tailor performance: Optimize caching strategies for read-heavy or write-intensive workloads (
noatime
,readcache
).Enhance data integrity: Enforce data consistency and reliability (example:
sync
).Customize behavior: Adjust settings like filesystem size limits for specific use cases (example:
fstype
).Troubleshoot issues: Fine-tune settings to resolve performance bottlenecks or compatibility problems.
Standard mount options and use cases
The CSI Plugin supports all standard mount options except the read-only (ro
) option. The following table briefly lists the supported mount options for convenience.
Set custom mount options with CSI Plugin
This example procedure demonstrates how to set custom mount options using the WEKA CSI Plugin.
Prerequisites:
The Kubernetes environment is set up and accessible.
The kubectl command-line tool is installed and configured.
Procedure:
Create StorageClass:
a. Open or create a YAML file for your StorageClass definition (for example,
storageclass-wekafs-mountoptions.yaml
).b. Add the following content to define the StorageClass with custom mount options:
c. Apply the StorageClass using the following command:
Create CSI secret: a. Execute the following command to create a CSI secret named
csi-wekafs-api-secret
(located in ../common/csi-wekafs-api-secret.yaml):This step ensures that the necessary credentials are available for the CSI Plugin.
Provision a new volume:
Apply the StorageClass to provision a new volume. Use the following command:
Replace
<FILE>
with the path to your YAML file containing the Persistent Volume Claim (PVC) definition.
Create application:
a. Create an application manifest file (for example,
csi-app-fs-mountoptions.yaml
) or use an existing one.b. In the manifest, specify the PVC with the custom mount options:
Replace
<YOUR_IMAGE>
with the desired container image.
c. Deploy the application:
Attach and validate:
Attach to the application pod:
b. Verify that the output resembles to the following example:
The acl
mount option is used internally by the WEKA CSI Plugin and cannot be set via StorageClass configuration
Mount options are initialized on the Persistent Volume (PV) during creation and will stick to the PV during its whole lifetime. Mount options cannot be changed for existing persistent volumes. Hence, it is recommended to carefully consider required mount options prior to creation of long-living persistent volumes.
Last updated