This installation is not successful on Linux Mint 21
File: engine/install/ubuntu.md
When following these instructions exactly I have encountered several issues.
Uninstall old versions of docker if present
$ sudo apt-get remove docker docker-engine docker.io containerd runc
[sudo] password for brant:
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
E: Unable to locate package docker-engine
Update apt
$ sudo apt-get update
Hit:1 http://security.ubuntu.com/ubuntu jammy-security InRelease
Ign:2 http://packages.linuxmint.com vanessa InRelease
Hit:4 https://dl.google.com/linux/chrome/deb stable InRelease
Hit:5 http://packages.linuxmint.com vanessa Release
Hit:6 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ InRelease
Get:8 https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease [3,626 B]
Ign:9 https://download.docker.com/linux/ubuntu vanessa InRelease
Hit:3 http://mirror.us.leaseweb.net/ubuntu jammy InRelease
Hit:7 http://mirror.us.leaseweb.net/ubuntu jammy-updates InRelease
Hit:10 http://mirror.us.leaseweb.net/ubuntu jammy-backports InRelease
Err:11 https://download.docker.com/linux/ubuntu vanessa Release
404 Not Found [IP: 13.32.151.52 443]
Hit:12 http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu jammy InRelease
Err:8 https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 51716619E084DAB9
Hit:14 http://ppa.launchpad.net/jonathonf/vim/ubuntu jammy InRelease
Reading package lists... Done
E: The repository 'https://download.docker.com/linux/ubuntu vanessa Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: https://cloud.r-project.org/bin/linux/ubuntu/focal-cran40/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
W: GPG error: https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 51716619E084DAB9
E: The repository 'https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
W: http://ppa.launchpad.net/jonathonf/vim/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
Note Err: 11 which is related to Docker.
$ sudo apt-get install \
ca-certificates \
curl \
gnupg \
lsb-release
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
ca-certificates is already the newest version (20211016).
lsb-release is already the newest version (11.1.0ubuntu4).
curl is already the newest version (7.81.0-1ubuntu1.4).
gnupg is already the newest version (2.2.27-3ubuntu2.1).
The following packages were automatically installed and are no longer required:
docker-ce-rootless-extras docker-scan-plugin libslirp0 slirp4netns
Use 'sudo apt autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 16 not upgraded.
Get Docker's official GPG key
$ sudo mkdir -p /etc/apt/keyrings
$ curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo gpg --dearmor -o /etc/apt/keyrings/docker.gpg
File '/etc/apt/keyrings/docker.gpg' exists. Overwrite? (y/N) y
Note that it is overwriting an existing docker.gpg file.
Set up the repository
$ echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/ubuntu \
$(lsb_release -cs) stable" | sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
Install docker engine
sudo apt-get update
Hit:1 https://cloud.r-project.org/bin/linux/ubuntu focal-cran40/ InRelease
Ign:2 http://packages.linuxmint.com vanessa InRelease
Get:3 https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease [3,626 B]
Hit:5 https://dl.google.com/linux/chrome/deb stable InRelease
Ign:6 https://download.docker.com/linux/ubuntu vanessa InRelease
Hit:7 http://packages.linuxmint.com vanessa Release
Hit:4 http://mirror.us.leaseweb.net/ubuntu jammy InRelease
Hit:8 http://mirror.us.leaseweb.net/ubuntu jammy-updates InRelease
Hit:9 http://mirror.us.leaseweb.net/ubuntu jammy-backports InRelease
Err:10 https://download.docker.com/linux/ubuntu vanessa Release
404 Not Found [IP: 13.32.151.28 443]
Err:3 https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease
The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 51716619E084DAB9
Hit:11 http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu jammy InRelease
Hit:12 http://security.ubuntu.com/ubuntu jammy-security InRelease
Hit:14 http://ppa.launchpad.net/jonathonf/vim/ubuntu jammy InRelease
Reading package lists... Done
W: https://cloud.r-project.org/bin/linux/ubuntu/focal-cran40/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
E: The repository 'https://download.docker.com/linux/ubuntu vanessa Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: GPG error: https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 51716619E084DAB9
E: The repository 'https://cloud.r-project.org/bin/linux/ubuntu jammy-cran40/ InRelease' is not signed.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.
W: http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
W: http://ppa.launchpad.net/jonathonf/vim/ubuntu/dists/jammy/InRelease: Key is stored in legacy trusted.gpg keyring (/etc/apt/trusted.gpg), see the DEPRECATION section in apt-key(8) for details.
Same error Err: 10 persists.
$ sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Package docker-ce is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
Package docker-ce-cli is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
E: Package 'docker-ce' has no installation candidate
E: Package 'docker-ce-cli' has no installation candidate
E: Unable to locate package containerd.io
E: Couldn't find any package by glob 'containerd.io'
E: Couldn't find any package by regex 'containerd.io'
E: Unable to locate package docker-compose-plugin
Unable to install Docker Engine.
I am not very familiar with Linux and would appreciate any help solving this installation issue.
BI
I was able to solve part of my problem by changing the way the keys were saved. After deleting prior docker installations are recommended in the manual, I did the following:
Step 1: delete the old docker key
sudo rm /etc/apt/sources.list.d/docker.list
Step 2: get the new docker key
wget -O- https://download.docker.com/linux/ubuntu/gpg | gpg --dearmor | sudo tee /usr/share/keyrings/docker-archive-keyring.gpg
Step 3: create a new docker.list file and point to the new key location
sudo gedit /etc/apt/sources.list.d/docker.list
# Add the following in the file
deb [arch=amd64 signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/ubuntu jammy stable
Step 4: use apt to get docker
sudo apt-get update
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
This appears to have mostly worked. However, I do get an error message during the installation that I do not understand:
$ sudo apt-get install docker-ce docker-ce-cli containerd.io docker-compose-plugin
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Suggested packages:
aufs-tools cgroupfs-mount | cgroup-lite
The following packages will be REMOVED:
containerd docker.io runc
The following NEW packages will be installed:
containerd.io docker-ce docker-ce-cli docker-compose-plugin
0 upgraded, 4 newly installed, 3 to remove and 24 not upgraded.
Need to get 0 B/96.7 MB of archives.
After this operation, 109 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 371498 files and directories currently installed.)
Removing docker.io (20.10.12-0ubuntu4) ...
Warning: Stopping docker.service, but it can still be activated by:
docker.socket
Removing containerd (1.5.9-0ubuntu3) ...
Removing runc (1.1.0-0ubuntu1) ...
Selecting previously unselected package containerd.io.
(Reading database ... 371236 files and directories currently installed.)
Preparing to unpack .../containerd.io_1.6.8-1_amd64.deb ...
Unpacking containerd.io (1.6.8-1) ...
Selecting previously unselected package docker-ce-cli.
Preparing to unpack .../docker-ce-cli_5%3a20.10.18~3-0~ubuntu-jammy_amd64.deb ...
Unpacking docker-ce-cli (5:20.10.18~3-0~ubuntu-jammy) ...
Selecting previously unselected package docker-ce.
Preparing to unpack .../docker-ce_5%3a20.10.18~3-0~ubuntu-jammy_amd64.deb ...
Unpacking docker-ce (5:20.10.18~3-0~ubuntu-jammy) ...
Selecting previously unselected package docker-compose-plugin.
Preparing to unpack .../docker-compose-plugin_2.10.2~ubuntu-jammy_amd64.deb ...
Unpacking docker-compose-plugin (2.10.2~ubuntu-jammy) ...
Setting up containerd.io (1.6.8-1) ...
Setting up docker-compose-plugin (2.10.2~ubuntu-jammy) ...
Setting up docker-ce-cli (5:20.10.18~3-0~ubuntu-jammy) ...
Setting up docker-ce (5:20.10.18~3-0~ubuntu-jammy) ...
Job for docker.service failed because the control process exited with error code.
See "systemctl status docker.service" and "journalctl -xeu docker.service" for details.
invoke-rc.d: initscript docker, action "start" failed.
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Active: activating (auto-restart) (Result: exit-code) since Tue 2022-10-04 10:16:00 EDT; 3ms ago
TriggeredBy: ● docker.socket
Docs: https://docs.docker.com
Process: 22521 ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock (code=exited, status=1/FAILURE)
Main PID: 22521 (code=exited, status=1/FAILURE)
CPU: 61ms
dpkg: error processing package docker-ce (--configure):
installed docker-ce package post-installation script subprocess returned error exit status 1
Processing triggers for man-db (2.10.2-1) ...
Errors were encountered while processing:
docker-ce
E: Sub-process /usr/bin/dpkg returned an error code (1)
$ systemctl status docker.service
● docker.service - Docker Application Container Engine
Loaded: loaded (/lib/systemd/system/docker.service; enabled; vendor preset: enabled)
Active: active (running) since Tue 2022-10-04 10:19:18 EDT; 22min ago
TriggeredBy: ● docker.socket
Docs: https://docs.docker.com
Main PID: 23597 (dockerd)
Tasks: 37
Memory: 27.8M
CPU: 797ms
CGroup: /system.slice/docker.service
└─23597 /usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.583767701-04:00" level=info msg="ClientConn switching balance>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.584316419-04:00" level=error msg="No zfs dataset found for ro>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.628820100-04:00" level=info msg="Loading containers: start."
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.731107322-04:00" level=info msg="Default bridge (docker0) is >
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.785300510-04:00" level=info msg="Loading containers: done."
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.791180885-04:00" level=info msg="Docker daemon" commit=e42327>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.791235377-04:00" level=info msg="Daemon has completed initial>
Oct 04 10:19:18 NCaseM1 systemd[1]: Started Docker Application Container Engine.
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.805811226-04:00" level=info msg="API listen on /run/docker.so>
Oct 04 10:19:31 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:31.454198219-04:00" level=info msg="ignoring event" container=ee>
lines 1-22/22 (END)
$ journalctl -xeu docker.service
░░
░░ The job identifier is 4389.
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.581937639-04:00" level=info msg="Starting up"
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.582317271-04:00" level=info msg="detected 127.0.0.53 nameserv>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.582776462-04:00" level=info msg="parsed scheme: \"unix\"" mod>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.582791129-04:00" level=info msg="scheme \"unix\" not register>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.582805877-04:00" level=info msg="ccResolverWrapper: sending u>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.582812439-04:00" level=info msg="ClientConn switching balance>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.583741461-04:00" level=info msg="parsed scheme: \"unix\"" mod>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.583751069-04:00" level=info msg="scheme \"unix\" not register>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.583762150-04:00" level=info msg="ccResolverWrapper: sending u>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.583767701-04:00" level=info msg="ClientConn switching balance>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.584316419-04:00" level=error msg="No zfs dataset found for ro>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.628820100-04:00" level=info msg="Loading containers: start."
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.731107322-04:00" level=info msg="Default bridge (docker0) is >
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.785300510-04:00" level=info msg="Loading containers: done."
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.791180885-04:00" level=info msg="Docker daemon" commit=e42327>
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.791235377-04:00" level=info msg="Daemon has completed initial>
Oct 04 10:19:18 NCaseM1 systemd[1]: Started Docker Application Container Engine.
░░ Subject: A start job for unit docker.service has finished successfully
░░ Defined-By: systemd
░░ Support: http://www.ubuntu.com/support
░░
░░ A start job for unit docker.service has finished successfully.
░░
░░ The job identifier is 4389.
Oct 04 10:19:18 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:18.805811226-04:00" level=info msg="API listen on /run/docker.so>
Oct 04 10:19:31 NCaseM1 dockerd[23597]: time="2022-10-04T10:19:31.454198219-04:00" level=info msg="ignoring event" container=ee>
Does anybody have an idea what the problem is and how to fix it? Interestingly, when I test docker using the following, it seems to function.
$ sudo service docker start
$ sudo docker run hello-world
Hello from Docker!
This message shows that your installation appears to be working correctly.
To generate this message, Docker took the following steps:
1. The Docker client contacted the Docker daemon.
2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
(amd64)
3. The Docker daemon created a new container from that image which runs the
executable that produces the output you are currently reading.
4. The Docker daemon streamed that output to the Docker client, which sent it
to your terminal.
To try something more ambitious, you can run an Ubuntu container with:
$ docker run -it ubuntu bash
Share images, automate workflows, and more with a free Docker ID:
https://hub.docker.com/
For more examples and ideas, visit:
https://docs.docker.com/get-started/
There hasn't been any activity on this issue for a long time.
If the problem is still relevant, mark the issue as fresh with a /remove-lifecycle stale comment.
If not, this issue will be closed in 14 days. This helps our maintainers focus on the active issues.
Prevent issues from auto-closing with a /lifecycle frozen comment.
/lifecycle stale
This issue still exists, the solution provided by @canuckafar helped me. Thanks. The documentation for all ubuntu based distro might need an update to follow the new way of handling keys
Closed issues are locked after 30 days of inactivity. This helps our team focus on active issues.
If you have found a problem that seems similar to this, please open a new issue.
/lifecycle locked