mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-07-22 11:21:47 +00:00
Merge pull request #54120 from m1093782566/fix-proxy-mode
Automatic merge from submit-queue (batch tested with PRs 54906, 54120, 54934, 54915, 54848). If you want to cherry-pick this change to another branch, please follow the instructions <a href="https://github.com/kubernetes/community/blob/master/contributors/devel/cherry-picks.md">here</a>. Fix kube-proxy fall back to iptables firstly when unable to load kernel modules **What this PR does / why we need it**: Fix kube-proxy fall back to iptables firstly when unable to load kernel modules **Which issue this PR fixes**: fixes #54121 **Special notes for your reviewer**: **Release note**: ```release-note NONE ``` /kind bug /sig network /area kube-proxy
This commit is contained in:
commit
b006bc5d04
@ -275,8 +275,8 @@ func tryIPVSProxy(iptver iptables.IPTablesVersioner, kcompat iptables.KernelComp
|
|||||||
// IPVS Proxier relies on iptables
|
// IPVS Proxier relies on iptables
|
||||||
useIPVSProxy, err := ipvs.CanUseIPVSProxier()
|
useIPVSProxy, err := ipvs.CanUseIPVSProxier()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
utilruntime.HandleError(fmt.Errorf("can't determine whether to use ipvs proxy, using userspace proxier: %v", err))
|
// Try to fallback to iptables before falling back to userspace
|
||||||
return proxyModeUserspace
|
utilruntime.HandleError(fmt.Errorf("can't determine whether to use ipvs proxy, error: %v", err))
|
||||||
}
|
}
|
||||||
if useIPVSProxy {
|
if useIPVSProxy {
|
||||||
return proxyModeIPVS
|
return proxyModeIPVS
|
||||||
|
Loading…
Reference in New Issue
Block a user