Last updated on November 5, 2020 by Dan Nanni
htopas an alternative to
topcommand. When I tried to install
yumpackage manager on CentOS, I got "No package htop available" error. How can I install
htop is an
ncurses-based real-time process viewer for Linux. While its interface is inspired by venerable
htop has several user-friendly features, not available in
top. For example,
htop allows you scroll a process list horizontally or vertically to see full command lines. Also, with
htop, you can kill or re-nice one or more processes at once, without entering their PIDs. Compared to
htop launches faster because
htop does not wait to collect data upon launch.
htopon CentOS with
htop package is available from EPEL repository. So you need to enable the repository first. Then use
yum command to install it.
$ sudo yum install htop
htopfrom the Source on CentOS
Another option is to compile and install
htop from the source. This option is useful when you want to install the latest version of
Here is how to build and install
htop from the source.
First, install prerequisites and download the source.
$ sudo yum groupinstall "Development Tools" $ sudo yum install ncurses-devel $ wget http://hisham.hm/htop/releases/1.0.3/htop-1.0.3.tar.gz $ tar xvfvz htop-1.0.3.tar.gz $ cd htop-1.0.3
configure script to prepare for compilation.
htop will be installed under
/usr/local/bin. If you want to change installation location to something else (e.g.,
configure script with
--prefix option instead. For example:
$ ./configure --prefix=/usr
Finally, build and install
htop as follows.
$ make $ sudo make install
After installation, launch
htop by entering:
Please note that this article is published by Xmodulo.com under a Creative Commons Attribution-ShareAlike 3.0 Unported License. If you would like to use the whole or any part of this article, you need to cite this web page at Xmodulo.com as the original source.