我的问题是

我的问题是

我正在尝试在 RaspberryPi 上的 Ubuntu Server 18.04 上安装 docker。我按照 Docker 网站上的说明进行操作。我卡在了第sudo apt-get install docker-ce:amd64 docker-ce-cli:amd64 containerd.io:amd64

Reading package lists... Done
Building dependency tree       
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 containerd.io:amd64 : Depends: libc6:amd64 (>= 2.14) but it is not installable
                       Depends: libseccomp2:amd64 (>= 2.4.0) but it is not installable
 docker-ce:amd64 : Depends: libseccomp2:amd64 (>= 2.3.0) but it is not installable
                   Depends: libc6:amd64 (>= 2.8) but it is not installable
                   Depends: libdevmapper1.02.1:amd64 (>= 2:1.02.97) but it is not installable
                   Depends: libsystemd0:amd64 but it is not installable
                   Recommends: aufs-tools:amd64 but it is not going to be installed
                   Recommends: cgroupfs-mount:amd64 or
                               cgroup-lite:amd64 but it is not installable
                   Recommends: pigz:amd64 but it is not going to be installed
                   Recommends: libltdl7:amd64 but it is not installable
                   Recommends: apparmor:amd64 but it is not installable
 docker-ce-cli:amd64 : Depends: libc6:amd64 (>= 2.4) but it is not installable
E: Unable to correct problems, you have held broken packages.

我尝试添加一些来自类似问题的新存储库。但没有任何成功。

我的当前source.list

deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic main restricted
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-updates main restricted
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic universe
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-updates universe
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic multiverse
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-updates multiverse
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-backports main restricted universe multiverse
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-security main restricted
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-security universe
deb [arch=amd64] http://ports.ubuntu.com/ubuntu-ports bionic-security multiverse
deb [arch=amd64] https://download.docker.com/linux/ubuntu bionic stable

# custom
deb http://archive.ubuntu.com/ubuntu bionic universe multiverse
deb-src http://archive.ubuntu.com/ubuntu bionic universe multiverse

deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic universe
deb-src [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic universe
deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic-updates universe
deb-src [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic-updates universe

deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic multiverse
deb-src [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic multiverse
deb [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic-updates multiverse
deb-src [arch=amd64] http://us.archive.ubuntu.com/ubuntu/ bionic-updates multiverse

deb [arch=amd64] http://security.ubuntu.com/ubuntu bionic-security universe
deb-src [arch=amd64] http://security.ubuntu.com/ubuntu bionic-security universe
deb [arch=amd64] http://security.ubuntu.com/ubuntu bionic-security multiverse
deb-src [arch=amd64] http://security.ubuntu.com/ubuntu bionic-security multiverse

我的问题是

我应该添加哪个存储库或我做错了什么?确切地说,我使用的是 Raspberry Pi 3 Model B+,18.04.3 LTS (GNU/Linux 4.15.0-1041-raspi2 aarch64)

答案1

OMG:就在我写下的时候aarch64。我试图为错误的架构安装docker。AMD64而不是arm64/aarch64。在Docker的指令中amd64是预先选择的。我一开始没有注意到它。

总结一下:

在第 4 步中,选择正确的架构非常重要。对我来说,这是arm64……

相关内容