diff --git a/pkg/proxy/ipvs/proxier.go b/pkg/proxy/ipvs/proxier.go index 66883e18dc3..3ea8ec04ed3 100644 --- a/pkg/proxy/ipvs/proxier.go +++ b/pkg/proxy/ipvs/proxier.go @@ -1643,6 +1643,10 @@ func (proxier *Proxier) cleanLegacyService(activeServices map[string]bool, curre // Applying graceful termination to all real servers for _, rs := range rsList { uniqueRS := GetUniqueRSName(svc, rs) + // If RS is already in the graceful termination list, no need to add it again + if proxier.gracefuldeleteManager.InTerminationList(uniqueRS) { + continue + } klog.V(5).Infof("Using graceful delete to delete: %v", uniqueRS) if err := proxier.gracefuldeleteManager.GracefulDeleteRS(svc, rs); err != nil { klog.Errorf("Failed to delete destination: %v, error: %v", uniqueRS, err)