Failed to create pod sandbox: rpc error: code = Unknown desc = [failed to set up sandbox container "3bf7500d12ae67983dcd2795d2feb168dceb563ac78afa5508d973db84ed5b47" network for pod "coredns-6f4c9cb7c5-jg5mj": networkPlugin cni failed to set up pod "coredns-6f4c9cb7c5-jg5mj_kube-system" network: failed to find plugin "loopback" in path [/opt/cni/bin], failed to clean up sandbox container "3bf7500d12ae67983dcd2795d2feb168dceb563ac78afa5508d973db84ed5b47" network for pod "coredns-6f4c9cb7c5-jg5mj": networkPlugin cni failed to teardown pod "coredns-6f4c9cb7c5-jg5mj_kube-system" network: failed to find plugin "portmap" in path [/opt/cni/bin]]
Unable to update cni config: no valid networks found in /etc/cni/net.d
方法1
cat <
[kubernetes]
name=Kubernetes
baseurl=https://mirrors.aliyun.com/kubernetes/yum/repos/kubernetes-el7-x86_64
enabled=1
gpgcheck=0
repo_gpgcheck=0
gpgkey=https://mirrors.aliyun.com/kubernetes/yum/doc/yum-key.gpg https://mirrors.aliyun.com/kubernetes/yum/doc/rpm-package-key.gpg
EOF
yum clean all && yum makecache && yum -y install kubernetes-cni
方法二
https://github.com/containernetworking/plugins/releases
kubectl describe po coredns-5dd5756b68-rc5t8 --namespace kube-system
kubectl describe po coredns-5dd5756b68-85rjp --namespace kube-system
删除pod
kubectl delete pods coredns-5dd5756b68-5rbzh -n kube-system
kubectl delete pods coredns-5dd5756b68-rc5t8 -n kube-system --force
kubectl delete pods coredns-5dd5756b68-wg7xn -n kube-system --force
kubectl -n kube-system get deployment coredns -o yaml | kubectl apply -f -Bash
ECS Linux服务器loopback网卡的作用说明
主机中的loopback的作用
请注意:loopback网卡这个为本地的回环网卡,就是客户在服务器进行自访问测试127.0.0.1或localhost时使用的网卡,若禁用的话在本机测试会无法进行自访问的,而且届时也将会无法ping通,建议不要进行禁用。
k8s网络插件有哪些
Kubernetes网络插件主要有以下几种:
选择网络插件时,应根据具体需求来决定。例如,如果需要大规模的网络策略和安全性管理,Calico可能是一个好选择;如果需要跨节点通信的高性能实现,Flannel可能更适合。每种插件都有其独特的优势和适用场景,选择时应根据实际需求进行评估