2

Context

In my .devcontainer that, I run in GitHub Codespaces, I've installed minikube. Shortly after minikube start I get this message

Executing "docker container inspect minikube took an unusually long time: 10.566089734s*

Restarting the docker service may improve performance.
  1. I'm using docker docker-in-docker feature.
  2. The .devcontainer environment starts docker with dockerd cli.
  3. systemctl is not present container running my environment

Question

I'd like to restart docker to improve performance. Is it possible to restart docker without stopping the docked process? Something like sudo systemctl restart docker but with dockerd?

Lukasz Dynowski
  • 11,169
  • 9
  • 81
  • 124
  • What are you trying to achieve? "Restart Docker" on bare metal would normally imply stopping and recreating the `dockerd` process. For things running in containers, you don't usually restart processes but rather delete and recreate the container; can you delete the DinD container? – David Maze Mar 01 '23 at 14:34

2 Answers2

0

After careful studding of dockerd cli, I concluded that there is no other option of restarting the docekrd process than just killing it and starting it manually again.

Lukasz Dynowski
  • 11,169
  • 9
  • 81
  • 124
-2

To restart dockerd, restart the docker service itself. For example, sudo systemctl restart docker in ubuntu.

Mitch
  • 1,556
  • 1
  • 17
  • 17