tl;dr使用dockerd
,我如何选择v2
运行时?
docker run
警告建议 v2 运行时
docker
运行失败docker run hello-world
。在文件中找到唯一的警告consider using runtime v2
/var/log/deamon.log
containerd[367]: level=warning msg="runtime v1 is deprecated since containerd v1.4, consider using runtime v2" time="2020-12-30T15:49:25.426984959-08:00"
这是所有系统日志和--debug
输出中唯一的警告或错误,所以这是我最好的下一步。
dockerd --help
的选项runtime
是
‣ dockerd --help | grep runtime
--add-runtime runtime Register an additional OCI compatible runtime (default [])
--cpu-rt-runtime int Limit the CPU real-time runtime in microseconds
--default-runtime string Default OCI runtime for containers (default "runc")
正在使用的版本
在 Raspberry Pi 2 上运行 Raspbian 9 (Debian 9)。
使用docker-ce
安装(使用安装get-docker.sh
)
‣ dpkg --status docker-ce
Package: docker-ce
Status: install ok installed
Priority: optional
Section: admin
Installed-Size: 68106
Architecture: armhf
Version: 5:19.03.14~3-0~raspbian-stretch
Replaces: docker-engine
Depends: docker-ce-cli, containerd.io (>= 1.2.2-3), iptables, libseccomp2 (>= 2.3.0), libc6 (>= 2.4), libdevmapper1.02.1 (>= 2:1.02.97), libsystemd0
Recommends: ca-certificates, cgroupfs-mount | cgroup-lite, git, pigz, xz-utils, libltdl7
Conflicts: docker (<< 1.5~), docker-engine, docker-engine-cs, docker.io, lxc-docker, lxc-docker-virtual-package
...
dockerd
‣ dockerd --version
Docker version 19.03.14, build 5eb3275d40