Description
I'm running docker rootless (as a systemd service).
When stopping the service:
- ... if containers are NOT running, docker exits fine.
- ... if containers are running, docker stops the containers immediately, but does not exit fine, but is killed by systemd after the 90s timeout (service had 90s to exit cleanly before being
SIGKILL'd.
This initial became evident since, when shutting down the system, systemd waits 90s for docker to stop, and then kills it, so it's been slowing down people's shutdown.
I'm the maintainer for the docker-rootless ArchLinux AUR package, and several other users report the same issue.
Steps to reproduce the issue:
- Run docker rootless
- Run a container (e.g.:
docker run --rm -it node:12 bash)
- Stop the service (e.g.:
systemctl --user stop docker.service)
Describe the results you received:
The container is killed immediately, but the docker service does not stop until the 90s timeout (systemd sends a SIGKILL after that time). Changing the systemd's timeout makes docker take that long to exit.
This does not happen is no containers are running.
Describe the results you expected:
The docker service should exit immediately.
Additional information you deem important (e.g. issue happens only occasionally):
Output of docker version:
$ docker version
Client:
Version: 20.10.1
API version: 1.41
Go version: go1.15.6
Git commit: 2291f610ae
Built: Tue Jan 19 17:19:21 2021
OS/Arch: linux/amd64
Context: default
Experimental: true
Output of docker info:
$ docker info
Client:
Context: default
Debug Mode: false
Plugins:
app: Docker App (Docker Inc., v0.9.1-beta3)
buildx: Build with BuildKit (Docker Inc., v0.5.1-tp-docker)
Additional environment details (AWS, VirtualBox, physical, etc.):
I'm having this issue on a physical ArchLinux machine, and other Arch users report the same issue.
Description
I'm running docker rootless (as a systemd service).
When stopping the service:
SIGKILL'd.This initial became evident since, when shutting down the system, systemd waits 90s for docker to stop, and then kills it, so it's been slowing down people's shutdown.
I'm the maintainer for the docker-rootless ArchLinux AUR package, and several other users report the same issue.
Steps to reproduce the issue:
docker run --rm -it node:12 bash)systemctl --user stop docker.service)Describe the results you received:
The container is killed immediately, but the docker service does not stop until the 90s timeout (systemd sends a SIGKILL after that time). Changing the systemd's timeout makes docker take that long to exit.
This does not happen is no containers are running.
Describe the results you expected:
The docker service should exit immediately.
Additional information you deem important (e.g. issue happens only occasionally):
Output of
docker version:Output of
docker info:Additional environment details (AWS, VirtualBox, physical, etc.):
I'm having this issue on a physical ArchLinux machine, and other Arch users report the same issue.