![]() |
|
|
|
|
|||||||
| Forums | Portal | Register | Forum Rules | FAQ | Contribute | Members List | Arcade | Search | Today's Posts | Mark Forums Read |
| UNIX for Dummies Questions & Answers If you're not sure where to post a UNIX or Linux question, post it here. All UNIX and Linux newbies welcome !! |
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Idle Oracle Process has removed automatically in AIX5.2 | balareddy | AIX | 1 | 06-26-2008 11:07 PM |
| sar output gives 98% idle CPU | Ashrunil | HP-UX | 3 | 08-24-2007 06:02 AM |
| CPU idle | melanie_pfefer | SUN Solaris | 4 | 01-19-2007 02:26 PM |
| finding idle time of a process | Krrishv | Shell Programming and Scripting | 36 | 01-10-2007 06:34 AM |
| Identifiy and Kill Idle Unix(SCO) Process called externally | vbalajis | SCO | 1 | 12-19-2003 07:52 AM |
|
|
Submit Tools | LinkBack | Thread Tools | Display Modes |
|
#1
|
|||
|
|||
|
How to see if the process is idle
We are running AIX 5.3 and for ICICS Printing we have process called cicstermp runing whcih attaches the print to print queue
But is process is triggered when ever a print is to be given Can we find the processes which are idle I mean every time a print is given it creats a new cicstermp process but it doesnot kill it when its done Can we find these kind of processes Some times even if the shell which triggered it gets closed the process runs with out a terminal I am posting few of those output form ps -ef root 5931186 1 0 10:00:12 pts/29 0:00 cicstermp -r CICSREGION -n PRINTER -P lp -cs -dcaisse root 6017234 1 0 Aug 28 - 0:00 cicstermp -r CICSREGION -n PRINTER -P lp -cs -dcaisse |
| Forum Sponsor | ||
|
|
|
#2
|
|||
|
|||
|
Hi,
i hope this will help you # Checking and counting the process [ABC.EXE] which is running on root directory "/" COUNT=`cd / |ps -ef |grep ABC.EXE |wc -l` # THIS WILL CHECK EITHER SERVICE IS RUNNING OR NOT if [ $COUNT = 0 ] then ABC.EXE echo "SERVICE STARTED" exit 0 fi # THIS WILL CHECK IF THE SERVICE IS RUNNING ONLY ONCE if [ $COUNT = 1 ] then echo "SERVICES ALREADYRUNNING" exit 0 fi # THIS WILL CHECK IF THE SERVICE IS RUNNING MORE THAN ONCE if [ $COUNT > 1 ] then banner ERROR echo "SERVICES HALTED - MORE THAN ONE INSTANCE" echo "PLEASE RESTART" echo "PRESS ANY KEY TO CONTINUE" read exit exit 0 fi |
|||
| Google The UNIX and Linux Forums |