From 6a158ba0c0cd7e62f7a1fc2da1c16f35d7e3ddca Mon Sep 17 00:00:00 2001 From: Prasanna Kumar Kalever Date: Sun, 14 Nov 2021 14:33:01 +0530 Subject: [PATCH] rbd: fix mapOptions passing with rbd-nbd mounter This was a regression introduced by: https://github.com/ceph/ceph-csi/pull/2556 Fixes: #2610 Signed-off-by: Prasanna Kumar Kalever --- internal/rbd/nodeserver.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/rbd/nodeserver.go b/internal/rbd/nodeserver.go index b14a381b99ab..fde4f83122cf 100644 --- a/internal/rbd/nodeserver.go +++ b/internal/rbd/nodeserver.go @@ -226,14 +226,14 @@ func populateRbdVol( } } if krbdSupported { - rv.MapOptions = req.GetVolumeContext()["mapOptions"] - rv.UnmapOptions = req.GetVolumeContext()["unmapOptions"] rv.Mounter = req.GetVolumeContext()["mounter"] } else { // fallback to rbd-nbd, // ignore the mapOptions and unmapOptions as they are meant for krbd use. rv.Mounter = rbdNbdMounter } + rv.MapOptions = req.GetVolumeContext()["mapOptions"] + rv.UnmapOptions = req.GetVolumeContext()["unmapOptions"] rv.VolID = volID