checkrestart command not found
Introduction
When you run more command in linux terminal / console, you get the following error message
checkrestart: command not found
or when using sudo you get the following error message
sudo: checkrestart: command not found
Solutions to checkrestart: command not found
How To Fix checkrestart: command not found in Ubuntu / Debian / Kali Linux / Raspbian
In Ubuntu checkrestart is provided by debian-goodies package.
debian-goodies is:
These programs are designed to integrate with standard shell tools, extending them to operate on the Debian packaging system.
dglob - Generate a list of package names which match a pattern [dctrl-tools, apt*, apt-file*, perl*] dgrep - Search all files in specified packages for a regex [dctrl-tools, apt-file (both via dglob)]
These are also included, because they are useful and don’t justify their own packages:
check-enhancements - find packages which enhance installed packages [apt, dctrl-tools] checkrestart - Help to find and restart processes which are using old versions of upgraded files (such as libraries) [python3, procps, lsof*] debget - Fetch a .deb for a package in APT’s database [apt] debman - Easily view man pages from a binary .deb without extracting [man, apt* (via debget)] debmany - Select manpages of installed or uninstalled packages [man | sensible-utils, whiptail | dialog | zenity, apt*, konqueror*, xdg-utils*] dhomepage - Open homepage of a package in a web browser [dctrl-tools, sensible-utils*, www-browser* | x-www-browser*] dman - Fetch manpages from online manpages.debian.org service [curl, man, lsb-release*] dpigs - Show which installed packages occupy the most space [dctrl-tools] find-dbgsym-packages - Get list of dbgsym packages from core dump or PID. [dctrl-tools, elfutils, libfile-which-perl, libipc-system-simple-perl, libfile-slurper-perl] Usage of the –ssh option requires openssh-client. Usage of the –deb option requires equivs. popbugs - Display a customized release-critical bug list based on packages you use (using popularity-contest data) [python3, popularity-contest] which-pkg-broke - find which package might have broken another [python3, apt] which-pkg-broke-build - find which package might have broken the build of another [python3 (via which-pkg-broke), apt]
Package name in brackets denote (non-essential) dependencies of the scripts. Packages names with an asterisk ("*") denote optional dependencies, all other are hard dependencies.
Hard dependencies of single tools are listed in the Recommends field of the package and optional dependencies of single tools in the Suggests field – as common with many “collection” style Debian packages.
To fix this problem, we can install more using the command below.
sudo apt-get -y install debian-goodies
This command might take some time to finish depending on your machine internet connection.
You can also use apt command to install debian-goodies.
sudo apt -y install debian-goodies
Or if you have aptitude installed you can use the following command.
sudo aptitude install debian-goodies
Summary
In this tutorial we learn how to fix checkrestart command not found error in Ubuntu / Debian / Kali Linux or Raspbian distribution.