赞
踩
docker rm-f $(docker ps -a -q)
docker rmi $(docker images -q)
systemctl stop docker
rm -rf /etc/docker
rm -rf /run/docker
rm -rf /var/lib/dockershim
# 容器与镜像存放在此目录
rm -rf /var/lib/docker
cat /proc/mounts |grep "docker" |grep "caf8ef20f3c1
然后取消挂载后
umount /data/sys/var/docker/containers/caf8ef20f3c1c78f03a5844ee23abc1d7e44246f242292040f1ef288899d0cb8/secrets
然后再执行
rm -rf /var/lib/docker
接下来分两种情况:
for i in ("containerd" "containerd-shim" "containerd-shim-runc-v2" "ctr" "docker" "dockerd" "docker-init" "docker-proxy" "runc")
do
rm -f /usr/bin/$i
done
rm -f /etc/systemd/system/docker.service
[root@ecs-46078391 ~]# yum list installed | grep docker
containerd.io.x86_64 1.6.8-3.1.el7 @docker-ce-stable
docker-ce.x86_64 3:20.10.9-3.el7 @/docker-ce-20.10.9-3.el7.x86_64
docker-ce-cli.x86_64 1:20.10.17-3.el7 @docker-ce-stable
docker-ce-rootless-extras.x86_64 20.10.17-3.el7 @docker-ce-stable
docker-scan-plugin.x86_64 0.17.0-3.el7 @docker-ce-stable
yum remove containerd.io.x86_64 docker-ce.x86_64 docker-ce-cli.x86_64 docker-ce-rootless-extras.x86_64 docker-scan-plugin.x86_64
yum list installed | grep docker
docker version
Copyright © 2003-2013 www.wpsshop.cn 版权所有,并保留所有权利。