From 44cc29b328166ff0553155347839d9246dd735d1 Mon Sep 17 00:00:00 2001 From: Chin-Ya Huang Date: Thu, 1 Aug 2024 10:25:10 +0800 Subject: [PATCH] feat(restore): skip loading endpoint during initiator start when dmDeviceAndEndpointCleanupRequired longhorn/longhorn-6613 Signed-off-by: Chin-Ya Huang --- pkg/nvme/initiator.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/nvme/initiator.go b/pkg/nvme/initiator.go index efc5762..72c82ae 100644 --- a/pkg/nvme/initiator.go +++ b/pkg/nvme/initiator.go @@ -261,7 +261,7 @@ func (i *Initiator) Start(transportAddress, transportServiceID string, dmDeviceA // Check if the initiator/NVMe device is already launched and matches the params if err := i.loadNVMeDeviceInfoWithoutLock(i.TransportAddress, i.TransportServiceID, i.SubsystemNQN); err == nil { if i.TransportAddress == transportAddress && i.TransportServiceID == transportServiceID { - if err = i.LoadEndpoint(false); err == nil { + if err = i.LoadEndpoint(dmDeviceAndEndpointCleanupRequired); err == nil { i.logger.Info("NVMe initiator is already launched with correct params") return false, nil }