Skip to content

Commit

Permalink
Merge pull request #269 from riya-singhal31/lvmcluster
Browse files Browse the repository at this point in the history
fix: deletion of lvmcluster which includes wrong paths
  • Loading branch information
openshift-merge-robot authored Sep 30, 2022
2 parents 7eac419 + 8cbb4fd commit 9bc9d38
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions pkg/vgmanager/vgmanager_controller.go
Original file line number Diff line number Diff line change
Expand Up @@ -324,6 +324,12 @@ func (r *VGReconciler) processDelete(ctx context.Context, volumeGroup *lvmv1alph
}
if lvmdConfig == nil {
r.Log.Info("lvmd config file does not exist")
// Remove the VG entry in the lvmvolumegroupnodestatus that was added to indicate the failures to the user.
// This allows the lvmcluster to get deleted and not stuck/wait forever as lvmcluster looks for the lvmvolumegroupnodestatus before deleting.
if statuserr := r.updateStatus(ctx, nil); statuserr != nil {
r.Log.Error(statuserr, "failed to update status", "VGName", volumeGroup.Name)
return statuserr
}
return nil
}
// To avoid having to iterate through device classes multiple times, map from name to config index
Expand Down

0 comments on commit 9bc9d38

Please sign in to comment.