How to filter processes by user?

You can filter processes by user using the ps command in the terminal. Here are the commands to do so:

  1. To see processes owned by a specific user (e.g., labex):

    ps -u labex
  2. To see processes owned by the root user:

    ps -u root
  3. To see all processes with detailed information:

    ps aux | grep labex

In these commands:

  • -u specifies the user whose processes you want to display.
  • aux provides a detailed view of all processes running on the system, and grep filters the output to show only those belonging to the specified user.

You can replace labex or root with any other username to filter processes for that user.

0 Comments

no data
Be the first to share your comment!