Question

Kuberntes PVC ReadWriteMany access mode alternative

Hello Everyone,

According to documentation on DO regarding PVC, it can have only ReadWriteOnce access mode, it means that this PVC can be acessible by only one pod/node . However I have an app that I want to scale between several nodes. Each pod located on own node + load balancer for traffic, and problem is - each pod should have access to shared media files (images etc, write and read), , but with ReadWriteOnce pods can not access to PVC from different nodes. This problem could be easily solved with ReadWriteMany access mode for PVC

Is there is a way to build volume on DO kubernetes cluster, that could be shared between kubernetes nodes

Subscribe
Share

Submit an answer
You can type!ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!

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.

Take a look at the Digital Ocean section here: https://medium.com/asl19-developers/create-readwritemany-persistentvolumeclaims-on-your-kubernetes-cluster-3a8db51f98e3

I am using s3-csi on Digital Ocean Spaces with the Goofys mounter to achieve readWriteMany.

I was able to make an nfs-server that a do-block storage is attached. the problem is the inability to replicate the nfs-server. do we have any solution for this?

Going to give a try to @lex19 approach and see how it works, on our case we only have a few writes.

@jwdobken I have created NFS on separate droplet, and using it as shared volume for pods that require it, it works properly. Previously I have tried to setup nfs inside cluster but decided to check if NFS matches my requirements (does it give any locks etc ) on separate droplet first, additionally it was easier to configure backups that I must have

I am curious, did you got any further? I now run pods on dedicated nodes with nodeSelector and labels.

This comment has been deleted

Hello Lennard, thanks I’ll try it out.

I am also thinking to create POD with NFS and share it between nodes

https://matthewpalmer.net/kubernetes-app-developer/articles/kubernetes-volumes-example-nfs-persistent-volume.html

I will provide feedback about my research

I also come across this today: https://github.com/CTrox/csi-s3 not working on kubernetes 1.12 for now but if that is fixed that could also a solution.

I was self considering a sort of S3FS mount with spaces, and that build-in in my docker container. But the ideal situation is ReadWriteMany mount of course!