Htop is an interactive and real-time system-monitor process-viewer written for Linux. It is designed to replace the Unix program top.
htop is Interactive process viewer for RHEL (Red Hat Enterprise) 8 Linux . It is just like default top command with an additional set of options and better display on the screen. This page shows installing htop on RHEL 8 using yum command.
install htop on RHEL 8 using yum
The procedure for installing htop on Red Hat Enterprise Linux 8 is as follows:
- Open the terminal window.
- For remote RHEL 8 server login using ssh command.
- Enable EPEL repo for RHEL 8 server or desktop
- Execute yum search htop command to search for htop on RHEL 8
- Run sudo yum install htop to install htop in RHEL 8
all steps and command in details.
Enable EPEL repo for RHEL 8
sudo yum install https://dl.fedoraproject.org/pub/epel/epel-release-latest-8.noarch.rpm sudo yum update
RHEL 8 install htop
Let us search for htop package using yum command:
yum search htop
Get information about htop package
Run the following command:
yum info htop
Finally, run the following to install htop on RHEL 8:
sudo yum install htop
How to use htop command
The syntax is:
htop htop [options] htop [options] arg
One can use a monochrome color scheme, run:
htop -C htop --no-color
Want to see the tree view by default when running htop? Try:
htop -t htop --tree
Let us see only processes of a given user named vivek:
htop -u vivek htop --user=vivek htop --user=nginx
Limit and show process for only the given PIDs:
htop -p PID htop -p PID1,PID2 --pid=PID,[,PID,PID...] htop -p 1342 htop -p 7435,136
htop keyboard shortcut keys
The following commands are supported while in htop:
|Up arrow key
|Select (highlight) the previous process in the process list. Scroll the list if necessary.
|Down arrow key
|Select (highlight) the next process in the process list. Scroll the list if necessary.
|Left arrow key
|Scroll the process list left.
|Right arrow key
|Scroll the process list right.
|Scroll the process list up or down one window.
|Scroll to the top of the process list and select the first process.
|Scroll to the bottom of the process list and select the last process.
|Trace process system calls: if strace(1) is installed, pressing this key will attach it to the currently selected process, presenting a live update of system calls issued by the process.
|Display open files for a process: if lsof(1) is installed, pressing this key will display the list of file descriptors opened by the process.
|Show only processes owned by a specified user.
|Sort by memory usage (top compatibility key).
|Sort by processor usage (top compatibility key).
|Sort by time (top compatibility key).
|“Follow” process: if the sort order causes the currently selected process to move in the list, make the selection bar follow it. This is useful for monitoring a process: this way, you can keep a process always visible on screen. When a movement key is used, “follow” loses effect.
|Hide kernel threads: prevent the threads belonging the kernel to be displayed in the process list. (This is a toggle key.)
|Hide user threads: on systems that represent them differently than ordinary processes (such as recent NPTL-based systems), this can hide threads from userspace processes in the process list. (This is a toggle key.)
|Show full paths to running programs, where applicable. (This is a toggle key.)
|Rfresh the screen.
|See this help menu.
|Same as above.
|Again, same as above.
|Exit htop (same as above)
How to get help about htop
Simply pass the –help option. For example:
htop --help man htop