千家信息网

k8s1.16.0 +flannel+kube-proxy出现 --random-fully解决

发表于:2025-02-01 作者:千家信息网编辑
千家信息网最后更新 2025年02月01日,出现错误日志日志kube-proxy 日志:I0923 10:19:59.443659 543401 proxier.go:1729] Not using `--random-fully` in t
千家信息网最后更新 2025年02月01日k8s1.16.0 +flannel+kube-proxy出现 --random-fully解决

出现错误日志日志

kube-proxy 日志:I0923 10:19:59.443659  543401 proxier.go:1729] Not using `--random-fully` in the MASQUERADE rule for iptables because the local version of iptables does not support itkubelet日志:I0923 11:24:47.087532    1941 kubelet_network_linux.go:111] Not using `--random-fully` in the MASQUERADE rule for iptables because the local version of iptables does not support it持续不间断出现这样的错误按照错误日志提示iptables 本地版本不支持升级iptables 

安装升级iptables所需依赖

yum install gcc make libnftnl-devel libmnl-devel autoconf automake libtool bison flex  libnetfilter_conntrack-devel libnetfilter_queue-devel libpcap-devel

编译安装iptables

export LC_ALL=Cwget wget https://www.netfilter.org/projects/iptables/files/iptables-1.6.2.tar.bz2tar -xvf iptables-1.6.2.tar.bz2cd iptables-1.6.2 ./autogen.sh ./configure make -j4 make install # 当然可以把cd /usr/local/sbin下面的iptables相关的东西打包然后分发到其它服务器cd /usr/local/sbin \cp iptables /sbin\cp iptables-restore /sbin/\cp iptables-save /sbin/

重启 kube-proxy 与 kubelet

service kube-proxy restartservice kubelet restart# 再次观察已经没有此日志出现一切恢复正常。
0