How to find process ID for a given program

Sometimes using ps with default settings is not enough to find the process ID for a program, because it may not have the correct program name you want. Take for example, catalina (tomcat) running under the process ID name of ‘java’ – how do you know which ‘java’ process is catalina?

Use the following:

/usr/ucb/ps -auxww | grep <search string>

Ex.

/usr/ucb/ps -auxww | grep catalina

Advertisements

Leave a Reply

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

WordPress.com Logo

You are commenting using your WordPress.com 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 )

Google+ photo

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

Connecting to %s