cri-o: CRI-o fails to start after installation

After installing cri-o-1.11 on ubuntu - it fails to start, because runc is not linked to the right location /usr/bin/runc

OS: ubuntu/xenial64

$ add-apt-repository -y ppa:projectatomic/ppa
$ apt-get update
$ apt-get install -y cri-o-1.11
$ systemctl status crio.service
● crio.service - Open Container Initiative Daemon
   Loaded: loaded (/lib/systemd/system/crio.service; disabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sun 2018-09-02 22:30:15 UTC; 2min 8s ago
     Docs: https://github.com/kubernetes-incubator/cri-o
  Process: 5686 ExecStart=/usr/bin/crio $CRIO_STORAGE_OPTIONS $CRIO_NETWORK_OPTIONS (code=exited, status=1/FAILURE)
 Main PID: 5686 (code=exited, status=1/FAILURE)

Sep 02 22:30:15 master1 systemd[1]: Starting Open Container Initiative Daemon...
Sep 02 22:30:15 master1 crio[5686]: time="2018-09-02 22:30:15.891302068Z" level=fatal msg="invalid --runtime value "stat /usr/bin/runc: no such file or directory""
Sep 02 22:30:15 master1 systemd[1]: crio.service: Main process exited, code=exited, status=1/FAILURE
Sep 02 22:30:15 master1 systemd[1]: Failed to start Open Container Initiative Daemon.
Sep 02 22:30:15 master1 systemd[1]: crio.service: Unit entered failed state.
Sep 02 22:30:15 master1 systemd[1]: crio.service: Failed with result 'exit-code'.
$ which runc
$ find / -name runc
/usr/lib/cri-o-runc/sbin/runc
ln -s /usr/lib/cri-o-runc/sbin/runc /usr/bin/runc
$ systemctl start crio
$ systemctl status crio.service
● crio.service - Open Container Initiative Daemon
   Loaded: loaded (/lib/systemd/system/crio.service; disabled; vendor preset: enabled)
   Active: active (running) since Sun 2018-09-02 22:32:28 UTC; 1s ago
     Docs: https://github.com/kubernetes-incubator/cri-o
 Main PID: 5872 (crio)
    Tasks: 10
   Memory: 6.2M
      CPU: 79ms
   CGroup: /system.slice/crio.service
           └─5872 /usr/bin/crio

Sep 02 22:32:28 master1 systemd[1]: Starting Open Container Initiative Daemon...
Sep 02 22:32:28 master1 systemd[1]: Started Open Container Initiative Daemon.

About this issue

  • Original URL
  • State: closed
  • Created 6 years ago
  • Reactions: 5
  • Comments: 31 (21 by maintainers)

Most upvoted comments

To link the binary, use ln:

ln -s /usr/sbin/runc /usr/bin/runc

The -s make the link, a symbolic link. From the binary /usr/sbin/runc And create a link at /usr/bin/runc

It looks that runc is installed in find / -name runc on Ubuntu 19.10:

/usr/bin/runc

version: 1.0.1-dev

crio version 1.16.6 (arch: armv7l)

@b23prodtm thanks for the reply. Yes, recently we have updated the repos. Everything should be working out-of-the-box.

@outcoldman Please consider re-testing and closing this report.

Thanks!

by default, we read runc from $PATH now, so I’d recommend setting runtime_path to empty, and installing it there.

Yes, I would also say let’s install runc in /usr/sbin.

the problem with that is it will then conflict with debian/ubuntu’s own runc which people have complained about in the past. So, if the distro’s runc is good enough (I’ve also heard of issues where it was too old), I can just get rid of the cri-o-runc package.

by the way, we’ve deprecated the projectatomic ppa, and now are moving our packaging efforts to openSUSE’s OBS Kubic repo: https://build.opensuse.org/project/show/devel:kubic:libcontainers:stable you may have more luck with that

I’m running into the same issue with Ubuntu 18.04 and cri-o 1.17. I was able to fix the issue with @outcoldman’s suggestion: ln -s /usr/lib/cri-o-runc/sbin/runc /usr/bin/runc.

● crio.service - Container Runtime Interface for OCI (CRI-O)
   Loaded: loaded (/usr/lib/systemd/system/crio.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sun 2020-02-23 15:46:17 UTC; 4h 26min ago
     Docs: https://github.com/cri-o/cri-o
  Process: 6237 ExecStart=/usr/bin/crio $CRIO_CONFIG_OPTIONS $CRIO_RUNTIME_OPTIONS $CRIO_STORAGE_OPTIONS $CRIO_NETWORK_OPTIONS $CRIO_METRICS_OPTIONS (code=exited, status=1/FAILURE)
 Main PID: 6237 (code=exited, status=1/FAILURE)

Feb 23 15:46:16 ubuntu systemd[1]: Starting Container Runtime Interface for OCI (CRI-O)...
Feb 23 15:46:17 ubuntu crio[6237]: time="2020-02-23 15:46:17.134726652Z" level=fatal msg="runtime config: runtime validation: \"runc\" not found in $PATH: exec: \"runc\": executable file not found in $PATH"
Feb 23 15:46:17 ubuntu systemd[1]: crio.service: Main process exited, code=exited, status=1/FAILURE
Feb 23 15:46:17 ubuntu systemd[1]: crio.service: Failed with result 'exit-code'.
Feb 23 15:46:17 ubuntu systemd[1]: Failed to start Container Runtime Interface for OCI (CRI-O).
marshall@ubuntu:~$ sudo apt-cache show cri-o-1.17
Package: cri-o-1.17
Version: 1.17.0-3
Architecture: amd64
Maintainer: Lokesh Mandvekar <lsm5@fedoraproject.org>
Installed-Size: 87308
Depends: libgpgme11, libseccomp2, conmon, containers-common (>= 0.1.27), cri-o-runc (>= 1.0.0)
Suggests: containernetworking-plugins
Replaces: cri-o-1.10, cri-o-1.11, cri-o-1.11-stable, cri-o-1.12, cri-o-1.13, cri-o-1.14, cri-o-1.15, cri-o-1.16
Filename: ./amd64/cri-o-1.17_1.17.0-3_amd64.deb
Size: 18611120
MD5sum: e7fd801f59f0bd199835e573cfbdf814
SHA1: 5b5e529106c9bc81bd9a6150e0dd851372032bdd
SHA256: 127a26329d2e739f11f23785a83da5a86d067b72e2603d66098b2dd96191f4e6
Section: devel
Priority: optional
Homepage: https://github.com/cri-o/cri-o
Description: OCI-based implementation of Kubernetes Container Runtime Interface.
Description-md5: a8cb00ac87b19d2db81aefe9cf4f39e3