How to view running processes in Linux
There are several methods in Linux to view running processes.
- To check the current running processes list, use the “ps” command by typing it into the terminal.
ps aux
- Using the top command: The top command can monitor the system’s process status in real-time, including CPU and memory usage.
top
- Use the htop command: htop is an improved version of top, which provides a more user-friendly interface and functionality.
htop
- The pgrep command can be used to find the process ID corresponding to a process name.
pgrep <进程名>
- By using the pidof command, you can find the corresponding process ID by the process name.
pidof <进程名>
This method can help you quickly view the processes running in the current system.