StorageClass Parameters for Dynamic Volume Provisioning

Table 1 StorageClass configuration parameters

Parameter

Description

Mandatory

Default Value

Remarks

metadata.name

User-defined name of a StorageClass object.

Yes

-

Take Kubernetes v1.22.1 as an example. The value can contain digits, lowercase letters, hyphens (-), and periods (.), and must start and end with a letter or digit.

provisioner

Name of the provisioner.

Yes

csi.huawei.com

Set this parameter to the driver name set during Huawei CSI installation.

The value is the same as that of driverName in the values.yaml file.

reclaimPolicy

Reclamation policy. The following types are supported:

  • Delete: Resources are automatically reclaimed.
  • Retain: Resources are manually reclaimed.

No

Delete

  • Delete: When a PV/PVC is deleted, resources on the storage device are also deleted.
  • Retain: When a PV/PVC is deleted, resources on the storage device are not deleted.

allowVolumeExpansion

Whether to allow volume expansion. If this parameter is set to true, the capacity of the PV that uses the StorageClass can be expanded.

No

false

This function can only be used to expand PV capacity but cannot be used to reduce PV capacity.

The PV capacity expansion function is supported in Kubernetes 1.14 (alpha) and later versions.

parameters.backend

Name of the backend where the resource to be created is located.

No

-

If this parameter is not set, Huawei CSI will randomly select a backend that meets the capacity requirements to create resources.

You are advised to specify a backend to ensure that the created resource is located on the expected backend.

parameters.pool

Name of the storage resource pool where the resource to be created is located. If this parameter is set, parameters.backend must also be specified.

No

-

If this parameter is not set, Huawei CSI will randomly select a storage pool that meets the capacity requirements from the selected backend to create resources. You are advised to specify a storage pool to ensure that the created resource is located in the expected storage pool.

parameters.volumeType

Type of the volume to be created. The following types are supported:

  • lun: A LUN is provisioned on the storage side.
  • fs: A file system is provisioned on the storage side.
  • dtree: A volume of the Dtree type is provisioned on the storage side.

Yes

-

  • If NAS storage is used, this parameter must be set to fs.
  • If SAN storage is used, this parameter must be set to lun.
  • If NAS storage of the Dtree type is used, this parameter must be set to dtree.

parameters.allocType

Allocation type of the volume to be created. The following types are supported:

  • thin: Not all required space is allocated during creation. Instead, the space is dynamically allocated based on the usage.
  • thick: All required space is allocated during creation.

No

-

If this parameter is not specified, thin will be used. Not all required space is allocated during creation. Instead, the space is dynamically allocated based on the usage.

OceanStor Dorado/OceanStor Dorado V3 does not support thick.

parameters.fsType

Type of a host file system. The supported types are:

  • ext2
  • ext3
  • ext4
  • xfs

No

ext4

This parameter is valid only when volumeType of a StorageClass is set to lun and volumeMode of a PVC is set to Filesystem.

parameters.authClient

IP address of the NFS client that can access the volume. This parameter is mandatory when volumeType is set to fs.

You can enter the client host name (a full domain name is recommended), client IP address, or client IP address segment.

Conditionally mandatory

-

The asterisk (*) can be used to indicate any client. If you are not sure about the IP address of the access client, you are advised to use the asterisk (*) to prevent the client access from being rejected by the storage system.

If the client host name is used, you are advised to use the full domain name.

The IP addresses can be IPv4 addresses, IPv6 addresses, or a combination of IPv4 and IPv6 addresses.

You can enter multiple host names, IP addresses, or IP address segments and separate them with semicolons (;) or spaces or by pressing Enter. Example: 192.168.0.10;192.168.0.0/24;myserver1.test

parameters.cloneSpeed

Cloning speed. The value ranges from 1 to 4.

No

3

4 indicates the highest speed. This parameter is available when you clone a PVC or create a PVC using a snapshot. For details, see Cloning a PVC or Creating a PVC Using a Snapshot.

parameters.applicationType

Application type name for creating a LUN or NAS when the backend is OceanStor Dorado.

No

-

  • If the value of volumeType is lun, log in to DeviceManager and choose Services > Block Service > LUN Groups > LUNs > Create to obtain the application type name.
  • If the value of volumeType is fs, log in to DeviceManager and choose Services > File Service > File Systems > Create to obtain the application type name.

parameters.qos

LUN/NAS QoS settings of the PV on the storage side.

The value of the parameter is JSON character strings in dictionary format. A character string is enclosed by single quotation marks and the dictionary key by double quotation marks. Example: '{"maxMBPS": 999, "maxIOPS": 999}'

No

-

For details about the supported QoS configurations, see Table 2.

parameters.storageQuota

Quota of a PV on the storage device. This parameter is valid only when NAS is used for connecting to OceanStor Pacific series storage.

The value of the parameter is JSON character strings in dictionary format. A character string is enclosed by single quotation marks and the dictionary key by double quotation marks. Example: '{"spaceQuota": "softQuota", "gracePeriod": 100}'

No

-

For details about the supported quota configurations, see Table 3.

parameters.hyperMetro

Whether a HyperMetro volume is to be created. This parameter needs to be configured when the backend is of the HyperMetro type.

  • "true": The created volume is a HyperMetro volume. If the storage backend is a HyperMetro backend, the value must be true.
  • "false": The created volume is a common volume.

Conditionally mandatory

false

When the used backend is a HyperMetro backend and a HyperMetro volume needs to be provisioned, set this parameter to true. If this parameter is set to false, services may be interrupted if the logical management port connected to the backend fails over.

parameters.metroPairSyncSpeed

Data synchronization speed of a HyperMetro pair. The value ranges from 1 to 4.

The value can be:

  • 1: low
  • 2: medium
  • 3: high
  • 4: highest

No

-

The configuration takes effect when a HyperMetro volume is created.

Note:

  • If this parameter is not configured, the storage speed of the HyperMetro pair is determined by the storage device.
  • The highest synchronization speed may increase the host latency.

parameters.fsPermission

Permission on the directory mounted to a container.

No

-

For details about the configuration format, refer to the Linux permission settings, for example, 777 and 755.

All SAN storage devices are supported. Only the following NAS storage devices are supported: OceanStor Dorado, OceanStor, and OceanStor Pacific 8.1.2 and later versions.

parameters.rootSquash

Controls the root permission of the client.

The value can be:

  • root_squash: The client cannot access the storage system as user root. If a client accesses the storage system as user root, the client will be mapped as an anonymous user.
  • no_root_squash: A client can access the storage system as user root and has the permission of user root.

No

-

Only NAS storage is supported.

parameters.allSquash

Whether to retain the user ID (UID) and group ID (GID) of a shared directory.

The value can be:

  • all_squash: The UID and GID of the shared directory are mapped to anonymous users.
  • no_all_squash: The UID and GID of the shared directory are retained.

No

-

Only NAS storage is supported.

parameters.accesskrb5

Configures the krb5 security protocol.

  • read_only: read-only
  • read_write: read and write
  • none: no permission

No

-

During mounting, you can specify the sec parameter in mountOptions.

parameters.accesskrb5i

Configures the krb5i security protocol.

  • read_only: read-only
  • read_write: read and write
  • none: no permission

No

-

During mounting, you can specify the sec parameter in mountOptions.

parameters.accesskrb5p

Configures the krb5p security protocol.

  • read_only: read-only
  • read_write: read and write
  • none: no permission

No

-

During mounting, you can specify the sec parameter in mountOptions.

parameters.snapshotDirectoryVisibility

Whether the snapshot directory is visible.

The value can be:

  • visible: The snapshot directory is visible.
  • invisible: The snapshot directory is invisible.

No

-

Only NAS storage is supported.

parameters.reservedSnapshotSpaceRatio

Configures reserved snapshot space.

Value type: character string

Value range: 0 to 50

No

-

OceanStor Dorado 6.1.5+ and OceanStor 6.1.5+ NAS storage devices are supported.

parameters.description

Configures the description of the created file system or LUN.

Value type: character string

The value contains 0 to 255 characters.

No

-

Only enterprise storage file systems and LUNs are supported.

mountOptions.nfsvers

NFS mount option on the host. The following mount option is supported:

nfsvers: protocol version for NFS mounting. The value can be 3, 4, 4.0, 4.1, or 4.2.

No

-

This parameter is optional after the -o parameter when the mount command is executed on the host. The value is in list format.

If the NFS version is specified for mounting, NFS 3, 4.0, 4.1, and 4.2 protocols are supported (the protocol must be supported and enabled on storage devices). If nfsvers is set to 4, the latest protocol version NFS 4 may be used for mounting due to different OS configurations, for example, 4.2. If the 4.0 protocol is required, you are advised to set nfsvers to 4.0.

mountOptions.acl

The DPC namespace supports the ACL function. The DPC client supports POSIX ACL, NFSv4 ACL, and NT ACL authentication.

No

-

The descriptions of acl, aclonlyposix, cnflush, and cflush are for reference only. For details about the parameters, see OceanStor Pacific Series Product Documentation and choose Configuration > Basic Service Configuration Guide for File > Configuring Basic Services (DPC Scenario) > Accessing a DPC Share on a Client > Step 2.

mountOptions.aclonlyposix

The DPC namespace supports POSIX ACL, and the DPC client supports POSIX ACL authentication.

The following protocols support POSIX ACL: DPC, NFSv3, and HDFS. If NFSv4 ACL or NT ACL is used, the DPC client cannot identify the ACL of this type. As a result, the ACL of this type does not take effect.

No

-

If aclonlyposix and acl are used together, only acl takes effect. That is, the namespace supports the ACL function.

mountOptions.cnflush

Asynchronous disk flushing mode. That is, data is not flushed to disks immediately when files in the namespace are closed.

No

-

Asynchronous flushing mode: When a file is closed, data in the cache is not flushed to storage media in synchronous mode. Instead, data is written from the cache to the storage media in asynchronous flushing mode. After the write service is complete, data is flushed from the cache to disks periodically based on the flushing period. In a multi-client scenario, if concurrent operations are performed on the same file, the file size update is affected by the disk flushing period. That is, the file size is updated only after the disk flushing is complete. Generally, the update is completed within several seconds. Synchronous I/Os are not affected by the disk flushing period.

mountOptions.cflush

Synchronous disk flushing mode. That is, data is flushed to disks immediately when files in the namespace are closed.

No

-

By default, the synchronous disk flushing mode is used.

mountOptions.sec

Kerberos 5 protocol for mounting NFS file systems.

No

-

  • If Kerberos 5 is used, set this parameter to krb5.
  • If Kerberos 5i is used, set this parameter to krb5i.
  • If Kerberos 5p is used, set this parameter to krb5p.
  • Kerberos supports only NFSv4.0 or NFSv4.1.

mountOptions.proto

Transmission protocol used for NFS mounting.

The value can be rdma.

No

-

  • Ensure that NFS over RDMA is enabled on the storage system.
  • NAS storage of OceanStor Dorado 6.1.7 or later is supported.

mountOptions.port

Protocol port used for NFS mounting.

Conditionally mandatory

-

If the transmission protocol is rdma, set this parameter to 20049.

mountOptions.discard

Automatically triggers the Trim or Discard operation when a file system is mounted. This operation instructs a block device to release unused blocks.

No

-

The xfs and ext4 file systems are supported.

Table 2 Supported QoS configurations

Storage Type

Parameter

Description

Remarks

OceanStor V5

IOTYPE

Read/write type.

This parameter is optional. If it is not specified, the default value of the storage backend is used. For details, see related storage documents.

The value can be:

  • 0: read I/O
  • 1: write I/O
  • 2: read and write I/Os

MAXBANDWIDTH

Maximum bandwidth. This is a restriction policy parameter.

The value is an integer greater than 0, expressed in MB/s.

MINBANDWIDTH

Minimum bandwidth. This is a protection policy parameter.

The value is an integer greater than 0, expressed in MB/s.

MAXIOPS

Maximum IOPS. This is a restriction policy parameter.

The value is an integer greater than 0.

MINIOPS

Minimum IOPS. This is a protection policy parameter.

The value is an integer greater than 0.

LATENCY

Maximum latency. This is a protection policy parameter.

The value is an integer greater than 0, expressed in ms.

OceanStor Dorado V3

IOTYPE

Read/write type.

The value can be:

  • 2: read and write I/Os

MAXBANDWIDTH

Maximum bandwidth. This is a restriction policy parameter.

The value is an integer ranging from 1 to 999999999, expressed in MB/s.

MAXIOPS

Maximum IOPS. This is a restriction policy parameter.

The value is an integer ranging from 100 to 999999999.

OceanStor Dorado/OceanStor

IOTYPE

Read/write type.

The value can be:

  • 2: read and write I/Os

MAXBANDWIDTH

Maximum bandwidth. This is a restriction policy parameter.

The value is an integer ranging from 1 to 999999999, expressed in MB/s.

MINBANDWIDTH

Minimum bandwidth. This is a protection policy parameter.

The value is an integer ranging from 1 to 999999999, expressed in MB/s.

MAXIOPS

Maximum IOPS. This is a restriction policy parameter.

The value is an integer ranging from 100 to 999999999.

MINIOPS

Minimum IOPS. This is a protection policy parameter.

The value is an integer ranging from 100 to 999999999.

LATENCY

Maximum latency. This is a protection policy parameter.

The value can be 0.5 or 1.5, expressed in ms.

FusionStorage/OceanStor Pacific series

maxMBPS

Maximum bandwidth. This is a restriction policy parameter.

This parameter is mandatory. The value is an integer greater than 0, expressed in MB/s. For details about the maximum value, see the actual limit of the storage device. For example, the maximum value of OceanStor Pacific NAS is 1073741824.

maxIOPS

Maximum IOPS. This is a restriction policy parameter.

This parameter is mandatory. The value is an integer greater than 0. For details about the maximum value, see the actual limit of the storage device. For example, the maximum value of OceanStor Pacific NAS is 1073741824000.

Table 3 Supported quota configurations

Parameter

Description

Remarks

spaceQuota

File quota type.

This parameter is mandatory. Only softQuota or hardQuota can be configured.

gracePeriod

Grace period allowed when the soft quota is configured.

This parameter is conditionally optional only when spaceQuota is set to softQuota.

The value is an integer ranging from 0 to 4294967294.