Static provisioner of local volumes
The local volume static provisioner manages PersistentVolume lifecycle for
pre-allocated disks by detecting and creating PVs for each local disk on the
host, and cleaning up the disks when released. It does not support dynamic
provisioning.
Local persistent volumes allows users to access local storage through the
standard PVC interface in a simple and portable way. The PV contains node
affinity information that the system uses to schedule pods to the correct
nodes.
An external static provisioner is provided here to help
simplify local storage management once the local volumes are configured. Note
that the local storage provisioner is different from most provisioners and does
not support dynamic provisioning. Instead, it requires that administrators
preconfigure the local volumes on each node and if volumes are supposed to be
The provisioner will manage the volumes under the discovery directories by creating
and cleaning up PersistentVolumes for each volume.
A caveat to scheduling a Pod on the same node as its local PV is that when the node hosting the PV is deleted, while the data is likely lost, the PV object still exists and therefore the system is indefinitely trying to schedule the Pod to a deleted node. See our local volume node cleanup documentation which contains information on how to make your workloads automatically recover from node deletion.
To get started with local static provisioning, you can follow our getting
started guide to bring up a Kubernetes cluster with
some local disks, deploy local-volume-provisioner to provision local volumes
and use PVC in your pod to request a local PV.
See our operations documentation which contains of
preparing, setting up and cleaning up local volumes on the nodes.
See our helm documentation for how to deploy and configure
local-volume-provisioner in Kubernetes cluster with helm.
If you want to manage provisioner with plain YAML files, you can refer to our
example yamls. helm generated
yamls are good sources of examples too.
Here is a full explanation of provisioner
configuration.
See our upgrading documentation for how to upgrade
provisioner version or update configuration in Kubernetes cluster.
See FAQs.
See Best Practices.
Recommended provisioner versions with Kubernetes versions
Provisioner version | K8s version |
---|---|
2.7.0 | 1.21+ |
2.6.0 | 1.12+ |
2.5.0 | 1.12+ |
Also see known issues and CHANGELOG.
Run ./hack/e2e.sh -h
to view help.
Learn how to engage with the Kubernetes community on the community page.
You can reach the maintainers of this project at:
Participation in the Kubernetes community is governed by the Kubernetes Code of Conduct.