Kubeadm初始化报错:[ERROR CRI]: container runtime is not running: output:

在初始化kubeadm的时候出现了如下错误:

复制代码
[root@centos7-1 ~]# sudo kubeadm init

[init] Using Kubernetes version: v1.26.0
[preflight] Running pre-flight checks
    [WARNING Firewalld]: firewalld is active, please ensure ports [6443 10250] are open or your cluster may not function correctly
    [WARNING Swap]: swap is enabled; production deployments should disable swap unless testing the NodeSwap feature gate of the kubelet
    [WARNING Hostname]: hostname "centos7-1" could not be reached
    [WARNING Hostname]: hostname "centos7-1": lookup centos7-1 on 192.168.3.2:53: no such host
    [WARNING Service-Kubelet]: kubelet service is not enabled, please run 'systemctl enable kubelet.service'
error execution phase preflight: [preflight] Some fatal errors occurred:
    [ERROR CRI]: container runtime is not running: output: E1222 04:36:50.586954   20582 remote_runtime.go:948] "Status from runtime service failed" err="rpc error: code = Unimplemented desc = unknown service runtime.v1alpha2.RuntimeService"
time="2022-12-22T04:36:50-05:00" level=fatal msg="getting status of runtime: rpc error: code = Unimplemented desc = unknown service runtime.v1alpha2.RuntimeService"
, error: exit status 1
[preflight] If you know what you are doing, you can make a check non-fatal with `--ignore-preflight-errors=...`
To see the stack trace of this error execute with --v=5 or higher
复制代码

按照如下命令进行操作

[root@centos7-1 ~]# rm -rf /etc/containerd/config.toml 
[root@centos7-1 ~]# systemctl restart containerd

然后再次执行初始化就可以了

[root@centos7-1 ~]# sudo kubeadm init

OK了!

 

posted @   Old·Artist  阅读(2691)  评论(0编辑  收藏  举报
相关博文:
阅读排行:
· DeepSeek 开源周回顾「GitHub 热点速览」
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· AI与.NET技术实操系列(二):开始使用ML.NET
· 单线程的Redis速度为什么快?
历史上的今天:
2017-12-22 Centos6.8 搭建Lvs+Keepalived
2017-12-22 Centos 6.8 配置Lvs
2017-12-22 Git如何克隆Gitlab?Git本地仓库如何上传Gitlab?
2017-12-22 Centos 7.x 配置Gitlab
2017-12-22 使用Git分布式版本控制系统
点击右上角即可分享
微信分享提示