03-24-2016 07:26 AM
Hi Guys, I am trying to run script on my 3845 to capture the stats when it spikes, I have set the levels quite low for testing purpose. However i am not seeing a file being generated in directory.I can see the HIGH CPU in the sys log but i am not seeing a file.
Can someone check my script ? (I compiled this script from the cisco site which was for the 6500s)
event manager applet CPU_STATS
event snmp oid "1.3.6.1.4.1.9.9.109.1.1.1.1.3.1" get-type exact entry-op gt entry-val "10" exit-op lt exit-val "5" poll-interval 5
action 1.01 syslog msg "------HIGH CPU DETECTED----, CPU:$_snmp_oid_val%"
action 1.02 cli command "enable"
action 1.03 cli command "show clock | append disk0:cpu_stats"
action 1.04 cli command "show proc cpu sort | append disk0:cpu_stats"
action 1.05 cli command "Show proc cpu | exc 0.00% | append disk0:cpu_stats"
action 1.06 cli command "Show proc cpu history | append disk0:cpu_stats"
action 1.07 cli command "show logging | append disk0:cpu_stats "
action 1.08 cli command "show spanning-tree detail | in ieee|occurr|from|is exec | append disk0:cpu_stats"
action 1.09 cli command "debug netdr cap rx | append disk0:cpu_stats"
action 1.10 cli command "show netdr cap | append disk0:cpu_stats"
action 1.11 cli command "undebug all"
Solved! Go to Solution.
03-25-2016 01:28 PM
If you see the syslog, then the problem is either that the disk0: file system doesn't support "append" (you can test his manually) or more likely you're using AAA command authorization, and you need to add:
event manager session cli username USER
Where USER is a username authorized to run all of the commands in question.
03-25-2016 01:28 PM
If you see the syslog, then the problem is either that the disk0: file system doesn't support "append" (you can test his manually) or more likely you're using AAA command authorization, and you need to add:
event manager session cli username USER
Where USER is a username authorized to run all of the commands in question.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide