cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
6822
Views
0
Helpful
7
Replies

EEM Tracking two tunnel interfaces at the same time

Ahmed Shaheen
Level 1
Level 1

Hi Everyone,

luckly i just got introduced to EEM lately, and i was wondering how life saver this would be in alot of enviroments..

I am trying to write an EEM to monitor two out of three tunnel interfaces if they went down i'd like to perform an action on the third interface.

i went through online posts and saw there was "event track" under the EEM, but when i login to  any of my routers i can't see this, i dont get the option track.

here is what i want to do..

monitor tunnel 100 and tunnel 200 - if the line protocol went down or there are no routing information recieved on them action is to unshut tunnel 300 and tunnel 400

thanks guys for help in advance

2 Accepted Solutions

Accepted Solutions

avayner
Level 1
Level 1

Hi,

Here is an example that does something similar:

track 10 interface Ethernet0/0 line-protocol

delay up 10

!

track 11 interface Ethernet0/1 line-protocol

delay up 10

!

track 12 interface Ethernet0/2 line-protocol

delay up 10

!

track 13 interface Ethernet0/3 line-protocol

delay up 10

!

track 19 list threshold percentage

object 10

object 11

object 12

object 13

threshold percentage down 51 up 100

!

event manager applet DOWN

event track 19 state down

action 1.0 cli command "enable"

action 1.1 cli command "conf t"

action 2.0 cli command "int lo100"

action 2.1 cli command "shut"

action 9.0 syslog priority alerts msg "SWITCHOVER TRIGGER"

!

event manager applet UP

event track 19 state up

action 1.0 cli command "enable"

action 1.1 cli command "conf t"

action 2.0 cli command "int lo100"

action 2.1 cli command "no shut"

action 9.0 syslog priority alerts msg "PREEMPT TRIGGER“

View solution in original post

You can catch the syslog event generated by the track object using the "event syslog" detector.

View solution in original post

7 Replies 7

avayner
Level 1
Level 1

Hi,

Here is an example that does something similar:

track 10 interface Ethernet0/0 line-protocol

delay up 10

!

track 11 interface Ethernet0/1 line-protocol

delay up 10

!

track 12 interface Ethernet0/2 line-protocol

delay up 10

!

track 13 interface Ethernet0/3 line-protocol

delay up 10

!

track 19 list threshold percentage

object 10

object 11

object 12

object 13

threshold percentage down 51 up 100

!

event manager applet DOWN

event track 19 state down

action 1.0 cli command "enable"

action 1.1 cli command "conf t"

action 2.0 cli command "int lo100"

action 2.1 cli command "shut"

action 9.0 syslog priority alerts msg "SWITCHOVER TRIGGER"

!

event manager applet UP

event track 19 state up

action 1.0 cli command "enable"

action 1.1 cli command "conf t"

action 2.0 cli command "int lo100"

action 2.1 cli command "no shut"

action 9.0 syslog priority alerts msg "PREEMPT TRIGGER“

Hi Arie,

i dont have the option event track in my EEM

You can catch the syslog event generated by the track object using the "event syslog" detector.

thats true!! but i wanted the EEM to start only when both tunnels goes down

Hi Ahmed,
Even though my response is too late, I'd still like to contribute.
use track a track with 'boolean or' which can then be implemented into an applet to track the when the sate of both the tunnels are down.


e.g
track x boolean 

 object x  

 object x

track the object in your event applet. So, when both the object's go down your event will be triggered. 

racosta01111
Level 1
Level 1

Hi Avayner,

Good Day,

Just wan to know the unit being used for threshold percentage down 51 up 100.

threshold percentage down 51 up 100

Is that 51 seconds and 100 seconds?

Thank you,

RJ

I think it refers to the amount of tracked objects, not seconds.

for example if you track 4 objects, you can define how many objects must be down, before the tracking returns "down".

 

let's say you want that at least 1 objects must be up, then you would define 0% as "down" and 25% as up:

threshold percentage down 0 up 25


Track 20
List Threshold percent
Threshold percent is UP
1 changes, last change 00:02:24
Current percentage 100%
Threshold percentage down 0% up 25%
Track List Members:
object 13 UP (25%)
object 12 UP (25%)
object 11 UP (25%)
object 10 UP (25%)

 

if you want at least 2 objects "up", you would use:

threshold percentage down 25 up 50

 

if you want at least 3 objects "up", you would use:

threshold percentage down 50 up 75