Sat down to knock out some blog posts recently and when I ran docker-compose up to get my blog up and running locally I was faced with a pretty aggressive error:

% docker-compose up
Starting joshtroniccom_blog_1 ...
Starting joshtroniccom_blog_1 ... error

ERROR: for joshtroniccom_blog_1  Cannot start service blog: oci runtime error: container_linux.go:295: starting container process caused "process_linux.go:399: container init caused \"process_linux.go:382: running prestart hook 0 caused \\\"fork/exec /usr/bin/dockerd (deleted): no such file or directory\\\"\""


ERROR: for blog  Cannot start service blog: oci runtime error: container_linux.go:295: starting container process caused "process_linux.go:399: container init caused \"process_linux.go:382: running prestart hook 0 caused \\\"fork/exec /usr/bin/dockerd (deleted): no such file or directory\\\"\""

ERROR: Encountered errors while bringing up the project.

What the actual fuck?!

I assumed it had something to do with the fact that I had accidentally killed the power to my desktop machine while trying to figure out with switch on the circuit breaker went to one of the kitchen lights that needed some love.

Also thought maybe it related to the other issues I have had recently with my blog’s containers where the Gemfile.lock gets all stupid and has to be blown away.

To confirm if it was specific to my blog, I tried to bring up the containers from another project of mine. Same deal though, so it was probably Docker related.

Having issues like this in the past, the first thing I tried was running docker-compose up again as root (with sudo).

Same deal again. So I decided to check the status of Docker’s service:

% sudo systemctl status docker
**Warning: docker.service changed on disk. Run 'systemctl daemon-reload' to reload units.**
● docker.service - Docker Application Container Engine
   Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
   Active: active (running) since Sat 2017-10-21 16:54:46 CDT; 3h 25min ago
     Docs: https://docs.docker.com
 Main PID: 349 (dockerd)
    Tasks: 26 (limit: 4915)
   CGroup: /system.slice/docker.service
           ├─349 /usr/bin/dockerd -H fd://
           └─364 docker-containerd -l unix:///var/run/docker/libcontainerd/docker-containerd.sock --metrics-interval=0 --start-

Well hot damn!

I assumed that warning was the cause of the problem as I have run into it in the past and running that command fixed things.

Thought is that I had ran an update recently but since I hadn’t needed to bounce any containers it wasn’t a problem. The moment I killed the power and restarted the box, the issue cropped up.

Upon running systemctl daemon-reload and then bouncing the Docker service with systemctl restart docker, the Docker service stopped complaining and everything was right with the world again:

% sudo systemctl status docker
● docker.service - Docker Application Container Engine
   Loaded: loaded (/usr/lib/systemd/system/docker.service; enabled; vendor preset: disabled)
   Active: active (running) since Sat 2017-10-21 16:54:46 CDT; 3h 25min ago
     Docs: https://docs.docker.com
 Main PID: 349 (dockerd)
    Tasks: 26 (limit: 4915)
   CGroup: /system.slice/docker.service
           ├─349 /usr/bin/dockerd -H fd://
           └─364 docker-containerd -l unix:///var/run/docker/libcontainerd/docker-containerd.sock --metrics-interval=0 --start-

Hope this saves you some time troubleshooting!