![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Memory and CPU utilization process | learnbash | Shell Programming and Scripting | 4 | 05-21-2008 03:21 PM |
| cpu utilization of a process | iam | AIX | 2 | 02-20-2008 01:50 AM |
| Counting Files and send an email Notification if it exceeds a limit | amitsayshii | UNIX for Dummies Questions & Answers | 10 | 07-07-2006 11:25 AM |
| script to check for a particular process and alert if its not running | goks | Shell Programming and Scripting | 1 | 12-09-2005 05:11 AM |
| ALERT!!! ALERT!!! I messed up the UNIX!!! | Fwurm | UNIX for Dummies Questions & Answers | 15 | 11-06-2001 05:53 AM |
![]() |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
|
|
||||
|
Alert When a Process Exceeds a CPU Utilization Limit...
Hi EveryOne
We run CICS Sofware on our AIX Machine... When ever some Process or Transaction loops it Takes heavy process Usage.. Is there a way that i can Get a alert message or a Message Thrown on to screen when ever a process named "cicsas" uses more that 20%... fo CPU.. I was tracking the CPU% form topas command and kill the porcess if it has more that 20% CPU and time is more than 15mins... Can we automate this or atleast get altered that some thing is wrong.... |
|
||||
|
Quote:
Can we do this with some shell scripts... ?? I just need a alert need not limit the process from using the CPU... based on the alert we need to take necessarty action... |
|
||||
|
Quote:
1) Moniotr topas -P 2) Get top 10 process 3) Check if it has "cicsas" 4) Check the % utilizion and of it exceeds 20% through a message on to console.. But topas -P is getting refreshed after given interval -i(interval time) Is there a way that i can get a snapshot of the processor utilization at paticular time.... |
|
||||
|
I have done some thing of this sort...
cpu=`ps aux|grep cicsas|head -1|tr -s " " "" |cut -f 3 -d " "` limit=20.0 c=$(echo $limit - $cpu | bc) if [[ $c = -* ]] ; then mail -s "Process is Taking more Memory.." USER_NAME < tmp fi This sends me a mail... but. Only when i check the mail i can see the messages... Is is possible to get alert message when ever a new mail comes?? This generally happens when ever a user logins... we get a message on screen saying "[YOU HAVE NEW MAIL]" Can this happen when ever a new mail comes in..... |
![]() |
| Bookmarks |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|