htop command is a system monitoring tool for Linux that provides an interactive and real-time view of the system processes. Here is a tutorial on how to use the
- Open a terminal window: To access the Linux command line, you can use the terminal application, which is usually found in the “Utilities” or “System Tools” section of the application menu.
htopis not already installed on your system, you can install it using your system’s package manager. For example, on a Debian-based system, you can run the following command:
sudo apt-get install htop
htop: To run
htop, simply enter the following command in the terminal:
- Understanding the
htopinterface displays a list of all running processes on the system, along with information such as the process ID (PID), user, CPU usage, memory usage, and status. You can navigate the list of processes using the up and down arrow keys, and you can sort the list by a specific column by clicking on the column header.
- Search for a process: To search for a specific process, you can use the
/key to enter search mode, and then type the name of the process you want to search for.
htopwill highlight any matching processes in the list.
- Kill a process: To kill a process, you can select the process in the list and then press the
F9key. This will bring up a menu of options, including the option to kill the process.
- View process details: To view detailed information about a process, you can select the process in the list and then press the
Enterkey. This will open a new window with information such as the command line arguments, environment variables, and open files.
htop: To quit
htop, press the
These are the basics of using
htop provides many other features and options, such as the ability to filter the process list, configure the display, and manage process priority. To learn more about these features, you can consult the
htop manual page by running the following command: