I have set up a small script to monitor BGP peering and to failover the HSRP based on the syslog etc. What I noticed is that the event gets triggered but it doesn't make the necessary changes. What I want is to change the HSRP priority upon a BGP peering failure. Below is the script. Can someone please help whats missing here. I have this script on a 3800 series router
Cisco IOS Software, 3800 Software (C3845-ADVIPSERVICESK9-M), Version 12.4(25b), RELEASE SOFTWARE (fc1) System image file is "flash:c3845-advipservicesk9-mz.124-25b.bin"
router#sh log | i BGP Jul 16 07:54:29.978: %BGP-5-ADJCHANGE: neighbor 192.168.1.1 Down Admin. shutdown Jul 16 07:54:29.978: %HA_EM-2-LOG: eBGP-MANUAL-DOWN: EEM reconfiguring router for HSRP priority of 90 as BGP neighbour is down Jul 16 10:54:10.988: %BGP-5-ADJCHANGE: neighbor 192.168.1.1 Up Jul 16 10:54:10.992: %HA_EM-2-LOG: eBGP-UP: EEM reconfiguring router for HSRP priority of 140 as BGP neighbour is up