Docker Community Forums

Share and learn in the Docker community.

Docker forgets VM is swarm manager

I have a Linux VM that shuts down every night and starts back up in the morning before I get to work. Docker is installed. I have it set up as a one-node swarm (itself). Up until this week, when the VM started up in the morning, docker would start, and all my stacks and containers would start back up.
This week - although docker starts up, it forgets that it is a swarm manager. Every day I’ve been having to do a docker swarm init followed by sudo systemctl restart docker.
Anyone have any ideas how to resolve this?

Docker version 19.03.11-ol, build 9bb540d

I assume you are using Oracle Linux? Docker itself does not provide repositories and packages for Oracle Linux. You might want to raise an issue to the maintainer of the docker package (which most likely is Oracle in your case), as each maintainer may or may not modify the docker sources while building their own package to align it to their needs.

I personaly prefer to stick with either CentOS, Ubuntu or Debian and install the packages from Docker’s own repositories, instead of relying on the packages provided by OS vendors.