Hello folks, can someone suggest why the script below is not returning anything?
My goal is to execute 'show hsrp detail', if HSRP output contains pattern indicated below, I should be able to generate an alert somehow.
Please let me know what I am missing.
event manager applet HSRP
event syslog pattern "Standby router is unknown"
action 1.0 cli show hsrp detail
action 2.0 syslog msg HSRP ISSUE
action 3.0 cli end
This is the output I want to find pattern from:
SWITCHTEST# show hsrp detail
Ethernet2/1 - Group 101 (HSRP-V2) (IPv4)
Local state is Initial(Interface Down), priority 90 (Cfged 90), may preempt
Forwarding threshold(for vPC), lower: 1 upper: 90
Hellotime 3 sec, holdtime 10 sec
Virtual IP address is 10.17.173.1 (Cfged)
Active router is unknown
Standby router is unknown
Authentication text "cisco"
Virtual mac address is 0000.0c9f.f065 (Default MAC)
6 state changes, last state change 04:18:02
IP redundancy name is hsrp-Eth2/1-101 (default)