docker服务启动报错docker.service holdoff time over, scheduling restart.
卸载docker
卸载安装包
yum remove -y docker
docker-client
docker-client-latest
docker-ce-cli
docker-common
docker-latest
docker-latest-logrotate
docker-logrotate
docker-selinux
docker-engine-selinux
docker-engine
rm -rf /usr/lib/systemd/system/docker.service
rm -rf /etc/systemd/system/docker.service.d
-rf /var/lib/docker/
rm -rf /var/run/docker
设置 yum repository
export REGISTRY_MIRROR=https://registry.cn-hangzhou.aliyuncs.com
yum install -y yum-utils
device-mapper-persistent-data
lvm2
yum-config-manager --add-repo http://mirrors.aliyun.com/docker-ce/linux/centos/docker-ce.repo
安装并启动 docker
yum install -y docker-ce-19.03.11 docker-ce-cli-19.03.11 containerd.io-1.2.13
配置仓库
mkdir /etc/docker || true
cat > /etc/docker/daemon.json <<EOF
{
“registry-mirrors”: [“https://registry.cn-hangzhou.aliyuncs.com”],
“exec-opts”: [“native.cgroupdriver=systemd”],
“log-driver”: “json-file”,
“log-opts”: {
“max-size”: “100m”
},
“storage-driver”: “overlay2”,
“storage-opts”: [
“overlay2.override_kernel_check=true”
]
}
EOF
mkdir -p /etc/systemd/system/docker.service.d
Restart Docker
systemctl daemon-reload
systemctl enable docker
systemctl restart docker文章来源:https://www.toymoban.com/news/detail-795594.html
我这边原因是配合的仓库地址不合适,
“registry-mirrors”: [“https://registry.cn-hangzhou.aliyuncs.com”],
这个弟子不合适导致,改完重启好了文章来源地址https://www.toymoban.com/news/detail-795594.html
到了这里,关于docker服务启动报错docker.service holdoff time over, scheduling restart.的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!