dh_runit command not found

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

Introduction

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

dh_runit: command not found

or when using sudo you get the following error message

sudo: dh_runit: command not found

Solutions to dh_runit: command not found

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

In Ubuntu dh_runit is provided by dh-runit package.

dh-runit is:

dh-runit provides a debhelper sequence addon named ‘runit’ and the dh_runit command.

The dh_runit command installs runscripts and adds the appropriate code to the postinst, prerm and postrm maint scripts to properly enable/disable and purge runscripts. When runit is PID 1 the maint script code also takes care of restarting services during upgrades, when appropriate.

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

sudo apt-get -y install dh-runit

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

You can also use apt command to install dh-runit.

sudo apt -y install dh-runit

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

sudo aptitude install dh-runit

Summary

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