cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1718
Views
6
Helpful
10
Replies

Advertise Routes when destination unreachable

ahmad82pkn
Level 2
Level 2

Guys, need your help again as always.

What i want to achieve is track a destination, if that destination is unreacable then bring that static route into routing table.

i know Track can take our route from routing table if destination is unreachable, i want to bring route into table if destination is unreachable.

actually my Site A is advertising some routes in my internal MPLS cloud. if Site A WAN link goes down.i want to advertise same routes from Site B router. so i want to track Site A wan link or loopback from Site B router and advertise same routes if Loopback of Site A not reachable.

any suggestion?

1 Accepted Solution

Accepted Solutions

Hi!

As per what you stated "  What i want to achieve is track a destination, if that destination is  unreacable then bring that static route into routing table"

I couldt find a related example on cisco website which fits, but i have a config for you which i wrote.

------------------------------------------------------------------------------------------------------------------------------

track 1 ip route 10.10.10.10/24 reachability

  event manager applet TRACK_IF_DOWN

    event track 1 state down

    action 1.0 cli command "enable"

    action 2.0 cli command "conf t"

    action 3.0 cli command "ip route 192.168.1.0 255.255.255.0 192.168.2.1"

    exit

  event manager applet TRACK_IF_UP

  event track 1 state up

  action 1.0 cli command "enable"

    action 2.0 cli command "conf t"

    action 3.0 cli command "no ip route 192.168.1.0 255.255.255.0 192.168.2.1"

  exit

------------------------------------------------------------------------------------------------------------------------------

1] You can change the commands as per your need like for vrf "ip route vrf " and so on.

    Here is the link for Emebeded Event Manager

    http://www.cisco.com/en/US/docs/ios-xml/ios/eem/configuration/12-4t/eem-12-4t-book.html

2] You can use IP SLA with TRACK for tracking the destination as well.

Let me know if this helped. Thanks.

View solution in original post

10 Replies 10

rais
Level 7
Level 7

Does it mean that constantly advertising routes from site B with inferior metrics [when compared to those of site A] won't work for you?

Thanks.

in my design not an option, i am running OSPF with carrier PE router, and they are doing BGP internal in their MPLS core. and all my attributes are lost in their cloud.

Regards,

Try this out.

There is also a conditional default-route advertisement supported on Cisco ospf that you might be able to use.

HTH.

thank you, i will try this and see if it serves the purpose. thank you Rais.

Nandan Mathure
Level 1
Level 1

@ahmad82pkn

You can create a tracked object. Then create a event manager applet for "event track , state = down" and insert required "action cli " for advertising routes. & another applet to reverse the action when state = up.

That should work.

Nandan Mathure

can you give me some document URL for this?

Hi!

As per what you stated "  What i want to achieve is track a destination, if that destination is  unreacable then bring that static route into routing table"

I couldt find a related example on cisco website which fits, but i have a config for you which i wrote.

------------------------------------------------------------------------------------------------------------------------------

track 1 ip route 10.10.10.10/24 reachability

  event manager applet TRACK_IF_DOWN

    event track 1 state down

    action 1.0 cli command "enable"

    action 2.0 cli command "conf t"

    action 3.0 cli command "ip route 192.168.1.0 255.255.255.0 192.168.2.1"

    exit

  event manager applet TRACK_IF_UP

  event track 1 state up

  action 1.0 cli command "enable"

    action 2.0 cli command "conf t"

    action 3.0 cli command "no ip route 192.168.1.0 255.255.255.0 192.168.2.1"

  exit

------------------------------------------------------------------------------------------------------------------------------

1] You can change the commands as per your need like for vrf "ip route vrf " and so on.

    Here is the link for Emebeded Event Manager

    http://www.cisco.com/en/US/docs/ios-xml/ios/eem/configuration/12-4t/eem-12-4t-book.html

2] You can use IP SLA with TRACK for tracking the destination as well.

Let me know if this helped. Thanks.

that is something really cool never came to know such flexibility exists .

Looks like my life is going to be lot easier.

thank you very much Nandan

Hi,

If you can not modify the attritbutes to the MPLS network and you run ospf  between PE-CE I would recommend an other solution.

From the site A which is the primary site you could advertise all your subnets to the MPLS.

From the site B which is the backup site to advertise an ospf summary address  of these subnets.

So, the MPLS network, when both A and B are up selects the most specific subnets of Routers A to route the traffic. If Router A fails the traffic is routed via the summary address of Router B.

Hope that helps,

Vasilis

hi Vasileios, Thats what i am doing right now i thought to find another way.

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community:

Review Cisco Networking products for a $25 gift card