OSPF NSSA Redistributed Default Route

I ran into a problem today that I don't understand. My topology is in the link below.

http://postimg.org/image/q2206orvx/

The goal is to get R4 to advertise R3 a default route via BGP, and then make R3 redistribute this into OSPF so that R1 can eventually use it. The current config being used on R3 and R4 is below

 

R3#sh run | s router
router ospf 1
router-id 3.3.3.3
log-adjacency-changes
area 1 nssa
redistribute bgp 2 subnets
network 10.0.23.3 0.0.0.0 area 1
router bgp 2
no synchronization
bgp log-neighbor-changes
network 10.0.34.0 mask 255.255.255.0
neighbor 10.0.34.4 remote-as 1
no auto-summary


and R4

R4#sh run | s router|ip route
router bgp 1
no synchronization
bgp log-neighbor-changes
network 0.0.0.0
neighbor 10.0.34.3 remote-as 2
no auto-summary
ip route 0.0.0.0 0.0.0.0 Null0
ip route 10.0.12.0 255.255.255.0 FastEthernet0/0 10.0.34.3
ip route 10.0.23.0 255.255.255.0 FastEthernet0/0 10.0.34.3


So now on R3's routing table he gets the default route

R3#sh ip route | b Gate
Gateway of last resort is 10.0.34.4 to network 0.0.0.0

10.0.0.0/24 is subnetted, 3 subnets
O IA 10.0.12.0 [110/20] via 10.0.23.2, 00:11:46, FastEthernet0/1
C 10.0.23.0 is directly connected, FastEthernet0/1
C 10.0.34.0 is directly connected, FastEthernet0/0
B* 0.0.0.0/0 [20/0] via 10.0.34.4, 00:30:50


So now I thought that with the combination of the #redistribute bgp 2 subnets command on R3 along with it being in the routing table that R1 would get this route. But it doesn't, as shown in the routing table below on R1

R1#sh ip route ospf
10.0.0.0/24 is subnetted, 3 subnets
O IA 10.0.23.0 [110/20] via 10.0.12.2, 00:25:11, FastEthernet0/0
O E2 10.0.34.0 [110/1] via 10.0.12.2, 00:21:16, FastEthernet0/0

And it doesn't. Can anyone explain?

Comments

  • You are experiencing normal OSPF behavior. OSPF does not "redistribute" a default as you would expect. It instead "generates" a default route via a Type-5 LSA in your case.

    http://www.cisco.com/c/en/us/support/docs/ip/open-shortest-path-first-ospf/47868-ospfdb9.html

  • This document is irrelevant, I'm using an NSSA (i.e. not injecting a default into a normal area). Btw R3 doesn't even generate a type7 default LSA.

     

    R3#sh ip ospf da

     

                OSPF Router with ID (3.3.3.3) (Process ID 1)

     

                    Router Link States (Area 1)

     

    Link ID         ADV Router      Age         Seq#       Checksum Link count

    2.2.2.2         2.2.2.2         858         0x80000008 0x00E4BB 2

    3.3.3.3         3.3.3.3         23          0x80000001 0x008F14 2

     

                    Summary Net Link States (Area 1)

     

    Link ID         ADV Router      Age         Seq#       Checksum

    10.0.12.0       2.2.2.2         1109        0x80000005 0x0048C2

     

                    Type-7 AS External Link States (Area 1)

     

    Link ID         ADV Router      Age         Seq#       Checksum Tag

    10.0.34.0       3.3.3.3         23          0x80000001 0x000548 0

  • I've read through a bunch of historical forum posts on various websites which state that you can't actually redistribute a default route into OSPF. Is that actually the case?

    I will try and find something about this in the main RFC if it is.

  • Turns out that you actually can't redistribute a default route into OSPF at all. The only possible way to get a default route into OSPF is by making a router generate the OSPF default route via a command under the ospf process. Problem solved.

Sign In or Register to comment.