我正在尝试使用以下方法在我的azure虚拟机上安装nvidia-docker:
sudo apt-get install -y nvidia-docker2
我收到此错误:
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:
nvidia-docker2 : Depends: docker-ce (>= 18.06.0~ce~3-0~ubuntu) but it is not installable or
docker-ee (>= 18.06.0~ce~3-0~ubuntu) but it is not installable or
docker.io (>= 18.06.0) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
据研究后了解,这是因为我有较旧的Docker版本。
尝试遵循以下说明: https://github.com/NVIDIA/nvidia-docker/issues/857#issuecomment-439586831 但这给了我以下错误:
E: Version '18.06.1~ce~3-0~ubuntu' for 'docker-ce' was not found
接下来,我尝试按照以下说明卸载旧版本的Docker:https://docs.docker.com/engine/install/ubuntu/ 然后我得到了结果:
Package 'docker-engine' is not installed, so not removed
sudo docker版本提供以下输出:
Client:
Version: 3.0.11+azure
API version: 1.40
Go version: go1.12.17
Git commit: eb310fca49568dccd87c6136f774ef6fff2a1b51
Built: Tue Mar 3 21:59:52 2020
OS/Arch: linux/amd64
Experimental: false
Server:
Engine:
Version: 3.0.11+azure
API version: 1.40 (minimum version 1.12)
Go version: go1.12.17
Git commit: aa6a9891b0
Built: Tue Mar 10 18:53:36 2020
OS/Arch: linux/amd64
Experimental: false
containerd:
Version: v1.2.13
GitCommit: 7ad184331fa3e55e52b890ea95e65ba581ae3429
runc:
Version: 1.0.0-rc10
GitCommit: dc9208a3303feef5b3839f4323d9beb36df0a9dd
docker-init:
Version: 0.18.0
GitCommit: fec3683
请帮助。