Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why the provisioner only support ReadWriteOnce #70

Closed
philpep opened this issue Jan 14, 2020 · 10 comments
Closed

Why the provisioner only support ReadWriteOnce #70

philpep opened this issue Jan 14, 2020 · 10 comments

Comments

@philpep
Copy link

philpep commented Jan 14, 2020

Why the provisioner only support ReadWriteOnce pvc and not ReadOnlyMany/ReadWriteMany.

Since it's just a node-local directory, there's no problem with having multiple writer/readers as long as the application support this.

@yasker
Copy link
Member

yasker commented Jan 14, 2020

I am not sure I get what do you mean...

PV can only be used by the local node, and that's one node.

@philpep
Copy link
Author

philpep commented Jan 14, 2020

Hmm, I think I misunderstood goals of this project...
I thought that volumes created by local-path-provisioner where bound to a node and thus pods using the volume are automatically bound (via nodeAffinity) to the same node, and in this case ReadWriteMany is possible.

@yasker
Copy link
Member

yasker commented Jan 14, 2020

@philpep Yeah, the pod would be scheduled to the volume. But from the volume's perspective, it's still only capable of single node read/write. The pods on the other nodes cannot read/write the volume, so the volume is still RWO.

Though if you have multiple pods on the same node, they can read/write the volume at the same time. RWO is only about the node, not pods.

@philpep
Copy link
Author

philpep commented Jan 16, 2020

Ok thanks for the explanations @yasker !

@philpep philpep closed this as completed Jan 16, 2020
@lsoica
Copy link

lsoica commented May 8, 2020

@yasker I also hit this limitation. My use case is that I am buiding a platform that could be installed both as single node k8s and multi node. For single node I am using a local storage provisioned, for multi node I'm leveraging rook. Now, I would like that for the apps deployed on top, the underlying storage provider to be transparent.

Some of the apps would need a storage class for shared volumes. I would like to use the same SC name, but in single node to be served by local provisioner, in multinode to be served by rook ceph. But the shared volumes requires RWX. So I cannot use this provisioner for local volumes.

Is there a real need for this restriction ?

@0xMH
Copy link

0xMH commented May 26, 2020

I hit this exact limitation just lately when I was testing ReadWriteMany on kind. I know that being on single node RWX isn't need but does it causes any side effects hence its a restriction?

@acim
Copy link

acim commented Jan 9, 2021

Yes, it would be nice to have this possibility. I am running single node anyway and want to do volume backups using CronJob resource, I don't want to run backup on the host itself.

@dchirikov
Copy link
Contributor

The path can be mounted on every node via NFS/Luster/GPFS/BeeGFS or other distributed FS, so I think this limitation should be tunable. Make it sense to make this behavior configurable?

@hwk42
Copy link

hwk42 commented Jun 3, 2021

Is it possible to support RWX , for example, as an option? In my case,pv is created by app with RWX mode,which is required by multi node env

@travisghansen
Copy link

travisghansen commented Jul 24, 2022

I have a local hostpath driver as part of my project here: https://github.com/democratic-csi/democratic-csi

It does allow rwx but implicitly pins the volume through topology should crazy scenarios come up (ie: it’s safe to use in multi-node clusters as well).

It also supports snapshots and clones (crudely via rsync).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

8 participants