OSPF_LSA_Deep_Dive

I will start this off by stating that we will start redistribution on the ASBR specified R2 to examine LSA types 4 and 5 (and where we can spot them), and R1 will eventually also be turned into an ASBR when we redistribute some loopback routes into the NSSA Area so we can review type 7 (So the Topology above may not stay 100% accurate as we move along).

Now the Type 4 LSA “ASBR Summary LSA” is created ONLY on ABR’s, so they can build the Shortest Path Tree (SPT) to the ASBR, which is triggered by a router becoming an ASBR in the first place. Being that R2 is technically an ABR (has interface in Area 0 and Area 2), I am curious to see how it will announce itself in “sh ip ospf” output and in the LSA DB.

Before getting into output, let us clarify that Type 5 LSA’s are created only on ASBR’s outside of NSSA OSPF network types, contained the external route information. These LSA’s advertise the O E2 routes with the seed / default metric of 20, supposedly the metric back to the ASBR, which can be changed (which I will) to be O E1 routes which give a true metric / cost from the local router to the destination network.

This is completely uncharted waters for me, so lets get our feet wet:

R2#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R2(config)#router ospf 1
R2(config-router)#redistribute rip ?
  metric       Metric for redistributed routes
  metric-type  OSPF/IS-IS exterior metric type for redistributed routes
  route-map    Route map reference
  subnets      Consider subnets for redistribution into OSPF
  tag          Set tag for routes redistributed into OSPF
  <cr>

R2(config-router)#redistribute rip metric-type 1 subnets

We now have R2 as our ASBR flooding type 5 LSA’s into all non-stub, non-total stub, and non-NSSA area’s. As to my confusion as to whether it would hold its rank as an ABR as well as ASBR:

R2#sh ip ospf
 Routing Process “ospf 1” with ID 22.2.2.2
 Start time: 00:01:37.095, Time elapsed: 00:48:12.161
 Supports only single TOS(TOS0) routes
 Supports opaque LSA
 Supports Link-local Signaling (LLS)
 Supports area transit capability
 It is an area border and autonomous system boundary router

 Redistributing External Routes from,
    rip, includes subnets in redistribution

It does show R2 as both an ABR and ASBR, and I cut off a lot of good Area information with this command (“sh ip ospf”), however you can also see right away what type of network types are being redistributed directly under the highlighted line of router type.

So lets see what this added to R2’s LS DB, if anything:

R2#sh ip ospf database

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

                Router Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum Link count
11.1.1.1        11.1.1.1        386         0x80000004 0x00D970 2
22.2.2.2        22.2.2.2        1572        0x80000004 0x009686 2
33.3.3.3        33.3.3.3        341         0x80000004 0x00866D 2

                Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
172.12.123.1    11.1.1.1        386         0x80000003 0x00B1EA

                Summary Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         11.1.1.1        639         0x80000003 0x00E83F
2.2.2.2         22.2.2.2        363         0x80000003 0x0042D3
3.3.3.3         33.3.3.3        341         0x80000003 0x009B68
172.12.15.0     11.1.1.1        386         0x80000005 0x00184A
172.12.34.0     33.3.3.3        341         0x80000003 0x0059DB

                Router Link States (Area 2)

Link ID         ADV Router      Age         Seq#       Checksum Link count
22.2.2.2        22.2.2.2        1572        0x80000003 0x00F1FA 1

                Summary Net Link States (Area 2)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         22.2.2.2        372         0x80000003 0x00F2E6
3.3.3.3         22.2.2.2        372         0x80000003 0x00963B
11.1.1.1        22.2.2.2        372         0x80000003 0x00705F
22.2.2.2        22.2.2.2        372         0x80000003 0x003DC4
33.3.3.3        22.2.2.2        372         0x80000003 0x000FA4
172.12.15.0     22.2.2.2        372         0x80000003 0x0026EF
172.12.34.0     22.2.2.2        372         0x80000003 0x0054AE
172.12.123.0    22.2.2.2        372         0x80000005 0x006F39

                Type-5 AS External Link States

Link ID         ADV Router      Age         Seq#       Checksum Tag

172.12.23.0     22.2.2.2        1580        0x80000001 0x002015 0

R2#

So R2 is now showing a Type-5 External Link States section in the LS DB, that includes the network being redistributed, and the RID of the router (this router) as the Advertising Router.

So I felt like an idiot afterward, but I went to verify the routes on R3 and show some output from there, however I forgot R3 is directly connected to that network so it isn’t going to show up in the OSPF route table!

However, lets take a look at the OSPF LS DB on R3 to make sure it is seeing the Type 5 LSA’s and possibly spot a Type 4 somewhere in the output:

R3#sh ip ospf database

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

                Router Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum Link count
11.1.1.1        11.1.1.1        1692        0x80000004 0x00D970 2
22.2.2.2        22.2.2.2        911         0x80000005 0x009487 2
33.3.3.3        33.3.3.3        1645        0x80000004 0x00866D 2

                Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
172.12.123.1    11.1.1.1        1692        0x80000003 0x00B1EA

                Summary Net Link States (Area 0)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         11.1.1.1        1945        0x80000003 0x00E83F
2.2.2.2         22.2.2.2        1671        0x80000003 0x0042D3
3.3.3.3         33.3.3.3        1645        0x80000003 0x009B68
172.12.15.0     11.1.1.1        1692        0x80000005 0x00184A
172.12.34.0     33.3.3.3        1645        0x80000003 0x0059DB

                Router Link States (Area 3)

Link ID         ADV Router      Age         Seq#       Checksum Link count
33.3.3.3        33.3.3.3        1645        0x80000003 0x00E4E9 1

                Summary Net Link States (Area 3)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         33.3.3.3        1652        0x80000003 0x007A51
2.2.2.2         33.3.3.3        1652        0x80000003 0x004C7B
11.1.1.1        33.3.3.3        1652        0x80000003 0x00F7C9
22.2.2.2        33.3.3.3        1652        0x80000003 0x00476C
33.3.3.3        33.3.3.3        1652        0x80000003 0x0014D1
172.12.15.0     33.3.3.3        1652        0x80000003 0x00AD5A
172.12.34.0     33.3.3.3        1652        0x80000003 0x0059DB
172.12.123.0    33.3.3.3        1652        0x80000005 0x00F6A3

                Summary ASB Link States (Area 3)

Link ID         ADV Router      Age         Seq#       Checksum

22.2.2.2        33.3.3.3        902         0x80000002 0x003183

                Router Link States (Area 34)

Link ID         ADV Router      Age         Seq#       Checksum Link count
4.4.4.4         4.4.4.4         1607        0x80000005 0x00173A 1
33.3.3.3        33.3.3.3        1665        0x80000005 0x00C15B 1

                Net Link States (Area 34)

Link ID         ADV Router      Age         Seq#       Checksum
172.12.34.4     4.4.4.4         1620        0x80000003 0x009876

                Summary Net Link States (Area 34)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         33.3.3.3        1665        0x80000003 0x007A51
2.2.2.2         33.3.3.3        1665        0x80000003 0x004C7B
3.3.3.3         33.3.3.3        1665        0x80000003 0x009B68
11.1.1.1        33.3.3.3        1665        0x80000003 0x00F7C9
22.2.2.2        33.3.3.3        1665        0x80000003 0x00476C
33.3.3.3        33.3.3.3        1665        0x80000003 0x0014D1
172.12.15.0     33.3.3.3        1665        0x80000003 0x00AD5A
172.12.123.0    33.3.3.3        1665        0x80000005 0x00F6A3

                Summary ASB Link States (Area 34)

Link ID         ADV Router      Age         Seq#       Checksum

22.2.2.2        33.3.3.3        916         0x80000002 0x003183

                Type-5 AS External Link States

Link ID         ADV Router      Age         Seq#       Checksum Tag

172.12.23.0     22.2.2.2        937         0x80000002 0x001E16 0

R3#

So as can be seen highlighted in blue we have our LSA Type 4 “Summary ASB Link States” LSA’s coming from ADV(ertising) Router 2 from it’s RID 22.2.2.2, which is seen being flooded into every Area except for the common Area (o) with the ASBR on R3, and highlighted in red is the Type 5 LSA advertising the redistributed network under Link ID along with R2’s RID.

What I found interesting is that the Type 5 LSA has no Area attached to it as can be seen in the output, it is for all Area’s on the Routers LS DB, and I verified this to be the case on all other routers….

… Including R5 BEFORE I may it an NSSA Area:

R5#sh ip ospf database

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

                Router Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum Link count
5.5.5.5         5.5.5.5         336         0x80000003 0x001B58 1
11.1.1.1        11.1.1.1        340         0x80000005 0x00364A 1

                Net Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum
172.12.15.1     11.1.1.1        341         0x80000001 0x0085BB

                Summary Net Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         11.1.1.1        675         0x80000001 0x00EC3D
2.2.2.2         11.1.1.1        321         0x80000001 0x0041A4
3.3.3.3         11.1.1.1        321         0x80000001 0x0013CE
11.1.1.1        11.1.1.1        675         0x80000001 0x006AB5
22.2.2.2        11.1.1.1        321         0x80000001 0x003C95
33.3.3.3        11.1.1.1        321         0x80000001 0x008B38
172.12.34.0     11.1.1.1        321         0x80000001 0x00D042
172.12.123.0    11.1.1.1        682         0x80000001 0x00EFCA

                Summary ASB Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum

22.2.2.2        11.1.1.1        327         0x80000001 0x0024AD

                Type-5 AS External Link States

Link ID         ADV Router      Age         Seq#       Checksum Tag

172.12.23.0     22.2.2.2        350         0x80000001 0x002015 0

R5#sh ip route ospf
     1.0.0.0/32 is subnetted, 1 subnets
O IA    1.1.1.1 [110/2] via 172.12.15.1, 00:07:09, FastEthernet0/1
     2.0.0.0/32 is subnetted, 1 subnets
O IA    2.2.2.2 [110/66] via 172.12.15.1, 00:06:58, FastEthernet0/1
     33.0.0.0/32 is subnetted, 1 subnets
O IA    33.3.3.3 [110/66] via 172.12.15.1, 00:06:58, FastEthernet0/1
     3.0.0.0/32 is subnetted, 1 subnets
O IA    3.3.3.3 [110/66] via 172.12.15.1, 00:06:58, FastEthernet0/1
     172.12.0.0/24 is subnetted, 4 subnets
O IA    172.12.34.0 [110/66] via 172.12.15.1, 00:06:58, FastEthernet0/1
O E1    172.12.23.0 [110/85] via 172.12.15.1, 00:06:53, FastEthernet0/1

O IA    172.12.123.0 [110/65] via 172.12.15.1, 00:07:09, FastEthernet0/1
     22.0.0.0/32 is subnetted, 1 subnets
O IA    22.2.2.2 [110/66] via 172.12.15.1, 00:06:58, FastEthernet0/1
     11.0.0.0/32 is subnetted, 1 subnets
O IA    11.1.1.1 [110/2] via 172.12.15.1, 00:07:09, FastEthernet0/1
R5#

So the Type 4’s and Type 5 look as they should, and we also see a Type 2 in the output, because R5 is directly connected via FastEthernet, so it is on a non-point-to-point connection (broadcast connection).

So now that it is working, let’s turn it into an NSSA Area, and see what happens to R5’s LS DB and ospf route table:

R5#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R5(config)#router ospf 1
R5(config-router)#area 15 nssa
R5(config-router)#
*Mar 31 20:00:19.008: %OSPF-5-ADJCHG: Process 1, Nbr 11.1.1.1 on FastEthernet0/1 from FULL to DOWN, Neighbor Down: Adjacency forced to reset
R5(config-router)#
ASR#1
[Resuming connection 1 to r1 … ]

R1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#router ospf 1
R1(config-router)#area 15 nssa
R1(config-router)#
*Apr 25 20:28:28.519: %OSPF-5-ADJCHG: Process 1, Nbr 5.5.5.5 on FastEthernet0/1 from FULL to DOWN, Neighbor Down: Adjacency forced to reset
*Apr 25 20:28:29.455: %OSPF-5-ADJCHG: Process 1, Nbr 5.5.5.5 on FastEthernet0/1 from LOADING to FULL, Loading Done
R1(config-router)#
ASR#5
[Resuming connection 5 to r5 … ]

*Mar 31 20:00:39.642: %OSPF-5-ADJCHG: Process 1, Nbr 11.1.1.1 on FastEthernet0/1 from LOADING to FULL, Loading Done
R5(config-router)#

Note that your Adjacencies drop when you reconfigure any kind of stub or NSSA Area 🙂

So lets see what’s new:

R5#sh ip ospf database

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

                Router Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum Link count
5.5.5.5         5.5.5.5         150         0x80000005 0x00BCAE 1
11.1.1.1        11.1.1.1        147         0x80000007 0x00DD98 1

                Net Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum
172.12.15.1     11.1.1.1        147         0x80000003 0x002712

                Summary Net Link States (Area 15)

Link ID         ADV Router      Age         Seq#       Checksum
1.1.1.1         11.1.1.1        152         0x80000002 0x009092
2.2.2.2         11.1.1.1        152         0x80000002 0x00E4F9
3.3.3.3         11.1.1.1        152         0x80000002 0x00B624
11.1.1.1        11.1.1.1        152         0x80000002 0x000E0B
22.2.2.2        11.1.1.1        152         0x80000002 0x00DFEA
33.3.3.3        11.1.1.1        152         0x80000002 0x002F8D
172.12.34.0     11.1.1.1        152         0x80000002 0x007497
172.12.123.0    11.1.1.1        160         0x80000002 0x009320

So as we can see Type 4 and Type 5 LSA’s are no longer reaching R5, which is exactly what we expect to see, and I will stop this post here as creating Type 7 LSA’s will be a gentle segway into the next topic put under a microscope – OSPF Stub Areas!