DEV Community

Radurga Rajendran
Radurga Rajendran

Posted on

Linux Basic Commands III

Process Management Commands:

ps - It Display running processes.
-aux: - It Show all processes.
top - It Monitor system processes in real-time.It displays a dynamic view of system processes and their resource usage.
kill - It helps to Terminate a process.
** - 9*: Forcefully kill a process.
**kill PID
* -terminates the process with the specified process ID.
pkill - Terminate processes based on their name.
pkill **- terminates all processes with the specified name.
**pgrep
- It helps to List processes based on their name.
grep - It used to search for specific patterns or regular expressions in text files or streams and display matching lines.
-i: Ignore case distinctions while searching.
-v: Invert the match, displaying non-matching lines.
-r or -R: Recursively search directories for matching patterns.
-l: Print only the names of files containing matches.
-n: Display line numbers alongside matching lines.
-w: Match whole words only, rather than partial matches.
-c: Count the number of matching lines instead of displaying them.
-e: Specify multiple patterns to search for.
-A: Display lines after the matching line.
-B: Display lines before the matching line.
-C: Display lines both before and after the matching line.

Top comments (0)