Monitor cpu abusers

I have found a script called monitorCpuUsage.sh. It is meant to be called from crontab and to inform you of processes or users who maybe using excessive amounts of cpu.

Here is the help screen:

# ./monitorCpuUsage.sh -h (help)

Usage: monitorCpuUsage.sh
-u starting uid, must be an integer greater than or equal to 0 (only used with “-w users”)
-m max cpu, must be an integer greater than or equal to 0 and less than 100
-w what to watch, must be “users” or “procs”
-e must contain an email address
-d specifies debug mode in which -e, -m, and -u do not need to be specified.

Here the script in use. Use the -d option which means the script sets the “maximum cpu allowed to -1? and prints to the screen rather than emailing.