To view and manage processes on openSUSE, you can use several command-line tools. The most common ones are ps, top, and htop.
ps: This command displays information about a selection of the active processes. For example, to view all running processes, you can use:
ps aux
Here, a lists all users' processes, u displays the output in a user-oriented format, and x adds processes without a controlling terminal.
top: This command provides a dynamic real-time view of a running system. It displays a list of processes that are currently running, along with system statistics like CPU and memory usage. To start top, simply type:
top
You can interact with top to sort processes, kill processes, and more.
htop: This is an interactive process viewer for Unix systems, similar to top, but offers more features like color highlighting, tree views, and the ability to scroll the process list. If not already installed, you can install it using:
sudo zypper install htop
Once installed, you can start htop by typing:
htop
For managing processes, you can use the kill command to terminate a process by its PID (Process ID). For example:
kill 1234
Replace 1234 with the PID of the process you want to terminate.
If you need a more robust solution for managing and monitoring processes in a cloud environment, consider using services like Tencent Cloud's Cloud Monitor, which provides comprehensive monitoring and management capabilities for cloud resources.