removing a redistributed /32 from advertisement

Started by icecream-guy, January 12, 2016, 02:43:23 PM

Previous topic - Next topic

icecream-guy

What is the best way ?


have a static route to a vip,
it's a host route /32
which is redistributed into ospf via a 'redistribute static' controlled by an ACL.


The goal is that there is an underlying /31 route coming from another site
(gets flushed in routing table due to the longest match rule).
Which needs to get advertised (redistributed?) into the network and take over to advertise the route to the new site where the VIP would be.

Idea plan would be to monitor the vip , say via ICMP,  when it goes unavailable, do something to remove the host route from the routing table, let the /31 from the other site slide into the routing table and get advertised to the rest of the network. 

i.e. like "no" out the static route, would be fine, but when the VIP come available again, I'd need the routing table to advertise the /32 route again. 

This all would happen automagically.


2 more cents, if I did it via ICMP, how would I know I'm pinging the right VIP at same ip?
:professorcat:

My Moral Fibers have been cut.

wintermute000


that1guy15

With BGP you can do a conditional route-map to redistribute this as you are suggesting. But OSPF you can only do a conditional default AFAIK.

But you can setup a track object on the static so when the ping fails then the static is placed in the RIB and redistributed into OSPF.
That1guy15
@that1guy_15
blog.movingonesandzeros.net

icecream-guy

sorry, should have been more clear.



this is a load balancer vip, not HSRP, VRRP, GLBP, vDC etc.

:professorcat:

My Moral Fibers have been cut.

Ctrl Z

Late reply  :mrgreen:

I did something like this once but it was pretty platform dependent. Using an F5 VIP you can enable route advertisement for the VIP /32, but only when all virtual servers using that VIP are available. Then use OSPF on the F5 to advertise the VIP into the network.

VIP goes down, F5 withdraws the route from OSPF. VIP comes alive, F5 advertises the /32 through OSPF.

If this wasn't for an F5 then forget everything I said.