cancel
Showing results for 
Search instead for 
Did you mean: 
cancel

Redistribution of Statics in to OSPF on Nexus 7000

malcolmsalmons
Beginner
Beginner

Hi

I'm looking to redistribute static routes in to OSPF on a Nexus 7k. To do this I'll be using a route-map with a match statement. My question is can you match routes using an ACL, a prefic-list or both. The reason that I ask is that in some docs I've read it states the following:

IP access lists—(For policy-based routing only). Match based on source or destination IP address,

protocol, or QoS parameters.

This tends to indicate that you can't use IP access lists for the match criteria for redistribution. Can anyone confirm this from their experience?


Thanks

Malcolm

2 REPLIES 2

mgalazka
Beginner
Beginner

I just did some testing of this... and the documentation appears to be correct.  I couldn't get proper redistribution when using route-map with ACL.  I set up an ACL that didn't permit anything, and all my static routes were redistributed.  When I used a prefix list, it behaved as expected.

See my output below for reference.

NexusLab(config)# do show run | b route-map

route-map test permit 10

  match ip address redistribute-static

route-map test2 permit 10

  match ip address prefix-list redist-prefix

...

NexusLab(config)# do show ip access-l redistribute-static

IP access list redistribute-static

        20 deny ip any any

NexusLab(config)#

NexusLab(config)#

NexusLab(config)#

NexusLab(config)# do show ip prefix-list

ip prefix-list redist-prefix: 1 entries

   seq 5 permit 1.1.1.1/32

NexusLab(config)#

NexusLab(config)#

NexusLab(config)#

NexusLab(config)# do show ip route static

IP Route Table for VRF "default"

'*' denotes best ucast next-hop

'**' denotes best mcast next-hop

'[x/y]' denotes [preference/metric]

1.1.1.1/32, ubest/mbest: 1/0

    *via Null0, [1/0], 00:12:21, static

3.3.3.3/32, ubest/mbest: 1/0

    *via Null0, [1/0], 00:05:59, static

NexusLab(config)#

NexusLab(config)#

NexusLab(config)# router ospf 44

NexusLab(config-router)# redistribute static route-map test

NexusLab(config-router)# do show ip ospf data external self

        OSPF Router with ID (10.100.100.100) (Process ID 44 VRF default)

                Type-5 AS External Link States

Link ID         ADV Router      Age        Seq#       Checksum Tag

1.1.1.1         10.100.100.100  612        0x80000002 0xe49d    0

3.3.3.3         10.100.100.100  7          0x80000002 0x88f1    0

NexusLab(config-router)# redistribute static route-map test2

NexusLab(config-router)# do show ip ospf data external self

        OSPF Router with ID (10.100.100.100) (Process ID 44 VRF default)

                Type-5 AS External Link States

Link ID         ADV Router      Age        Seq#       Checksum Tag

1.1.1.1         10.100.100.100  627        0x80000002 0xe49d    0

NexusLab(config-router)#

Hope this helps.

Matt

Hi Matt

So from your output it looks like the access-list isn't used and the route-map matches all statics and redistributes them. Looks like I'll be using prefix-lists then.

Thanks for testing that out

Malc

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: