报错具体内容:

[preflight] Some fatal errors occurred:
[ERROR CRI]: container runtime is not running: output: time="2023-07-21T09:20:07Z" level=fatal msg="validate service connection: CRI v1 runtime API is not implemented for endpoint \"unix:///var/run/containerd/containerd.sock\": rpc error: code = Unimplemented desc = unknown service runtime.v1.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

  

 

系统环境:

ubuntu 20.04

contained.io 1.6.1

 

 

解决方案:

vi /etc/containerd/config.toml
注释掉其中的:disabled_plugins = ["cri"]
 再重新执行初始化命令
 
 
方案来自官方原文:
说明:
如果你从软件包(例如,RPM 或者 .deb)中安装 containerd,你可能会发现其中默认禁止了 CRI 集成插件。

你需要启用 CRI 支持才能在 Kubernetes 集群中使用 containerd。 要确保 cri 没有出现在 /etc/containerd/config.toml 文件中 disabled_plugins 列表内。如果你更改了这个文件,也请记得要重启 containerd。

如果你在初次安装集群后或安装 CNI 后遇到容器崩溃循环,则随软件包提供的 containerd 配置可能包含不兼容的配置参数。考虑按照 getting-started.md 中指定的 containerd config default > /etc/containerd/config.toml 重置 containerd 配置,然后相应地设置上述配置参数。

 

 
 
 
 
 
 
posted on 2023-07-21 17:58  Boom__Clap  阅读(5116)  评论(0编辑  收藏  举报