Current situation:
Currently, CephFS backends in Manila are limited to only creating snapshots - Manila does not offer create_share_from_snapshot_support capability for CephFS just yet. From CSI side of things, the spec doesn't allow advertising CREATE_DELETE_SNAPSHOT without supporting snapshot volume source in CreateVolumeRequest - which means that csi-manila must forbid CephFS snapshots altogether.
Proposed solution:
Given this is one of the more sought-after features, csi-manila tries to fill out this gap with in-driver functionality (i.e. a compatibility layer) until it's supported natively by Manila. The driver checks for Manila capabilities by reading extra specs from the share type of the source share. Based on those the driver either chooses to use Manila's native support or a compatibility layer, if one exists.
In order to create a share from a CephFS snapshot, the data needs to be copied over from the snapshot into a new share. CSI Manila will therefore create a blank (destination) share, mount it, mount the source share containing the snapshot and copy the data to destination using rsync.
Implementation:
The code is finished and ready for PRs. I can post those right after #714 is done.
Current situation:
Currently, CephFS backends in Manila are limited to only creating snapshots - Manila does not offer
create_share_from_snapshot_supportcapability for CephFS just yet. From CSI side of things, the spec doesn't allow advertisingCREATE_DELETE_SNAPSHOTwithout supporting snapshot volume source inCreateVolumeRequest- which means that csi-manila must forbid CephFS snapshots altogether.Proposed solution:
Given this is one of the more sought-after features, csi-manila tries to fill out this gap with in-driver functionality (i.e. a compatibility layer) until it's supported natively by Manila. The driver checks for Manila capabilities by reading extra specs from the share type of the source share. Based on those the driver either chooses to use Manila's native support or a compatibility layer, if one exists.
In order to create a share from a CephFS snapshot, the data needs to be copied over from the snapshot into a new share. CSI Manila will therefore create a blank (destination) share, mount it, mount the source share containing the snapshot and copy the data to destination using rsync.
Implementation:
create_share_from_snapshot_supportcompatibility layer for native CephFSThe code is finished and ready for PRs. I can post those right after #714 is done.