【k8s】centos上安装kubernetes,报错Error:docker-ce-cli conflicts with 2:docker-1.13.1-94.gitb2f74b2.el7.centos.x86_64

时间:2021-11-15 15:44:38

使用命令:

yum install kubernetes

报错:

Error: docker-ce-cli conflicts with :docker-1.13.-.git07f3374.el7.centos.x86_64
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest

错误原因:

yum安装kubernetes之前已经安装过docker,导致出现上面报错

解决方法:

先卸载docker,再重新安装kubernetes,即可解决这个问题

yum list installed | grep docker

【k8s】centos上安装kubernetes,报错Error:docker-ce-cli conflicts with 2:docker-1.13.1-94.gitb2f74b2.el7.centos.x86_64

将三个查出来的全部卸载

yum -y remove  containerd.io.x86_64  docker-ce.x86_64  docker-ce-cli.x86_64

卸载完成,再重新执行

yum install kubernetes