环境信息:
RKE2 版本: rke2 version v1.31.4+rke2r1
节点 CPU 架构,操作系统和版本:Linux 6.8.0-51-generic #52-Ubuntu SMP PREEMPT_DYNAMIC Thu Dec 5 13:09:44 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
集群配置:1master
问题描述:
使用rke2安装rancher和cert-manager,pod一直显示是ContainerCreating。describe pod
重现步骤:
- 安装 RKE2 的命令: install.sh 脚本安装
预期结果:
实际结果:
kubectl get pod -A -owide 部分pod无法创建,情况如下图:
kubectl -n cattle-system describe pod rancher-7c86d8d9bf-5896t
日志
kubectl -n cattle-system describe pod rancher-7c86d8d9bf-5896t
Events:
Type Reason Age From Message
Normal Scheduled 34m default-scheduler Successfully assigned cattle-system/rancher-7c86d8d9bf-5896t to liushuai
Warning FailedCreatePodSandBox 34m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “3a42f4ca195c43475b176d979c3cc13cb506c2109796a24d00f756cef6c8f747”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 34m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “6a2dcb470412c72a4d63d2a4bf695f11b98496c01af8f7ba45a914fd5684dda6”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 34m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “2bdaa2cdd88c962cb29b4d30dddb2009817a3483156f91c220ea8bba908ea862”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 34m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “551566c75a7dab9421542acc9aaf697f477311bb30204e823ff1ed9c30785653”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 33m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “ed5248800931232cf926ed6369beed367fde19e9e106abb172bd92a34ca80f8c”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 33m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “6829dd862eb2c7a4f02c4e33c7e5e4927a2aa07e601b08b552f81223e4df5e16”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 33m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “c8a47924a3e43e591bb9c0c0475cdd88b37584df49467d99d54232ff6e302a20”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 33m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “9489541e2ad5eb5bf64c8bcf4a59955fbf8629c7aaaccb39bc97cb48d45f2479”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 32m kubelet Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “c0c72a7a39bf3850fd8607ad01126043c149cd7f8bc18e0385a5d4b23e36515b”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254
Warning FailedCreatePodSandBox 4m27s (x122 over 32m) kubelet (combined from similar events): Failed to create pod sandbox: rpc error: code = Unknown desc = failed to setup network for sandbox “18c5d1d3c5b9008111b2299522b6ff81735c1f47a2e398b4b20ff65f0e000fe4”: plugin type=“calico” failed (add): failed to allocate for range 0: no IP addresses available in range set: 10.42.0.1-10.42.0.254