gpt4 book ai didi

docker - 无法生成错误 “shim error: docker-runc not installed on system”的Docker镜像

转载 作者:行者123 更新时间:2023-12-02 19:37:18 24 4
gpt4 key购买 nike

我正在尝试从Dockerfile构建Docker镜像,但看到错误shim error: docker-runc not installed on system
这是我的Dockerfile:

FROM ubuntu

RUN apt-get update \
&& apt-get install -y build-essential \
&& apt-get install -y libssl-dev libbz2-dev

$ docker build -t ub .
Sending build context to Docker daemon 2.048 kB
Step 1 : FROM ubuntu
---> 6a2f32de169d
Step 2 : RUN apt-get update && apt-get install -y build-essential && apt-get install -y libssl-dev libbz2-dev
---> Running in b7574a066f82
shim error: docker-runc not installed on system

Docker版本详细信息:
$ docker version
Client:
Version: 1.12.6
API version: 1.24
Package version: docker-common-1.12.6-16.sl7.x86_64
Go version: go1.7.4
Git commit: 3a094bd/1.12.6
Built: Fri Apr 14 09:57:15 2017
OS/Arch: linux/amd64

Server:
Version: 1.12.6
API version: 1.24
Package version: docker-common-1.12.6-16.sl7.x86_64
Go version: go1.7.4
Git commit: 3a094bd/1.12.6
Built: Fri Apr 14 09:57:15 2017
OS/Arch: linux/amd64

docker 信息:
$ docker info
Containers: 11
Running: 0
Paused: 0
Stopped: 11
Images: 5
Server Version: 1.12.6
Storage Driver: devicemapper
Pool Name: docker-8:2-526997-pool
Pool Blocksize: 65.54 kB
Base Device Size: 10.74 GB
Backing Filesystem: xfs
Data file: /dev/loop0
Metadata file: /dev/loop1
Data Space Used: 856.8 MB
Data Space Total: 107.4 GB
Data Space Available: 7.817 GB
Metadata Space Used: 1.479 MB
Metadata Space Total: 2.147 GB
Metadata Space Available: 2.146 GB
Thin Pool Minimum Free Space: 10.74 GB
Udev Sync Supported: true
Deferred Removal Enabled: false
Deferred Deletion Enabled: false
Deferred Deleted Device Count: 0
Data loop file: /var/lib/docker/devicemapper/devicemapper/data
WARNING: Usage of loopback devices is strongly discouraged for production use. Use `--storage-opt dm.thinpooldev` to specify a custom block storage device.
Metadata loop file: /var/lib/docker/devicemapper/devicemapper/metadata
Library Version: 1.02.135-RHEL7 (2016-11-16)
Logging Driver: json-file
Cgroup Driver: cgroupfs
Plugins:
Volume: local
Network: bridge null host overlay
Swarm: inactive
Runtimes: runc
Default Runtime: runc
Security Options: seccomp
Kernel Version: 3.10.0-229.20.1.el7.x86_64
Operating System: Scientific Linux 7.3 (Nitrogen)
OSType: linux
Architecture: x86_64
Number of Docker Hooks: 2
CPUs: 2
Total Memory: 7.641 GiB
Name: caspgval4
ID: RM5S:3ZWP:VPDC:AFOP:V3PA:XW4B:DMRS:VCB2:Q22K:3GBX:UYZO:EBAK
Docker Root Dir: /var/lib/docker
Debug Mode (client): false
Debug Mode (server): false
Registry: https://index.docker.io/v1/
WARNING: bridge-nf-call-iptables is disabled
WARNING: bridge-nf-call-ip6tables is disabled
Insecure Registries:
127.0.0.0/8
Registries: docker.io (secure)

最佳答案

您安装的docker似乎缺少了一些必需的零件。您的安装可能存在错误,或者Scientific Linux安装可能存在安装问题。您可以尝试直接从docker升级到发行版,而不是通过以root身份运行以下命令来使用Scientific Linux的版本:

curl -sSL https://get.docker.com/ | sh

关于docker - 无法生成错误 “shim error: docker-runc not installed on system”的Docker镜像,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/43576154/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com