How To Install runc on CentOS 8

runc is CLI for running Open Containers

Introduction

In this tutorial we learn how to install runc on CentOS 8.

What is runc

The runc command can be used to start containers which are packaged in accordance with the Open Container Initiative’s specifications, and to manage containers running under runc.

We can use yum or dnf to install runc on CentOS 8. In this tutorial we discuss both methods but you only need to choose one of method to install runc.

Install runc on CentOS 8 Using dnf

Update yum database with dnf using the following command.

sudo dnf makecache --refresh

The output should look something like this:

CentOS Linux 8 - AppStream                                       43 kB/s | 4.3 kB     00:00    
CentOS Linux 8 - BaseOS                                          65 kB/s | 3.9 kB     00:00    
CentOS Linux 8 - ContinuousRelease                               43 kB/s | 3.0 kB     00:00    
CentOS Linux 8 - Extras                                          23 kB/s | 1.5 kB     00:00    
CentOS Linux 8 - FastTrack                                       40 kB/s | 3.0 kB     00:00    
CentOS Linux 8 - HighAvailability                                36 kB/s | 3.9 kB     00:00    
CentOS Linux 8 - Plus                                            24 kB/s | 1.5 kB     00:00    
CentOS Linux 8 - PowerTools                                      50 kB/s | 4.3 kB     00:00    
Extra Packages for Enterprise Linux Modular 8 - x86_64           13 kB/s | 9.2 kB     00:00    
Extra Packages for Enterprise Linux 8 - x86_64                   24 kB/s | 8.5 kB     00:00    
Metadata cache created.

After updating yum database, We can install runc using dnf by running the following command:

sudo dnf -y install runc

Install runc on CentOS 8 Using yum

Update yum database with yum using the following command.

sudo yum makecache --refresh

The output should look something like this:

CentOS Linux 8 - AppStream                                       43 kB/s | 4.3 kB     00:00    
CentOS Linux 8 - BaseOS                                          65 kB/s | 3.9 kB     00:00    
CentOS Linux 8 - ContinuousRelease                               43 kB/s | 3.0 kB     00:00    
CentOS Linux 8 - Extras                                          23 kB/s | 1.5 kB     00:00    
CentOS Linux 8 - FastTrack                                       40 kB/s | 3.0 kB     00:00    
CentOS Linux 8 - HighAvailability                                36 kB/s | 3.9 kB     00:00    
CentOS Linux 8 - Plus                                            24 kB/s | 1.5 kB     00:00    
CentOS Linux 8 - PowerTools                                      50 kB/s | 4.3 kB     00:00    
Extra Packages for Enterprise Linux Modular 8 - x86_64           13 kB/s | 9.2 kB     00:00    
Extra Packages for Enterprise Linux 8 - x86_64                   24 kB/s | 8.5 kB     00:00    
Metadata cache created.

After updating yum database, We can install runc using yum by running the following command:

sudo yum -y install runc

How To Uninstall runc on CentOS 8

To uninstall only the runc package we can use the following command:

sudo dnf remove runc

runc Package Contents on CentOS 8

/usr/bin/runc
/usr/lib/.build-id
/usr/lib/.build-id/3d
/usr/lib/.build-id/3d/f6f40fda0a4c4bdbb102cf503afbde488282c1
/usr/share/bash-completion/completions/runc
/usr/share/doc/runc
/usr/share/doc/runc/CONTRIBUTING.md
/usr/share/doc/runc/MAINTAINERS_GUIDE.md
/usr/share/doc/runc/PRINCIPLES.md
/usr/share/doc/runc/README.md
/usr/share/licenses/runc
/usr/share/licenses/runc/LICENSE
/usr/share/man/man8/runc-checkpoint.8.gz
/usr/share/man/man8/runc-create.8.gz
/usr/share/man/man8/runc-delete.8.gz
/usr/share/man/man8/runc-events.8.gz
/usr/share/man/man8/runc-exec.8.gz
/usr/share/man/man8/runc-kill.8.gz
/usr/share/man/man8/runc-list.8.gz
/usr/share/man/man8/runc-pause.8.gz
/usr/share/man/man8/runc-ps.8.gz
/usr/share/man/man8/runc-restore.8.gz
/usr/share/man/man8/runc-resume.8.gz
/usr/share/man/man8/runc-run.8.gz
/usr/share/man/man8/runc-spec.8.gz
/usr/share/man/man8/runc-start.8.gz
/usr/share/man/man8/runc-state.8.gz
/usr/share/man/man8/runc-update.8.gz
/usr/share/man/man8/runc.8.gz
/usr/bin/runc
/usr/lib/.build-id
/usr/lib/.build-id/ed
/usr/lib/.build-id/ed/c28dbe0398be89f7a927b29321cc1c9191c137
/usr/share/bash-completion/completions/runc
/usr/share/doc/runc
/usr/share/doc/runc/CONTRIBUTING.md
/usr/share/doc/runc/MAINTAINERS_GUIDE.md
/usr/share/doc/runc/PRINCIPLES.md
/usr/share/doc/runc/README.md
/usr/share/licenses/runc
/usr/share/licenses/runc/LICENSE
/usr/share/man/man8/runc-checkpoint.8.gz
/usr/share/man/man8/runc-create.8.gz
/usr/share/man/man8/runc-delete.8.gz
/usr/share/man/man8/runc-events.8.gz
/usr/share/man/man8/runc-exec.8.gz
/usr/share/man/man8/runc-kill.8.gz
/usr/share/man/man8/runc-list.8.gz
/usr/share/man/man8/runc-pause.8.gz
/usr/share/man/man8/runc-ps.8.gz
/usr/share/man/man8/runc-restore.8.gz
/usr/share/man/man8/runc-resume.8.gz
/usr/share/man/man8/runc-run.8.gz
/usr/share/man/man8/runc-spec.8.gz
/usr/share/man/man8/runc-start.8.gz
/usr/share/man/man8/runc-state.8.gz
/usr/share/man/man8/runc-update.8.gz
/usr/share/man/man8/runc.8.gz

References

Summary

In this tutorial we learn how to install runc on CentOS 8 using yum and dnf.