
Vultr offers persistent storage options for Kubernetes through both Vultr Block Storage (VBS) and the Vultr File System (VFS). These storage solutions are integrated with the Vultr Kubernetes Engine (VKE) to support a wide range of application needs—from high-performance single-node volumes to shared, multi-node file systems. VKE includes a managed Kubernetes control plane that automatically installs the Vultr Container Storage Interface (CSI), enabling seamless access to these storage types and allowing your applications to scale with ease.
In this guide, you will provision persistent volumes using both Vultr Block Storage (VBS) and Vultr File System (VFS), and learn how to update the configuration to perform PVC expansion where supported.
Before you begin:
KUBECONFIG) for cluster management.Vultr provides two types of persistent storage technologies for Kubernetes workloads, available in most global regions: Vultr Block Storage and Vultr File System (VFS). These options support a variety of performance, capacity, and access mode requirements.
Vultr Block Storage supports ReadWriteOnce (RWO) access mode and is ideal for high-performance or large-capacity workloads where each volume is attached to a single node.
HDD Block Storage – A cost-effective solution using traditional spinning hard drives. Suitable for workloads that require large capacity over speed.
vultr-block-storage-hddNVMe Block Storage – A high-performance option backed by solid-state NVMe drives. Best for latency-sensitive or IOPS-intensive applications.
vultr-block-storageThe Vultr File System provides ReadWriteMany (RWX) access, allowing multiple pods across different nodes to read and write to the same volume simultaneously. It’s ideal for shared data use cases such as content management systems, collaborative apps, and distributed workloads.
vultr-vfs-storageTo check availability in your region, use the /v2/regions API endpoint.
Look for the following flags in the response:
block_storage_storage_opt: Indicates HDD Block Storage availabilityblock_storage_high_perf: Indicates NVMe Block Storage availabilitySome locations support both storage classes. If NVMe block storage is available in a location, our CSI uses that class by default.
In this section, you are to create a PVC using a YAML configuration file with ReadWriteOnce (RWO) access mode.
Create a configuration file.
Copy and paste the below given configuration.
Save and exit the file.
In the above configuration, you are requesting an NVMe block storage volume with a size of 10Gi using the vultr-block-storage storage class. This PVC uses the ReadWriteOnce access mode, meaning it can be mounted as read-write by a single node.
Supported Vultr Block Storage types and minimum size requirements:
NVMe Block Storage
storageClassName: vultr-block-storage10GiHDD Block Storage
storageClassName: vultr-block-storage-hdd40Gi To use HDD block storage, update the storageClassName to vultr-block-storage-hdd and set the storage request to at least 40Gi in the above configuration.
Apply the configuration file.
Output
Verify that a new Vultr Block Storage is provisioned.
Output
You can verify the same by navigating to Cloud Storage then Block Storage on your Vultr Console.
In this section, you are to expand the storage capacity of an existing VBS attached to your instance.
Change the configuration file.
Increase the storage capacity.
Save and exit the file.
In the above configuration, you increased the storage capacity for an existing NVMe block storage to 30 GB from the original 10 GB.
Apple the configuration changes.
Output
Verify the change.
Output
You can verify the same by navigating to Cloud Storage then Block Storage on your Vultr portal.
It is not advised to reduce the storage capacity of the VBS as the action may result in significant data loss.
Vultr File System volumes can be used as Persistent Volumes in Kubernetes using the vultr-vfs-storage storage class.
Create a new manifest for PVC resource.
In this example, the PVC resource test-rwx is created with a capacity of 10Gi and access mode ReadWriteMany. The storage class vultr-vfs-storage is used to provision the VFS volume.
Apply the PVC manifest.
Output:
List the PVC resource.
The PVC resource test-rwx should be listed with the status Bound.
Output:
If you are unable to reproduce the same behaviour as noted above, you can try troubleshooting to get more information.
Describe the PVC resource.
You can review the events for any issues related to provisioning of the VFS volume.
List all storage classes.
The list must contain vultr-vfs-storage in order to provision a VFS volume.
Ensure sufficient quota allocation.
Monitor cluster events for storage issues.
In this guide, you learned about the different persistent storage types and classes available globally on Vultr, including both Vultr Block Storage (VBS) and Vultr File System (VFS). You provisioned an HDD block storage volume and also explored how to expand the storage of an existing volume attached to a Kubernetes cluster.
0 Comments
Be the first to comment and share your perspective with the community.