Suppose 1000 processes are running on the system out of those
if you have to show only certain process ids which command
will you use?

Answers were Sorted based on User's Feedback



Suppose 1000 processes are running on the system out of those if you have to show only certain pr..

Answer / linuxdemon

ps -ef | grep pid

Is This Answer Correct ?    13 Yes 2 No

Suppose 1000 processes are running on the system out of those if you have to show only certain pr..

Answer / c sivakumar. kumarsiva46@yaho

pgrep -fl <scriptname> This command will show respective
process alone.

Example:-
ready> pgrep -fl genericShip.pl
(output following below)
11607 /usr/local/bin/perl /forms1/prodenv/genericShip.pl

Is This Answer Correct ?    0 Yes 1 No

Suppose 1000 processes are running on the system out of those if you have to show only certain pr..

Answer / suvarna

top command can also be used

Is This Answer Correct ?    0 Yes 2 No

Suppose 1000 processes are running on the system out of those if you have to show only certain pr..

Answer / bhaskar

ps -aef grep pid

Is This Answer Correct ?    1 Yes 4 No

Suppose 1000 processes are running on the system out of those if you have to show only certain pr..

Answer / aseem

It is up to you, how you want. For example suppose you want
to display a range like PID from 1500 to 2000 then

ps -ef | grep '[1500 - 2000]'

Is This Answer Correct ?    0 Yes 4 No

Post New Answer

More Unix Commands Interview Questions

Is grep faster than awk?

0 Answers  


What is the function of grep command in unix?

0 Answers  


what is difference between unix and linux?

6 Answers   IBM, Shell, Wipro,


If JFS file system is 100% full how we can increase the file system ?

3 Answers  


How are UNIX file permissions represented?

1 Answers  


how to remotely move a file ??? that mean how to move a file one machine to another machine ???

10 Answers   Altair,


How we will execute previous command in vi editor?

8 Answers   Infosys,


How to rename files and folders?

7 Answers   IBM, Oracle,


How do you find path of a directory? Give its syntax.

7 Answers  


what is the use of ls -l command & what is the information it gives about user ?

5 Answers  


What is the comma to display different lines that are found when compare two files?

0 Answers  


What is the difference between a hard link and a soft link in Unix?

1 Answers  


Categories