Open In App

How to Install and Use Htop on Linux?

Last Updated : 09 Apr, 2021
Improve
Improve
Like Article
Like
Save
Share
Report

For Linux systems, Htop is an interactive system control, process viewer, and process manager. It was created as a replacement for the Linux program top, and it has a lot of the same features as the top, but with a lot more flexibility in terms of how system processes can be interpreted. Unlike top, htop displays the entire list of running processes rather than just the most resource-intensive ones. Htop can view processes as a tree and provides resource-usage statistics using color.

Installation:

First, update your system sources:

$ sudo apt install htop
How to Install and Use Htop on Linux

Updating system source

Now, install htop using the below command:

$ sudo apt-get install -y htop
How to Install and Use Htop on Linux

Installing htop

Compiling from source

We’ll need ncurses, as well as development tools/build necessary, to compile htop from the source. The steps for downloading htop from the source are as follows.

Install development tools using the below command:

$ sudo apt-get install build-essential
How to Install and Use Htop on Linux

Installing development tools

Installing ncurses:

$ sudo apt-get install libncurses5-dev libncursesw5-dev
How to Install and Use Htop on Linux

Installing ncurses

Now download htop from the source using wget:

$ wget http://hisham.hm/htop/releases/2.2.0/htop-2.2.0.tar.gz
How to Install and Use Htop on Linux

Downloading htop

Extract tar:

$ tar xvfvz htop-2.2.0.tar.gz
How to Install and Use Htop on Linux

Extract tar

Change directory to htop:

$ cd htop-2.2.0/

Change directory to htop

Now run the configure:

$ ./configure
How to Install and Use Htop on Linux

Running the configure file

Now make a script:

$ make
How to Install and Use Htop on Linux

Making script

Now we can install htop:

$ make install

Installing htop

Now you can open htop by simply typing:

$ htop
How to Install and Use Htop on Linux

htop


Like Article
Suggest improvement
Share your thoughts in the comments

Similar Reads