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

[PoC] ReadWriteMany support #45

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

[PoC] ReadWriteMany support #45

wants to merge 2 commits into from

Conversation

kvaps
Copy link

@kvaps kvaps commented May 3, 2023

This is proof-of-concept for ReadWriteMany support #44

The design is simple:

  • RWX volumes are openned with shared lock
  • Volumes have no owner tags assigned (LVs opened in shared mode do not support assigning tags and actually do not require this owner tag, because it can be assigned to multiple nodes)
  • in case of resize we relock volume in exclusive mode, then resize it, then switch back to shared lock.

What tested:

  • RWX volumes provisioning (works)
  • Attach/detach of block volumes (works)
  • KubeVirt live migration (works)
  • LiveVolume resizing (works)

What is not tested:

  • Creating of snapshots

@kvaps
Copy link
Author

kvaps commented May 3, 2023

@aleofreddi Unfortunately I have no time to continue with this proposal right now. It worked for me, but of course this PR requires some rework.
Feel free to use my research to implement this feature, or possible I will implement it by my own later.

@kvaps kvaps marked this pull request as draft May 3, 2023 08:41
@aleofreddi
Copy link
Owner

@kvaps thank you for putting this one together!

Indeed if I recall correctly, snapshots & shared logical volumes do not play well together, but still I'm more inclined to have this feature in (and disallow snapshots for ReadWriteMany volumes) rather than keeping it out.

When I have some free time I'll do some testing and pick it up from here.

@kvaps
Copy link
Author

kvaps commented May 3, 2023

Would snapshots work the same way as volume resizing Eg when you lock shared volume in exclusive mode, then make snapshot, then lock it back to shared mode. This would allow to have both useful features for KubeVirt VMs: live migration and snapshots

@aleofreddi
Copy link
Owner

Yes, but I'm not sure they will work well afterwards. If I recall correctly, I've looked at this when I started the driver and found out that these are unsupported (ref. https://www.suse.com/support/kb/doc/?id=000019652); but I'm not sure this is still the case - definitely worth checking.

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

Successfully merging this pull request may close these issues.

2 participants