Skip to content

Commit

Permalink
fix(disk): no need to check disk UUID while deleting a disk
Browse files Browse the repository at this point in the history
Longhorn 9126

Signed-off-by: Derek Su <[email protected]>
  • Loading branch information
derekbit committed Jul 31, 2024
1 parent 76191be commit 403dc24
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions controller/node_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -1699,10 +1699,7 @@ func (nc *NodeController) alignDiskSpecAndStatus(node *longhorn.Node) {
}

func (nc *NodeController) deleteDisk(diskType longhorn.DiskType, diskName, diskUUID, diskPath, diskDriver string) error {
if diskUUID == "" {
log.Infof("Disk %v has no diskUUID, skip deleting", diskName)
return nil
}
log.Infof("Deleting disk %v with diskUUID %v", diskName, diskUUID)

dataEngine := util.GetDataEngineForDiskType(diskType)

Expand Down

0 comments on commit 403dc24

Please sign in to comment.