Wednesday, March 2, 2016

Useful Unix or Linux command on single post

Get process id of all the running program on Unix or Linux system.
ps ax | grep java

22491 pts/0    S+     0:00 grep --color=auto java
27209 ?        S      0:00 sudo nohup java
27210 ?        Sl     2:58 java

Kill process using process id (PDID) in unix or linux:
sudo kill -9 27210

Below command will fetch count of files in a particular director in Unix or Linux system?

ls -l | grep -v ^l | wc -l

No comments:

Post a Comment