Remove conntrack entries from loadbalancer ip too.

This commit is contained in:
Pavithra Ramesh
2019-02-13 09:55:31 -08:00
parent cd2d33eaa3
commit 24d3ab83dc
4 changed files with 24 additions and 0 deletions

View File

@@ -619,6 +619,12 @@ func (proxier *Proxier) deleteEndpointConnections(connectionMap []proxy.ServiceE
klog.Errorf("Failed to delete %s endpoint connections for externalIP %s, error: %v", epSvcPair.ServicePortName.String(), extIP, err)
}
}
for _, lbIP := range svcInfo.LoadBalancerIPStrings() {
err := conntrack.ClearEntriesForNAT(proxier.exec, lbIP, endpointIP, v1.ProtocolUDP)
if err != nil {
klog.Errorf("Failed to delete %s endpoint connections for LoabBalancerIP %s, error: %v", epSvcPair.ServicePortName.String(), lbIP, err)
}
}
}
}
}