05-19-2010 09:41 AM - edited 03-06-2019 11:10 AM
Hi,
Having been reading about EEM, i would like to try to use it in applet form, to track objects in IOS.
When i try to config it, i dont see the cli option event track .....
I have 12.2(50) IP services with EEM 2.40
Am i missing something?
TIA
Alan
Solved! Go to Solution.
06-01-2010 08:19 AM
While this will work, you may find the syslog solution a little better as it will not add the extra SNMP polling overhead.
05-19-2010 10:26 AM
Hi Alan,
Do you see this command:
Switch-A(config)#event manager applet test ?
authorization Specify an authorization type for the applet
class Specify a class for the applet
trap Generate an SNMP trap when applet is triggered.
Switch-A(config)#event manager applet test
The above ouput is from a 3750-E
Reza
05-19-2010 10:43 AM
Hi Reza,
I see this at the event menu
INBOUND-STACK(config-applet)#event ?
application Application specific event
cli CLI event
config Configuration policy event
counter Counter event
env Environmental event
gold GOLD event
interface Interface event
ioswdsysmon IOS WDSysMon event
none Manually run policy event
oir OIR event
snmp SNMP event
snmp-notification SNMP Notification Event
syslog Syslog event
tag event tag identifier
timer Timer event
05-19-2010 10:50 AM
That is good. So you are able to configure the applet.
Also have a look at this config guide for more details
05-19-2010 11:01 AM
Hi Reza,
I've looked at the guide, but its not clear at all how to link an event to the tracked object.
Cheers
Alan
05-30-2010 10:48 AM
Object tracking support for EEM does not exist in the Cat3K line. However, you should be able to use the syslog ED to match on TRACKING-5-STATE messages. When your tracked object changes state, do you see those syslog messages? If so, just build an EEM applet to watch for them. For example:
event manager applet track-down
event syslog pattern "TRACKING-5-STATE: 1 .*Up->Down"
...
06-01-2010 04:12 AM
Hi Joe, thanks for the reply, i've not yet tried that, but certainly sounds plausible
I did manage to find another way though, which i have provided for the benefit of others
event manager applet SLADOWN
event snmp oid 1.3.6.1.4.1.9.9.42.1.2.9.1.6.10 get-type exact entry-op eq entry-val "1" exit-op eq exit-val "2" poll-interval 2
action 0.5 cli command "enable"
action 1.0 cli command "conf t"
action 2.0 cli command "int g1/0/18"
action 3.0 cli command "shut"
event manager applet SLAUP
event snmp oid 1.3.6.1.4.1.9.9.42.1.2.9.1.6.10 get-type exact entry-op eq entry-val "2" exit-op eq exit-val "1" poll-interval 2
action 0.5 cli command "enable"
action 1.0 cli command "conf t"
action 2.0 cli command "int g1/0/18"
action 3.0 cli command "no shut"
06-01-2010 08:19 AM
While this will work, you may find the syslog solution a little better as it will not add the extra SNMP polling overhead.
06-01-2010 08:31 AM
Joe,
You're right, it will, but i will check the merits of both and see what one fits best. AT least i have more than one alternative
Cheers
Alan
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