When I tried docker-slim first, it hit "OCI runtime created failed:"error, why?

Viewed 419

My step is according to https://github.com/docker-slim/docker-slim#build-command-options

docker images ubuntu:14.04

REPOSITORY          TAG                 IMAGE ID            CREATED             SIZE
ubuntu              14.04               6e4f1fe62ff1        3 months ago        197MB

docker-slim build --http-probe=false ubuntu:14.04

docker-slim[build]: info=probe message='changing continue-after from probe to enter because http-probe is disabled'
docker-slim[build]: state=started
docker-slim[build]: info=params target=ubuntu:14.04 continue.mode=enter rt.as.user=true keep.perms=true
docker-slim[build]: state=image.inspection.start
docker-slim[build]: info=image id=sha256:6e4f1fe62ff14a4c8119781d47a3739fa97c190e1df38e868794ad7a7cf50a48 size.bytes=196513448 size.human=196 MB
docker-slim[build]: info=image.stack index=0 name='ubuntu:14.04' id='sha256:6e4f1fe62ff14a4c8119781d47a3739fa97c190e1df38e868794ad7a7cf50a48'
docker-slim[build]: state=image.inspection.done
docker-slim[build]: state=container.inspection.start
docker-slim[build]: info=container status=created name=dockerslimk_96914_20200327012028 id=4451869a0c47c88d225ad73ece2c0f1926da481bb205e0e0f0c5f4ad05779a7a
time="2020-03-27T09:20:28+08:00" level=fatal msg="docker-slim: failure" error="API error (400): OCI runtime create failed: container_linux.go:296: starting container process caused \"exec: \\\"/opt/dockerslim/bin/docker-slim-sensor\\\": stat /opt/dockerslim/bin/docker-slim-sensor: no such file or directory\": unknown" stack="goroutine 1 [running]:\nruntime/debug.Stack(0xc000374420, 0x1000000000001c8, 0x0)\n\truntime/debug/stack.go:24 +0x9d\ngithub.com/docker-slim/docker-slim/pkg/util/errutil.FailOn(0xb9ace0, 0xc00023ec20)\n\tgithub.com/docker-slim/docker-slim/pkg/util/errutil/errutil.go:14 +0x54\ngithub.com/docker-slim/docker-slim/internal/app/master/commands.OnBuild(0xc0000f1ae0, 0x7ffd7a3fd58b, 0xc, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0, ...)\n\tgithub.com/docker-slim/docker-slim/internal/app/master/commands/build.go:264 +0x162f\ngithub.com/docker-slim/docker-slim/internal/app/master.init.0.func10(0xc0001a6b00, 0x0, 0xc0001c2f00)\n\tgithub.com/docker-slim/docker-slim/internal/app/master/cli.go:1655 +0x171a\ngithub.com/urfave/cli.HandleAction(0x9cd840, 0xad0bd8, 0xc0001a6b00, 0xc0001a6b00, 0x0)\n\tgithub.com/urfave/cli@v1.22.1/app.go:523 +0x11a\ngithub.com/urfave/cli.Command.Run(0xaa0a83, 0x5, 0x0, 0x0, 0xc0002e6de0, 0x1, 0x1, 0xac41f6, 0x3e, 0x0, ...)\n\tgithub.com/urfave/cli@v1.22.1/command.go:174 +0x56e\ngithub.com/urfave/cli.(*App).Run(0xc0000321c0, 0xc000208040, 0x4, 0x4, 0x0, 0x0)\n\tgithub.com/urfave/cli@v1.22.1/app.go:276 +0x7ae\ngithub.com/docker-slim/docker-slim/internal/app/master.runCli()\n\tgithub.com/docker-slim/docker-slim/internal/app/master/cli.go:2053 +0x55\ngithub.com/docker-slim/docker-slim/internal/app/master.Run()\n\tgithub.com/docker-slim/docker-slim/internal/app/master/app.go:6 +0x25\nmain.main()\n\tgithub.com/docker-slim/docker-slim/cmd/docker-slim/main.go:8 +0x20\n" version="linux|Transformer|1.29.0|afff2c9679a697ebfc933360267253a10325269d|2020-03-18_07:11:20PM"

Why? My environment: docker-slim version

docker-slim[version]: info=app version='linux|Transformer|1.29.0|afff2c9679a697ebfc933360267253a10325269d|2020-03-18_07:11:20PM' container=false dsimage=false
docker-slim[version]: info=app outdated=false current=1.29.0 verdict='your have the latest version'
docker-slim[version]: info=app location='/home/users/lizhenguo/dist_linux'
docker-slim[version]: info=host osname='unknown'
docker-slim[version]: info=host osbuild=
docker-slim[version]: info=host version='#181 SMP Thu Feb 8 16:34:08 CST 2018'
docker-slim[version]: info=host release=3.10.0_3-0-0-17
docker-slim[version]: info=host sysname=Linux
docker-slim[version]: info=docker name=szth-sys-gpu-kongming08.szth.baidu.com
docker-slim[version]: info=docker kernel_version=3.10.0_3-0-0-17
docker-slim[version]: info=docker operating_system=<unknown>
docker-slim[version]: info=docker ostype=linux
docker-slim[version]: info=docker server_version=17.12.0-ce
docker-slim[version]: info=docker architecture=x86_64
docker-slim[version]: info=dclient api_version=1.35
docker-slim[version]: info=dclient min_api_version=1.12
docker-slim[version]: info=dclient build_time=2017-12-27T20:12:29.000000000+00:00
docker-slim[version]: info=dclient git_commit=c97c6d6

docker version

Client:
 Version:   17.12.0-ce
 API version:   1.35
 Go version:    go1.9.2
 Git commit:    c97c6d6
 Built: Wed Dec 27 20:05:38 2017
 OS/Arch:   linux/amd64

Server:
 Engine:
  Version:  17.12.0-ce
  API version:  1.35 (minimum version 1.12)
  Go version:   go1.9.2
  Git commit:   c97c6d6
  Built:    Wed Dec 27 20:12:29 2017
  OS/Arch:  linux/amd64
  Experimental: false
1 Answers

You will need to install the command docker-slim-sensor as well.

It is in the same folder as docker-slim after your unpack the downloaded tar file during the installation step. You also need to make sure that it has the execution right.

Related