Docker 正在运行。 Docker 桌面显示 "Docker Desktop stopped..."

标签 docker ubuntu docker-desktop

我已经使用本指南在我的 Ubuntu 20.04 VM 上安装了 Docker 和 Docker Desktop:
https://linuxiac.com/how-to-install-docker-desktop-on-ubuntu/
一切都在运行,但我的 Docker 桌面应用程序似乎无法连接到 Docker 本身。service docker status返回:

● docker.service - Docker Application Container Engine
     Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
     Active: active (running) since Fri 2022-05-13 14:49:12 PDT; 4 days ago
TriggeredBy: ● docker.socket
       Docs: https://docs.docker.com
   Main PID: 1086 (dockerd)
      Tasks: 18
     Memory: 73.0M
     CGroup: /system.slice/docker.service
             └─1086 /usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock

Warning: some journal files were not opened due to insufficient permissions.
但是,当我尝试在 Docker Desktop 中进行配置时,这就是我所得到的。当我点击设置时,我会得到一个永久加载微调器。
docker desktop error
我试过的
  • 我已经用 sudo service docker stop / start 重新启动了 docker
  • 我使用 Ubuntu 桌面右上角的 Docker 桌面下拉菜单单击了重新启动。
  • 我已将我的用户添加到 docker团体。

  • 我可以采取哪些步骤来调试它?有什么明显的我失踪了吗?
    谢谢!

    最佳答案

    我在 debian 11 和 Docker desktop 4.8.1 上遇到了同样的问题
    (!) 如果您在 VM 中使用 linux,请验证虚拟化支持:Docker Desktop 运行需要 KVM 支持的 VM。 https://docs.docker.com/desktop/linux/install/#kvm-virtualization-support
    您需要在 VMWare 中启用 CPU 计数器
    https://github.com/canonical/multipass/issues/1085
    验证数量

    egrep -c '(svm|vmx)' /proc/cpuinfo
    
    您需要停止并禁用 Docker。
    $ sudo service docker stop
    $ sudo systemctl disable docker.service
    $ sudo systemctl disable docker.socket
    
    然后,重新启动 linux 和 Docker 桌面。
    更重要的是,如果您以 root 用户身份运行“docker ps”,则不会使用 docker desktop。您还有另一个容器列表。
    并且...如果您更改 "setting-> Resources-> advanced: Disk Image location"请注意,您不能删除默认文件 1.8G => home/YOUR_USER/.docker/desktop/vms/0/data/Docker 。生的 。
    您可以更改路径,但需要将该文件保存在该位置。
    enter image description here
    恢复出厂设置
    enter image description here
    Docker 桌面重启
    enter image description here
    重新启动计算机后的 Docker 服务状态
    enter image description here
    完整历史:
    sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
    sudo usermod -aG docker YOUR_USER
    sudo apt install gnome-terminal
    sudo apt install qemu-kvm libvirt-clients libvirt-daemon-system bridge-utils virtinst libvirt-daemon virt-manager -y
    sudo usermod -aG kvm YOUR_USER
    sudo apt autoremove
    sudo apt install ./docker-desktop-4.8.1-amd64.deb
    sudo systemctl disable docker.service
    sudo systemctl disable docker.socket
    
    测试 VirtualBox 虚拟机 - Ubuntu 20.04
    enter image description here

    关于Docker 正在运行。 Docker 桌面显示 "Docker Desktop stopped...",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/72281976/

    相关文章:

    ruby - Rake 任务不会在我的 sinatra 应用程序中运行

    macos - TTF_OpenFont() 返回 NULL

    windows - 如何在Docker Windows容器内安装网络卷

    docker - 无法在 Docker for Windows 上共享 C 盘

    kubernetes - 如何使用 Kubernetes 在 Docker for Mac 中启用网络策略

    amazon-web-services - AWS Docker 戈兰。 'eb deploy' 错误

    docker - 从 Dockerfile 创建 Docker 基础镜像?

    docker - docker-compose 网络名称的最大长度是多少?

    docker - 使用 Docker Compose 的微服务 : Same Container, 多个项目

    c# - 带有 Azure Linux VM 的 Couchbase