09-24-2012 02:39 PM - edited 03-07-2019 09:04 AM
Ok I didn't setup my OSPF on my 7010. Today I found out that any static route I put into my 7010 gets sent into to my MPLS network. My 6509's you have to "Tag" the static rout for this to happen. Was under the impression the same was necessary for the 7010 or at least it had to "match" an access list.
How can I fix the below so that by default all static routes are not resdistributed into OSPF?
route-map ospf2mpls permit 10
match interface Vlan20 Vlan100 Vlan116 Vlan120 Vlan242 Vlan244 Vlan250
set tag 10194
set metric 100
set metric-type type-1
route-map static2mpls permit 10
match ip address Static2OSPF_REDIST
set tag 10194
set metric 100
set metric-type type-1
ip access-list Static2OSPF_REDIST
10 permit ip 10.192.10.0/24 any
==Static routes===
ip route 0.0.0.0/0 10.192.16.30
ip route 10.20.20.0/24 10.192.16.1
ip route 10.20.60.0/24 10.192.16.1
ip route 10.192.10.0/24 10.192.16.2
.
.
.
end static routes
09-24-2012 03:27 PM
You cannot use access-list for redistribution. ACL is used for PBR only, for redistribution, you need to use prefix-list:
HTH,
jerry
09-24-2012 03:29 PM
Yes, understood. But why is nxos taking all of my statics and redistributing them?
09-24-2012 03:39 PM
It will take it because it sees it is a route-map, not what is inside the route-map. This is why documentation comes in handy in this situation.
Regards,
jerry
09-24-2012 03:44 PM
sorry don't understand how the below tells the nexus to suck in all my static routes. is "redistribute static" enabled by default on the nexus?
route-map static2mpls permit 10
match ip address Static2OSPF_REDIST
set tag 10194
set metric 100
set metric-type type-1
ip access-list Static2OSPF_REDIST
10 permit ip 10.192.10.0/24 any
09-24-2012 03:47 PM
Wait, can you post all the routing config? I need to see the OSPF process configuration. Redistribution is not on by default.
Regards,
jerry
09-24-2012 03:53 PM
is this enough?
router ospf 1
router-id 10.194.255.255
redistribute direct route-map ospf2mpls
redistribute static route-map static2mpls
router bgp 64520
router-id 10.194.160.1
timers bgp 10 30
address-family ipv4 unicast
network 172.20.192.0/23
network 172.20.194.0/23
distance 20 20 20
neighbor 10.194.160.2 remote-as 64520
remote-as 64520
dont-capability-negotiate
update-source Vlan160
address-family ipv4 unicast
09-24-2012 03:58 PM
Yes, let me quote your config:
router ospf 1
router-id 10.194.255.255
redistribute direct route-map ospf2mpls
redistribute static route-map static2mpls <<< You are redistibuting Static into OSPF
You configured it to redistribute static into OSPF. This is not the default behavior. Like I said, you need to change the route-map to use prefix-list to fix the problem.
Regards,
jerry
09-24-2012 04:02 PM
Ah, so it is ignoring the "route-map static2mpls" and is just seeing "redistribute static"
Then why in the world did it allow route-map static2mpls
to be put in? Arghhhh!!!! Thanks!
09-24-2012 04:04 PM
It is ignoring the match ip address Static2OSPF_REDIST and permit everything.
Regards,
jerry
09-02-2018 12:49 AM
hello Jerry,
I have similar problem.. but I already use prefix list to redistribute static to OSPF but still it's redistribute everything that I add to static route.. do you have any suggestion?
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide