Join 1M+ other developers and:
- Get help and share knowledge in Q&A
- Subscribe to topics of interest
- Get courses & tools that help you grow as a developer or small business owner
How to specify filesystem for Persistent Volumes in k8s cluster?
I have a Kubernetes cluster with a deployment which uses automatically provisioned block storage. My question is:
How can I specify the filesystem for the Persistent Volume? I would like for the Persistent Volume to be created with XFS in my case (my service is a MongoDB which recommends XFS filesystem).
Here is the section from my manifest for the Claim and volume mount:
... volumeMounts: - name: mongo-raw-volume-claim mountPath: /data/db volumeClaimTemplates: - metadata: name: mongo-raw-volume-claim spec: accessModes: [ "ReadWriteOnce" ] storageClassName: do-block-storage resources: requests: storage: 100Gi
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.×