Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docker Desktop 4.36.0 stops working during computer sleep #7493

Open
doberkofler opened this issue Nov 27, 2024 · 4 comments
Open

Docker Desktop 4.36.0 stops working during computer sleep #7493

doberkofler opened this issue Nov 27, 2024 · 4 comments

Comments

@doberkofler
Copy link

Description

It seems as if with the upgrade to 4.36.0 the Docker Desktop engine would stop working when the computer is in sleep mode.
After waking the computer up, the engine is stopped and cannot be restarted.
Only completely quitting Docker Desktop and restarting it solves the problem.

Reproduce

Put computer in sleep mode

Expected behavior

No response

docker version

Client:
 Version:           27.3.1
 API version:       1.47
 Go version:        go1.22.7
 Git commit:        ce12230
 Built:             Fri Sep 20 11:38:18 2024
 OS/Arch:           darwin/amd64
 Context:           desktop-linux

Server: Docker Desktop 4.36.0 (175267)
 Engine:
  Version:          27.3.1
  API version:      1.47 (minimum version 1.24)
  Go version:       go1.22.7
  Git commit:       41ca978
  Built:            Fri Sep 20 11:41:11 2024
  OS/Arch:          linux/amd64
  Experimental:     false
 containerd:
  Version:          1.7.21
  GitCommit:        472731909fa34bd7bc9c087e4c27943f9835f111
 runc:
  Version:          1.1.13
  GitCommit:        v1.1.13-0-g58aa920
 docker-init:
  Version:          0.19.0
  GitCommit:        de40ad0

docker info

Client:
 Version:    27.3.1
 Context:    desktop-linux
 Debug Mode: false
 Plugins:
  ai: Ask Gordon - Docker Agent (Docker Inc.)
    Version:  v0.1.0
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-ai
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.18.0-desktop.2
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.30.3-desktop.1
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-compose
  debug: Get a shell into any image or container (Docker Inc.)
    Version:  0.0.37
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-debug
  desktop: Docker Desktop commands (Alpha) (Docker Inc.)
    Version:  v0.0.15
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-desktop
  dev: Docker Dev Environments (Docker Inc.)
    Version:  v0.1.2
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-dev
  extension: Manages Docker extensions (Docker Inc.)
    Version:  v0.2.27
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-extension
  feedback: Provide feedback, right in your terminal! (Docker Inc.)
    Version:  v1.0.5
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-feedback
  init: Creates Docker-related starter files for your project (Docker Inc.)
    Version:  v1.4.0
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-init
  sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc.)
    Version:  0.6.0
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-sbom
  scout: Docker Scout (Docker Inc.)
    Version:  v1.15.0
    Path:     /Users/doberkofler/.docker/cli-plugins/docker-scout

Server:
 Containers: 2
  Running: 2
  Paused: 0
  Stopped: 0
 Images: 10
 Server Version: 27.3.1
 Storage Driver: overlayfs
  driver-type: io.containerd.snapshotter.v1
 Logging Driver: json-file
 Cgroup Driver: cgroupfs
 Cgroup Version: 2
 Plugins:
  Volume: local
  Network: bridge host ipvlan macvlan null overlay
  Log: awslogs fluentd gcplogs gelf journald json-file local splunk syslog
 Swarm: inactive
 Runtimes: runc io.containerd.runc.v2
 Default Runtime: runc
 Init Binary: docker-init
 containerd version: 472731909fa34bd7bc9c087e4c27943f9835f111
 runc version: v1.1.13-0-g58aa920
 init version: de40ad0
 Security Options:
  seccomp
   Profile: unconfined
  cgroupns
 Kernel Version: 6.10.14-linuxkit
 Operating System: Docker Desktop
 OSType: linux
 Architecture: x86_64
 CPUs: 8
 Total Memory: 7.656GiB
 Name: docker-desktop
 ID: 633b29f2-f595-46b6-8b00-a87efbb87291
 Docker Root Dir: /var/lib/docker
 Debug Mode: false
 HTTP Proxy: http.docker.internal:3128
 HTTPS Proxy: http.docker.internal:3128
 No Proxy: hubproxy.docker.internal
 Labels:
  com.docker.desktop.address=unix:///Users/doberkofler/Library/Containers/com.docker.docker/Data/docker-cli.sock
 Experimental: false
 Insecure Registries:
  hubproxy.docker.internal:5555
  127.0.0.0/8
 Live Restore Enabled: false

WARNING: daemon is not using the default seccomp profile

Diagnostics ID

79912DA4-8398-4A43-89C0-F3CB52D03706/20241127070311

Additional Info

No response

@stevenanthonyrevo
Copy link

I've experienced similar running Docker Desktop on MacOS ARM.

Recently, Docker Desktop appears to be getting hung up or dropping networking after long periods of time running.

I've tried to get Docker Desktop out of a "zombie like state" when it gets stuck by manually restarting the daemon.

I don't believe this issue is linux specific and I don't believe any computer settings will change the behavior. My ARM computer should not be dropping networking when its set up to run without sleep mode.

@patrickgtri
Copy link

patrickgtri commented Dec 13, 2024

Similar problem. Docker desktop does not survive sleep/closing of laptop shell. Will not shut down either after this occurs; must be force-quit and restarted.

Docker Desktop Version 4.36.0 (175267)
Engine: 27.3.1
Compose: v2.30.3-desktop.1
Credential Helper: v0.8.2
Kubernetes: v1.30.5

Generated on: Fri Dec 13 10:49:45 EST 2024
--- System Information ---
Hardware:

    Hardware Overview:

      Model Name: MacBook Pro
      Model Identifier: Mac14,10
      Model Number: MNW93LL/A
      Chip: Apple M2 Pro
      Total Number of Cores: 12 (8 performance and 4 efficiency)
      Memory: 16 GB
      System Firmware Version: 11881.1.1
      OS Loader Version: 10151.140.19.700.2
      Serial Number: [REDACTED]
      Hardware UUID: 27238D67-8BE1-54FE-AAA1-387AC5060A3E
      Provisioning UDID: 00006020-000E70CE0AE8C01E
      Activation Lock Status: Enabled


--- Docker Info ---
Client:
 Version:    27.3.1
 Context:    desktop-linux
 Debug Mode: false
 Plugins:
  ai: Ask Gordon - Docker Agent (Docker Inc.)
    Version:  v0.1.0
    Path:     [USER_HOME]/.docker/cli-plugins/docker-ai
  buildx: Docker Buildx (Docker Inc.)
    Version:  v0.18.0-desktop.2
    Path:     [USER_HOME]/.docker/cli-plugins/docker-buildx
  compose: Docker Compose (Docker Inc.)
    Version:  v2.30.3-desktop.1
    Path:     [USER_HOME]/.docker/cli-plugins/docker-compose
  debug: Get a shell into any image or container (Docker Inc.)
    Version:  0.0.37
    Path:     [USER_HOME]/.docker/cli-plugins/docker-debug
  desktop: Docker Desktop commands (Alpha) (Docker Inc.)
    Version:  v0.0.15
    Path:     [USER_HOME]/.docker/cli-plugins/docker-desktop
  dev: Docker Dev Environments (Docker Inc.)
    Version:  v0.1.2
    Path:     [USER_HOME]/.docker/cli-plugins/docker-dev
  extension: Manages Docker extensions (Docker Inc.)
    Version:  v0.2.27
    Path:     [USER_HOME]/.docker/cli-plugins/docker-extension
  feedback: Provide feedback, right in your terminal! (Docker Inc.)
    Version:  v1.0.5
    Path:     [USER_HOME]/.docker/cli-plugins/docker-feedback
  init: Creates Docker-related starter files for your project (Docker Inc.)
    Version:  v1.4.0
    Path:     [USER_HOME]/.docker/cli-plugins/docker-init
  sbom: View the packaged-based Software Bill Of Materials (SBOM) for an image (Anchore Inc.)
    Version:  0.6.0
    Path:     [USER_HOME]/.docker/cli-plugins/docker-sbom
  scout: Docker Scout (Docker Inc.)
    Version:  v1.15.0
    Path:     [USER_HOME]/.docker/cli-plugins/docker-scout

Server:

--- Docker Engine Version ---

Cannot connect to the Docker daemon at unix://[USER_HOME]/.docker/run/docker.sock. Is the docker daemon running?

--- Docker Desktop & Compose Version ---
Docker version 27.3.1, build ce12230
Docker Compose version v2.30.3-desktop.1

--- Running Containers ---
Cannot connect to the Docker daemon at unix://[USER_HOME]/.docker/run/docker.sock. Is the docker daemon running?

And I found this in the logs:

2024-12-13 09:49:19.842581 (gui/502 [100018]) <Notice>: removing inactive unmanaged service: com.apple.xpc.launchd.unmanaged.com.docker.back.11884
2024-12-13 09:49:19.857929 (gui/502 [100018]) <Notice>: service inactive: com.apple.xpc.launchd.unmanaged.com.docker.virt.11913
2024-12-13 09:49:19.857938 (gui/502 [100018]) <Notice>: removing inactive unmanaged service: com.apple.xpc.launchd.unmanaged.com.docker.virt.11913
2024-12-13 09:49:19.859192 (pid/11913 [com.docker.virt]) <Notice>: shutting down
2024-12-13 09:49:19.859200 (pid/11913 [com.docker.virt]) <Notice>: removing active service: com.apple.Virtualization.VirtualMachine.AAAF1133-E936-4FB9-A72D-A667317997AA
2024-12-13 09:49:19.869103 (pid/11913 [com.docker.virt]) <Notice>: service inactive: com.apple.Virtualization.VirtualMachine.AAAF1133-E936-4FB9-A72D-A667317997AA
2024-12-13 09:49:19.869139 (pid/11913 [com.docker.virt]) <Notice>: cleaning up
2024-12-13 09:49:19.919155 (gui/502/application.com.docker.docker.61372659.61372684 [11883]) <Notice>: exited due to exit(0), ran for 13464619ms
2024-12-13 09:49:19.919161 (gui/502/application.com.docker.docker.61372659.61372684 [11883]) <Notice>: service state: exited
2024-12-13 09:49:19.919165 (gui/502/application.com.docker.docker.61372659.61372684 [11883]) <Notice>: internal event: EXITED, code = 0
2024-12-13 09:49:19.919166 (gui/502/application.com.docker.docker.61372659.61372684 [11883]) <Notice>: job state = exited
2024-12-13 09:49:19.919187 (gui/502 [100018]) <Notice>: service inactive: application.com.docker.docker.61372659.61372684
2024-12-13 09:49:19.919190 (gui/502/application.com.docker.docker.61372659.61372684 [11883]) <Notice>: service state: not running
2024-12-13 09:49:19.920704 (gui/502/application.com.docker.docker.61372659.61372684) <Notice>: removing job: caller = runningboardd
2024-12-13 09:49:19.920713 (gui/502 [100018]) <Notice>: removing service: application.com.docker.docker.61372659.61372684
2024-12-13 09:49:19.920718 (gui/502/application.com.docker.docker.61372659.61372684) <Notice>: internal event: PETRIFIED, code = 0
2024-12-13 09:49:19.920720 (gui/502/application.com.docker.docker.61372659.61372684) <Notice>: job state = removed
2024-12-13 09:49:20.048104 (pid/11883 [com.docker.back]) <Notice>: shutting down
2024-12-13 09:49:20.048120 (pid/11883 [com.docker.back]) <Notice>: cleaning up

The time stamp in the log is associated with reopening the laptop, not closing it or shutting down the app via user/admin input. It falsely seems to say there was a clean shutdown, yet Docker Desktop is open but in this arrested state. It could be entering this state over prolonged periods but it is definitely doing this after closing and reopening the laptop clamshell.

@enzoxic

This comment has been minimized.

@djs55
Copy link
Contributor

djs55 commented Dec 19, 2024

@doberkofler thanks for the report. I tried to reproduce with the latest patch release

by starting DD, letting my machine fall asleep, waiting, waking the machine and checking it was ok. Unfortunately it doesn't reproduce for me.

Could you try again with 4.37.1 and, if it still reproduces, could you grab diagnostics while it's still in the hung state? There might be a deadlock somewhere but restarting deletes the evidence. If the diagnostics themselves hang (hopefully not, but just in case) could you grab the output of

curl --unix-socket ~/Library/Containers/com.docker.docker/Data/backend.sock http://localhost/goroutines/stacks -o stacks.txt

and attach to the issue? Thanks in advance!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants