[Docker FAQs] Failed to start Docker daemon after CentOS 7 upgrade to 3.10.0+

Failed to start Docker daemon

Docker daemon failed to start after run yum update -y command on CentOS 7.

OverlayFS is a modern union filesystem that is similar to AUFS, but faster and with a simpler implementation. Docker provides two storage drivers for OverlayFS: the original overlay, and the newer and more stable overlay2.

This topic refers to the Linux kernel driver as OverlayFS and to the Docker storage driver as overlay or overlay2.


Note: If you use OverlayFS, use the overlay2 driver rather than the overlay driver, because it is more efficient in terms of inode utilization. To use the new driver, you need version 4.0 or higher of the Linux kernel, or RHEL or CentOS using version 3.10.0-514 and above.


1
2
3
4
# systemctl status docker
2月 29 17:51:08 example.cloudolife.com dockerd[24875]: time="2021-09-29T17:51:08.151436130+08:00" level=info msg="ClientConn switching balancer to \"pick_first\"" module=grpc
2月 29 17:51:08 example.cloudolife.com dockerd[24875]: failed to start daemon: error initializing graphdriver: /backups/docker/lib contains several valid graphdrivers: overlay2, overlay; Please cleanup o
2月 29 17:51:08 example.cloudolife.com systemd[1]: docker.service: main process exited, code=exited, status=1/FAILURE

Must specify storage-driver with overlay or overlay2

1
2
# vi /etc/docker/daemon.json
{ "storage-driver": "overlay" }

Restrat docker.

1
# systemctl restart docker

References

[1] Use the OverlayFS storage driver | Docker Documentation -https://docs.docker.com/storage/storagedriver/overlayfs-driver/