Skip to content

Commit 4429a99

Browse files
iPraveenPariharmergify[bot]
authored andcommitted
rbd: correct default encryption type
Problem: When the encryptionType is not specified in the StorageClass, the default type (block) is used and stored in OMAP. However, during OMAP regeneration in a secondary cluster, the default type is incorrectly set to none. This discrepancy leads to errors during PVC cloning, with the message: `cannot create encrypted volume from unencrypted volume.` Solution: Update the default encryption type to consistently use block instead of none. Signed-off-by: Praveen M <[email protected]> (cherry picked from commit 0cfb2b0)
1 parent 2f813da commit 4429a99

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/rbd/rbd_journal.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -599,7 +599,7 @@ func RegenerateJournal(
599599

600600
rbdVol.Owner = owner
601601

602-
kmsID, encryptionType, err = ParseEncryptionOpts(volumeAttributes, util.EncryptionTypeNone)
602+
kmsID, encryptionType, err = ParseEncryptionOpts(volumeAttributes, rbdDefaultEncryptionType)
603603
if err != nil {
604604
return "", err
605605
}

0 commit comments

Comments
 (0)