On 7/6/2014 5:07 PM, Daniel van der Steeg wrote:
Hello all,
I have implemented two EEM Policies using TCL on a Cisco Catalyst 6500,
both of them running every X seconds. Now I am trying to find a way to
monitor the CPU and memory usage of these policies, to determine their
footprint. Does anyone have a good idea how I can do this?
It looks like cpmProcExtUtil5SecRev is what you need. This should be
available but it might depend on your IOS. CISCO-PROCESS-MIB shows all
the different incarnations of it. You can also use
cpmProcExtMemAllocatedRev and cpmProcExtMemFreedRev to track memory usage.
Use cpmProcessName to find the process you want to monitor (in this case
grepping for PID but you can look for name):
[rdrake@machine ~]$ snmpwalk -v2c -c community routername
1.3.6.1.4.1.9.9.109.1.2.1.1.2 | grep 318
SNMPv2-SMI::enterprises.9.9.109.1.2.1.1.2.1.318 = STRING: "ISIS Upd PUR"
The 1.318 is the important bit.
[rdrake@machine ~]$ snmpwalk -v2c -c community routername
1.3.6.1.4.1.9.9.109.1.2.3.1.5 | grep 318
SNMPv2-SMI::enterprises.9.9.109.1.2.3.1.5.1.318 = Gauge32: 0
One problem being that this is a percentage with a minimum resolution of
1% (integer based) so even though this is the busiest process on the box
I tested on, I always got zero percent. It should be good for
thresholding if you want to make sure your process doesn't spike the CPU
though. Also, the PID might change every reboot so long term monitoring
might be problimatic unless you can associate the process name with the
other thing.
Reference:
http://tools.cisco.com/Support/SNMP/do/BrowseMIB.do?local=en&mibName=CISCO-PROCESS-MIB
Look at this for oids:
ftp://ftp.cisco.com/pub/mibs/oid/CISCO-PROCESS-MIB.oid
Thanks,
Daniel
Hats,
Robert