From 37c8f07ed5ae016f5c3bbe012b59b3fffcc2cc77 Mon Sep 17 00:00:00 2001 From: Niels de Vos Date: Fri, 3 Mar 2023 12:15:38 +0100 Subject: [PATCH] rbd: do not run mkfs on a BlockMode volume Signed-off-by: Niels de Vos --- internal/rbd/nodeserver.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/rbd/nodeserver.go b/internal/rbd/nodeserver.go index 338b5791d..4f7e3d70d 100644 --- a/internal/rbd/nodeserver.go +++ b/internal/rbd/nodeserver.go @@ -781,7 +781,7 @@ func (ns *NodeServer) mountVolumeToStagePath( readOnly = true } - if existingFormat == "" && !staticVol && !readOnly { + if existingFormat == "" && !staticVol && !readOnly && !isBlock { args := mkfsDefaultArgs[fsType] // if the VolumeContext contains "mkfsOptions", use those as args instead