update-alternatives:错误:arptables 的替代/usr/sbin/arptables-legacy 未注册;不设置 [英] update-alternatives: error: alternative /usr/sbin/arptables-legacy for arptables not registered; not setting

查看:33
本文介绍了update-alternatives:错误:arptables 的替代/usr/sbin/arptables-legacy 未注册;不设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Buster 主机上安装了 Debian 10 (Buster) KVM 客户机.尝试在 Debian wiki

iptables>

I've Debian 10 (Buster) KVM guest machines on a Buster host. Trying to switch to the legacy iptables on VMs following Debian wiki

update-alternatives --set iptables /usr/sbin/iptables-nft
update-alternatives --set ip6tables /usr/sbin/ip6tables-nft
update-alternatives --set arptables /usr/sbin/arptables-nft
update-alternatives --set ebtables /usr/sbin/ebtables-nft

虽然其他三个成功,但 arptables 更新失败并显示消息

While other three succeeds, arptables update fails with the message

update-alternatives: error: alternative /usr/sbin/arptables-legacy for arptables not registered; not setting

有解决办法吗?

如果您好奇,来宾机器是使用 kubeadm 启动的 Kubernetes (v1.18) 集群的节点.网络插件是 Calico.除了 MetalLB 控制器错误

If you're curious, guest machines are nodes of a Kubernetes (v1.18) cluster initiated with kubeadm. Network plugin is Calico. Everything works with default nftables settings except that MetalLB controller errors

 1 reflector.go:125] pkg/mod/k8s.io/client-go@v0.0.0-20190620085101-78d2af792bab/tools/cache/reflector.go:98: Failed to list *v1.ConfigMap: Get https://10.96.0.1:443/api/v1/namespaces/metallb-system/configmaps?fieldSelector=metadata.name%3Dconfig&limit=500&resourceVersion=0: dial tcp 10.96.0.1:443: i/o timeout

当我从访客 VM ping 10.96.0.1 时,我得到

When I ping 10.96.0.1 from guest VM, I get

PING 10.96.0.1 (10.96.0.1) 56(84) bytes of data.
From 94.157.208.1 icmp_seq=1 Packet filtered
From 94.157.208.1 icmp_seq=2 Packet filtered
...

--- 10.96.0.1 ping statistics ---
7 packets transmitted, 0 received, +7 errors, 100% packet loss, time 15ms

推荐答案

首先需要安装遗留包:

sudo apt-get install -y iptables arptables ebtables

然后更新替代方案:

sudo update-alternatives --set iptables /usr/sbin/iptables-legacy
sudo update-alternatives --set ip6tables /usr/sbin/ip6tables-legacy
sudo update-alternatives --set arptables /usr/sbin/arptables-legacy
sudo update-alternatives --set ebtables /usr/sbin/ebtables-legacy

这篇关于update-alternatives:错误:arptables 的替代/usr/sbin/arptables-legacy 未注册;不设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆