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 WEKA 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).

  • 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.

Option
Description
Use cases

sync

Ensure data is written to disk before mount

Database workloads requiring high data integrity

noatime

Disable write timestamp updates

Reduce write amplification, improve performance

nodev

Disallow device nodes

Security-sensitive environments

noexec

Disallow program execution

Security-focused deployments

atime

Enable access time recording

Monitor file access patterns

diratime

Enable directory access time recording

Track directory access time

relatime

Update access and modification times relative to stat time

Reduce write amplification, improve performance

data=ordered

Ensure sequential writes are flushed to disk immediately

Databases requiring strict write ordering

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:

  1. 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:

2. 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):

3. Provision a new volume:

4. Create application:

5. Attach and validate: