All guides
Home Glossary Container runtime
Term

Container runtime

Software responsible for executing containers, managing their lifecycle, and enforcing resource isolation on a host system.

A Container Runtime is the core software component responsible for executing containers, managing their lifecycle, and enforcing resource isolation on a host system. It pulls container images from a registry, unpacks their filesystems, and runs the application processes inside isolated environments. Acting as the execution engine, it bridges the gap between a container orchestrator and the host operating system kernel.

How it works

The container runtime ecosystem is divided into two distinct functional layers that separate user-facing management from low-level kernel operations:

  • Low-level runtimes: Tools such as runc and crun handle the direct creation and execution of container processes. They interact with the Linux kernel to set up isolation primitives, including namespaces (to isolate process IDs, networks, and mounts) and cgroups (to limit CPU, memory, and disk I/O).
  • High-level runtimes: Daemons such as containerd and CRI-O manage the broader container lifecycle. They handle pulling and unpacking images, managing local image storage, configuring container networking, and delegating the actual process execution down to a low-level runtime.

In Kubernetes environments, the kubelet communicates with high-level runtimes through the Container Runtime Interface (CRI). This standardized API allows cluster operators to swap runtimes—for example, switching to a sandboxed runtime like gVisor or Kata Containers for stronger workload isolation—without modifying core cluster components. Since the removal of Dockershim in Kubernetes 1.24, clusters communicate directly with CRI-compatible runtimes, reducing architectural overhead and unnecessary abstraction layers.

Example

When managing a Kubernetes node or troubleshooting container execution directly without the Docker daemon, administrators use crictl, a command-line interface designed specifically for CRI-compatible runtimes like containerd.

# List all running containers managed by the CRI runtime
sudo crictl ps

# Pull an image and inspect runtime status
sudo crictl pull nginx:alpine
sudo crictl info

In the background, containerd fetches the nginx:alpine layers, mounts them into an overlay filesystem, generates an Open Container Initiative (OCI) runtime specification file (config.json), and invokes runc to spawn the isolated process.

What matters when choosing a server or hosting

Selecting infrastructure for containerized workloads requires verifying how the host environment supports the runtime layer:

  • Kernel version and modules: Modern runtimes rely on specific Linux kernel features such as overlay2 storage drivers, cgroups v2, and seccomp profiles. Outdated distribution kernels can cause runtime failures or degraded I/O performance.
  • Dedicated kernel vs. shared environment: Virtual Private Servers (VPS) and dedicated bare-metal servers provide full kernel access, allowing you to install custom runtimes or microVM engines like Kata Containers. Restricted container-based hosting (such as legacy OpenVZ instances) often blocks nested namespaces and cgroup manipulation.
  • Storage IOPS and disk throughput: High-level runtimes extract and layer image archives continuously during deployments and autoscaling events. Fast NVMe storage prevents disk bottlenecks during image pulls and container startups.
  • Rootless support: If security policies prohibit running background daemons as root, ensure the host OS supports user namespaces and rootless execution modes natively.

Common mistakes

  • Confusing Docker with the runtime itself: Docker is a complete developer platform that includes a CLI, image builder, and API; under the hood, it relies on containerd and runc to actually run containers.
  • Using the Docker CLI to debug Kubernetes pods: On modern Kubernetes nodes using containerd or CRI-O directly, running docker ps will either fail or show no containers. Operators must use crictl or ctr instead.
  • Ignoring cgroups driver mismatches: Configuring Kubernetes and the container runtime to use different cgroup drivers (for instance, mixing cgroupfs and systemd) leads to resource accounting errors and node instability under memory pressure.

FAQ

What is the difference between containerd and runc?

containerd is a high-level runtime that manages image transfers, storage, and container lifecycles, whereas runc is a low-level OCI runtime that containerd invokes to actually create the namespaces and start the container process on the host kernel.

Do I still need Docker installed on a Kubernetes worker node?

No. Kubernetes interacts directly with CRI-compatible runtimes such as containerd or CRI-O. Installing the full Docker Engine on worker nodes adds unnecessary background services and resource overhead.

Can a single host use multiple low-level runtimes?

Yes. High-level runtimes like containerd support multiple runtime handlers via Kubernetes RuntimeClasses, allowing standard workloads to run on runc while untrusted workloads run inside isolated sandboxes like gVisor on the same machine.

All glossary terms

Glossary

Related terms

Full glossary

New guides every week.

A digest of the best pieces on servers, VPN and self-hosted software. No ads, no spam.

1 email a weekOne-click unsubscribeRU · EN
Only slipjar.app articles, nothing else.