<p>Here is an example of <code>.yml</code> file to create an PersistentVolume on a kubernetes cluster:</p>

<pre><code>apiVersion: v1
kind: PersistentVolume
metadata:
  name: task-pv-volume
  namespace: prisma
  labels:
    type: local
spec:
  storageClassName: manual
  capacity:
    storage: xxGi
  accessModes:
    - ReadWriteOnce
  hostPath:
    path: "/data"
</code></pre>

<p>Can the storage capacity be more than the available storage capacity on the node with the smallest disk in the cluster? Or the maximum is the sum of available disk on the cluster nodes ?</p>

<p>generally you are binding the <code>pv</code> to an external storage volume your cloud provider offers (for example - aws EBS), abstracted as a <code>StorageClass</code>, in a size that matches your needs. cluster nodes come and go, you shouldn't rely on their storage.</p>

<p>quick guides: <a href="https://cloud.google.com/kubernetes-engine/docs/concepts/persistent-volumes" rel="nofollow noreferrer">gcp</a> <a href="https://medium.com/@tanzwud.work/k8s-dynamic-provisioning-of-persistent-volumes-on-aws-449902f9c69e" rel="nofollow noreferrer">aws</a> <a href="https://learn.microsoft.com/en-au/azure/aks/azure-disks-dynamic-pv" rel="nofollow noreferrer">azure</a></p>
