Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Docker service does not start anymore after Ubuntu 18.04 update: dm_task_run failed / no such device storage-driver=overlay2

After I triggered an unattended-upgrade on Ubuntu 18.04 (currently 18.04.5) and rebooted the server my docker service does not start anymore. So I tried to run it manually with sudo dockerd but got the following errors:

failed to mount overlay: no such device storage-driver=overlay2 docker failed to start daemon: error initializing graphdriver: driver not supported

After fiddling around with various suggestions (incl. the obligatory reboot x times) I gave up and uninstalled docker (incl. deleting usr/lib/docker) to reinstall the newest version. But this only changed the error message to:

failed to start daemon: error initializing graphdriver: devicemapper: Error running deviceCreate (CreatePool) dm_task_run failed

I have more than enough disk space and already tried to delete the /usr/lib/docker folder (which btw. doesn't have an overlay2 folder which my previous installation at least had), but those suggestions didn't work. If I force --storage-driver=overlay2 I get the old "failed to mount overlay:..." from above.

I am now totally clueless how to solve this problem. Any ideas?

Edit: It seems that all the dm_* errors shouldn't be my problem, since they come from devicemapper which shouldn't be used. Instead the overlay2 stuff should work. So it all boils down to: Why does overlay2 not work (anymore?) on my machine?

Current versions:

  • Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-106-generic x86_64)
  • Docker version 19.03.12, build 48a66213fe

Full error message:

INFO[2020-09-10T12:38:41.720023381+02:00] Starting up INFO[2020-09-10T12:38:41.721017055+02:00] detected 127.0.0.53 nameserver, assuming systemd-resolved, so using resolv.conf: /run/systemd/resolve/resolv.conf INFO[2020-09-10T12:38:41.723286420+02:00] parsed scheme: "unix"
module=grpc INFO[2020-09-10T12:38:41.723397263+02:00] scheme "unix" not registered, fallback to default scheme module=grpc INFO[2020-09-10T12:38:41.723468274+02:00] ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock 0 }] } module=grpc INFO[2020-09-10T12:38:41.723493045+02:00] ClientConn switching balancer to "pick_first" module=grpc INFO[2020-09-10T12:38:41.727552254+02:00] parsed scheme: "unix"
module=grpc INFO[2020-09-10T12:38:41.727619515+02:00] scheme "unix" not registered, fallback to default scheme module=grpc INFO[2020-09-10T12:38:41.727666336+02:00] ccResolverWrapper: sending update to cc: {[{unix:///run/containerd/containerd.sock 0 }] } module=grpc INFO[2020-09-10T12:38:41.727698707+02:00] ClientConn switching balancer to "pick_first" module=grpc ERRO[2020-09-10T12:38:41.845132923+02:00] [graphdriver] prior storage driver devicemapper failed: devicemapper: Error running deviceCreate (CreatePool) dm_task_run failed failed to start daemon: error initializing graphdriver: devicemapper: Error running deviceCreate (CreatePool) dm_task_run failed

like image 619
Holger Rattenscheid Avatar asked Oct 19 '25 15:10

Holger Rattenscheid


1 Answers

I finally found the solution: It seems that the ubuntu update messed up while updating the kernel. After reinstalling the kernel everything works fine again and docker runs with overlay2.

So for me it was:

sudo apt-get install --reinstall linux-image-4.15.0-106-generic
like image 198
Holger Rattenscheid Avatar answered Oct 21 '25 06:10

Holger Rattenscheid