Skip to content

Commit 8983a0d

Browse files
authored
more on ps command
1 parent da44999 commit 8983a0d

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

README.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -671,6 +671,9 @@ Regular expressions.
671671
- `ps -p 1`: to get info about a process based on a given PID.
672672
- `ps -u zaki`: to get info about a process based on a given UID.
673673

674+
- `pstree`: to print the tree of the processes.
675+
- `pidof firfox`: to print the id of the process firfox.
676+
674677
### top command:
675678
- `top` command will display the complete active process, cpu and memory information, `shift+p` will order the output based on cpu usage, `shift+m` will order based on memory usage, `c` to print the absolute path of the process, `k` to kill a process.
676679
- `top -u zaki`: print only processes owned by a given user.
@@ -679,6 +682,7 @@ Regular expressions.
679682
- `kill 1245` kill the process with the pid 1234, you should be able to kill a process only if youa are the owner of that process.
680683
- `kill -9 5678`: forcing to kill the process with sigkill signal.
681684
- `killall vim`: killing all the vim process.
685+
- `kill -l`: print all the signals that we can use to kill a process.
682686

683687
## Network linux commands
684688
- `hostname`: to print the name of the host, with `-d` option it prints the domain name which the machine belongs to, with `-f` option, it prints the fully qualified domaine name, with -`i`, it prints the ip address of the machine.

0 commit comments

Comments
 (0)