mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-25 07:40:19 +00:00
rbd: unset snapshot metadata on CreateVolume From snapshot
Unset the snapshot metadata from the rbd image created from the snapshot Signed-off-by: Prasanna Kumar Kalever <prasanna.kalever@redhat.com>
This commit is contained in:
parent
d89c5fb39f
commit
e0f34a6d60
@ -591,6 +591,12 @@ func (cs *ControllerServer) createVolumeFromSnapshot(
|
||||
|
||||
return err
|
||||
}
|
||||
err = rbdVol.unsetAllMetadata(k8s.GetSnapshotMetadataKeys())
|
||||
if err != nil {
|
||||
log.ErrorLog(ctx, "failed to unset snapshot metadata on rbd image %q: %v", rbdVol, err)
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
log.DebugLog(ctx, "create volume %s from snapshot %s", rbdVol, rbdSnap)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user