cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
2027
Views
0
Helpful
1
Replies

OSPF Static route redistribution and route map question

Craddockc
Level 3
Level 3

Community,

For some reason I cant seem to get my route map to work. I am trying to redistribute static routes into the OSPF 1 process so they can be advertised using the following:

router ospf 1

redistribute static route-map Static-Routes

route-map Static-Routes permit 10
match ip address Static-Routes

ip access-list Static-Routes
10 permit ip any any

What I want to accomplish is this. I want to redistribute all static routes except for 10.10.10.1 but all other static routes need to be advertised via OSPF. This is on a nexus 9K by the way so I think the "subnets" option is on by default. No classful redistribution happening. I tried setting up my "Static-Routes" ACL like this but it didnt work:

ip access-list Static-Routes

5 deny ip 10.10.10.1 0.0.0.0 any

10 permit ip any any

Im thinking I need a deny clause in my route map but im not sure how to set this up. Can you guys/gals help? Thanks.

1 Accepted Solution

Accepted Solutions

Julio Garcia
Level 1
Level 1

Hi,

I would use a standard ACL instead of extended, or even an IP Prefix list.

5 deny 10.10.10.1 0.0.0.0

10 permit any

Then create a second clause to deny the rest of routes to be redistributed (although this clause is redundant since by default there is an implicit deny in a route-map applied to redistribution according to documentation)

route-map Static-Routes deny 20

Another way of doing it is denying first and permitting afterwards:

ip access-list 1 permit 10.10.10.1 0.0.0.0

!

route-map Static-Routes deny 10

   match ip address 1

!

route-map Static-Routes permit 20

!

Regards,

Julio

View solution in original post

1 Reply 1

Julio Garcia
Level 1
Level 1

Hi,

I would use a standard ACL instead of extended, or even an IP Prefix list.

5 deny 10.10.10.1 0.0.0.0

10 permit any

Then create a second clause to deny the rest of routes to be redistributed (although this clause is redundant since by default there is an implicit deny in a route-map applied to redistribution according to documentation)

route-map Static-Routes deny 20

Another way of doing it is denying first and permitting afterwards:

ip access-list 1 permit 10.10.10.1 0.0.0.0

!

route-map Static-Routes deny 10

   match ip address 1

!

route-map Static-Routes permit 20

!

Regards,

Julio