Skip to content

pidof COMMAND:

July 24, 2010

pidof COMMAND:
pidof linux command is used to find the process ID of a running program.

The Syntax is
pidof [options..] program


-s Single shot – this instructs the program to only return one pid.
-x Scripts too – this causes the program to also return process id’s of shells running the named scripts.
-o Tells pidof to omit processes with that process id. The special pid %PPID can be used to name the parent process of the pidof program, in other words the calling shell or shell script.


  1. To find a process id of a particular console:
    pidof -s console

    This command prints the process id of the console.



From → Unix

Leave a Comment

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: