Solved

Ps -ef with exclude option for shell processes ID

Posted on 2006-10-30
3
618 Views
Last Modified: 2013-12-26
Hi, We are using the following command to find all the processes owned by "admin" and the processes having name with SIS, ora.

ps -f |-u Admin grep [SIS]  |grep -v " grep [ora\|SIS] " ,

This is listing all the process with ora and SIS and also the following which we want to avoid with shell processes like csh and ksh.

admin 400588 204800   0 13:57:50  pts/0  0:00 ksh
admin 543846 839918   0 16:28:59  pts/3  0:00 -csh

Could some body help us to fine tune the command to list out all the processes with SIS and ora and NOT to show the shell processes ?

Thanks
GVS
0
Comment
Question by:gvsunil
  • 2
3 Comments
 
LVL 58

Expert Comment

by:amit_g
ID: 17838477
ps -f -u Admin | grep [SIS]  | egrep -v 'grep|ksh|csh'
0
 

Author Comment

by:gvsunil
ID: 17839022
Thanks Amit,

this looks promising, but do you think the following change in your command will also show the ora and SIS processes as well ?

ps -f -u Admin | grep [ora\|SIS]  | egrep -v 'grep|ksh|csh'

Thanks
GVS
0
 
LVL 58

Accepted Solution

by:
amit_g earned 500 total points
ID: 17839028
Use egrep instead

ps -f -u Admin | egrep 'ora|SIS'  | egrep -v 'grep|ksh|csh'
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Importing Special Characters in Dynamics GP Through Integration Manager 3 69
while loop over for loop 7 93
sumHeights  challenge 17 66
Annoying "thing" blocks my view 4 83
Introduction: Dynamic window placements and drawing on a form, simple usage of windows registry as a storage place for information. Continuing from the first article about sudoku.  There we have designed the application and put a lot of user int…
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Internet Business Fax to Email Made Easy - With  eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, f…

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

24 Experts available now in Live!

Get 1:1 Help Now