Thursday, February 23, 2017

How to check CPU /memory of particular process ?

We can check from top command also can get it using below command


#ps -p <pid> -o %cpu


[root@linuxtechnotes ~]# ps -p 19930   -o %mem
%MEM
 0.0
[root@linuxtechnotes ~]#
[root@linuxtechnotes ~]# ps -p 19930   -o %cpu
%CPU
97.0
[root@linuxtechnotes ~]#
[root@linuxtechnotes ~]#

2 comments: