PDA

View Full Version : OSPF distributing a static route


mmc1800
03-30-2005, 01:07 PM
I am feeling pretty confident OSPF is working well on my network and all is well for the routes to the networks that attach directly to any of the interface on any of the staros routers that are running OSPF.

The situation I have is that I would like OSPF to be aware of some routes that are routed through a non OSPF enabled router (CPE firewalls).

Currently there is a static route in place from the AP radio to the CPE firewall routing a /24 subnet to the firewall, and OSPF is routing to the gateway IP of the firewall:

+-[·]--------------------------- Static Routes --------------------------------+
¦ IP Address / Mask Gateway Device Comments ¦
¦ 1 10.200.205.0/24 10.200.2.205 wpci2 Customer #1 ^¦

ospfd> sh ip os ro
============ OSPF network routing table ============
<..snip..>
N 10.200.2.0/24 [54] area: 0.0.0.0
directly attached to wpci1
<..snip..>

Currently I have to keep static routes in place on every router hop all the way back to the ASBR to make this route happen. I would like the AP to distribute this route accross OSPF so I can remove all the static routes except the one on the actual AP that makes the last hop.

I was thinking that adding "redistribute static" would do the trick, but if that is the way something about how I am doing it is not working. When I added redistribute static I started to see that router in the list as an ASBR but it not the routes I was looking for (it didn't seem to add any routes, just identified itself as an ASBR).

I could theoretically enable RIP on the firewalls and then play with redistribute RIP but I would rather just define these last hop routes from the AP to the cpe firewall and have it let the OSPF routers know about the route.

I am hoping someone has some experience with this kind of scenario and could let me know what was working for you. Thanks for all the posts and discussions on these forums it made a basic OSPF setup realatively painless to get working.

lonnie
04-03-2005, 01:02 AM
check this link
http://forums.star-os.com/showthread.php?t=3648

mmc1800
04-04-2005, 02:34 PM
That did it for sure.

That information is a little hidden in the thread, so in general if you find this thread looking for an answer to my question, the readers digest version is that you have to do the following:

1) add the static route through zebra (quote from other thread: To do that, use the telnet client to connect to 127.0.0.1, port 2601. Enter the password and 'enable', then 'configure terminal', and 'ip route x.x.x.x/x y.y.y.y' where x.x.x.x/x is the subnet you want to route to, and y.y.y.y is the gateway address. 'write file', quit, save/activate changes.)

and then

2) add redistribute static through your ospf interface (advanced routing/configure OSPF, enter password, enable, configure terminal, router ospf, redistribute static, write file, exit, exit, save/activate changes).

Works like a charm. My network now has nothing in any of the 'static and default routing' section of the staros radios, except the border routers that redistribute the static routes.

Thanks for everyones help.