How to install ContainerD

Containerd versions can be found in this location : https://github.com/containerd/containerd/releases

Step 1 : Download the containerd package

wget https://github.com/containerd/containerd/releases/download/v1.6.14/containerd-1.6.14-linux-amd64.tar.gz

Unpack :

sudo tar Cxzvf /usr/local containerd-1.6.14-linux-amd64.tar.gz

Install runc :

Runc is a standardized runtime for spawning and running containers on Linux according to the OCI specification

wget https://github.com/opencontainers/runc/releases/download/v1.1.3/runc.amd64

$ install -m 755 runc.amd64 /usr/local/sbin/runc

Download and install CNI plugins :

wget https://github.com/containernetworking/plugins/releases/download/v1.1.1/cni-plugins-linux-amd64-v1.1.1.tgz

mkdir -p /opt/cni/bin

Configure containerd

We need to create a containerd directory for the configuration file

sudo mkdir /etc/containerd

config.toml is the default configuration file fro containerd :

containerd config default | sudo tee /etc/containerd/config.toml

Enable systemd group . Use sed command to change the parameter in config.toml instead of using vi editor

sudo sed -i ‘s/SystemdCgroup \= false/SystemdCgroup \= true/g’ /etc/containerd/config.toml

Convert containerd into service :

sudo curl -L https://raw.githubusercontent.com/containerd/containerd/main/containerd.service -o /etc/systemd/system/containerd.service

sudo systemctl daemon-reload

sudo systemctl enable — now containerd

sudo systemctl status containerd

12 thoughts on “How to install ContainerD”

  1. I don’t think the title of your article matches the content lol. Just kidding, mainly because I had some doubts after reading the article.

Leave a Comment

Your email address will not be published. Required fields are marked *