rootlessctl command not found

In this troubleshooting guide we learn how to fix rootlessctl command not found error message

Introduction

When you run more command in linux terminal / console, you get the following error message

rootlessctl: command not found

or when using sudo you get the following error message

sudo: rootlessctl: command not found

Solutions to rootlessctl: command not found

How To Fix rootlessctl: command not found in Ubuntu / Debian / Kali Linux / Raspbian

In Ubuntu rootlessctl is provided by rootlesskit package.

rootlesskit is:

The purpose of RootlessKit is to run Docker and Kubernetes as an unprivileged user (known as “Rootless mode”), so as to protect the real root on the host from potential container-breakout attacks.

RootlessKit creates user_namespaces(7) and mount_namespaces(7), and executes newuidmap(1)/newgidmap(1) along with subuid(5) and subgid(5).

RootlessKit also supports isolating network_namespaces(7) with userspace NAT using “slirp”.

This Debian package doesn’t support vpnkit mode.

On Debian system, kernel.unprivileged_userns_clone should be enabled.

To fix this problem, we can install more using the command below.

sudo apt-get -y install rootlesskit

This command might take some time to finish depending on your machine internet connection.

You can also use apt command to install rootlesskit.

sudo apt -y install rootlesskit

Or if you have aptitude installed you can use the following command.

sudo aptitude install rootlesskit

Summary

In this tutorial we learn how to fix rootlessctl command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.