cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
954
Views
0
Helpful
2
Replies

OSPF database omitting the more specific external prefix

ronaldobf
Level 1
Level 1

Hi guys.

Today I was analyzing an environment which runs OSPF. The router has some external routes. I got, as example, the prefixes 10.1.1.0/24 and 10.1.1.0/25 from one router and 10.1.1.0/25 from another.

Everything is working fine but when I issue "show ip ospf external database" for that specific IP, I just see the more generic route (/24) from the router which advertises both prefixes /25 and /24. I mean, the database does not show the /25 from the router which advertises both the /24 and /25, as shown below (reproduced in lab as below):

Database without issuing a specific IP (3 prefixes):

R3#sh ip os d e

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

                Type-5 AS External Link States

  LS age: 526

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.0 (External Network Number )

  Advertising Router: 40.40.40.40

  LS Seq Number: 80000001

  Checksum: 0x126A

  Length: 36

Network Mask: /25

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 20

        Forward Address: 0.0.0.0

        External Route Tag: 0

  Routing Bit Set on this LSA

  LS age: 714

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.0 (External Network Number )

  Advertising Router: 50.50.50.50

  LS Seq Number: 80000002

  Checksum: 0x7B62

  Length: 36

  Network Mask: /24

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 10

        Forward Address: 0.0.0.0

        External Route Tag: 0

  Routing Bit Set on this LSA

  LS age: 720

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.127 (External Network Number )

  Advertising Router: 50.50.50.50

  LS Seq Number: 80000001

  Checksum: 0x8559

  Length: 36

  Network Mask: /25

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 10

        Forward Address: 0.0.0.0

        External Route Tag: 0

Specifying the IP  I got only 2 prefixes:

R3#sh ip os d e 1.1.1.0

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

                Type-5 AS External Link States

  LS age: 448

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.0 (External Network Number )

  Advertising Router: 40.40.40.40

  LS Seq Number: 80000001

  Checksum: 0x126A

  Length: 36

  Network Mask: /25

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 20

        Forward Address: 0.0.0.0

        External Route Tag: 0

  Routing Bit Set on this LSA

  LS age: 635

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.0 (External Network Number )

  Advertising Router: 50.50.50.50

  LS Seq Number: 80000002

  Checksum: 0x7B62

  Length: 36

  Network Mask: /24

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 10

        Forward Address: 0.0.0.0

        External Route Tag: 0

R3#sh ip route 1.1.1.0

Routing entry for 1.1.1.0/25

  Known via "ospf 1", distance 110, metric 10, type extern 2, forward metric 10

  Last update from 10.1.1.1 on FastEthernet0/0, 00:11:25 ago

  Routing Descriptor Blocks:

  * 10.1.1.1, from 50.50.50.50, 00:11:25 ago, via FastEthernet0/0

      Route metric is 10, traffic share count is 1

I would like to understand the reason when I issue "show ip ospf database external" specifying the IP it only shows the generic route /24 instead of showing both /24 and /25.

Regards,

1 Accepted Solution

Accepted Solutions

cadet alain
VIP Alumni
VIP Alumni

Hi,

It is filtering on the LS ID not the prefix, the one you don't see anymore as LS ID of 1.1.1.127 instead of 1.1.1.0.

Routing Bit Set on this LSA

  LS age: 720

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.127 (External Network Number )  <<<<<<<<<<<<<

  Advertising Router: 50.50.50.50

  LS Seq Number: 80000001

  Checksum: 0x8559

  Length: 36

  Network Mask: /25

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 10

        Forward Address: 0.0.0.0

        External Route Tag: 0

Regards

Alain

Don't forget to rate helpful posts.

Don't forget to rate helpful posts.

View solution in original post

2 Replies 2

cadet alain
VIP Alumni
VIP Alumni

Hi,

It is filtering on the LS ID not the prefix, the one you don't see anymore as LS ID of 1.1.1.127 instead of 1.1.1.0.

Routing Bit Set on this LSA

  LS age: 720

  Options: (No TOS-capability, DC)

  LS Type: AS External Link

  Link State ID: 1.1.1.127 (External Network Number )  <<<<<<<<<<<<<

  Advertising Router: 50.50.50.50

  LS Seq Number: 80000001

  Checksum: 0x8559

  Length: 36

  Network Mask: /25

        Metric Type: 2 (Larger than any link state path)

        TOS: 0

        Metric: 10

        Forward Address: 0.0.0.0

        External Route Tag: 0

Regards

Alain

Don't forget to rate helpful posts.

Don't forget to rate helpful posts.

Hi Alain.

I see what you mean. Since there are two network IPs (even with different subnet mask) for the same advertising router, it must differentiate one from another. Normally, the link state ID is the network IP (all bits 0 in host portion), but with two IDs it must use the bits within the host portion (including broadcast).

This is shown in the RFC 1583.

http://www.ietf.org/rfc/rfc1583.txt

 12.1.4.  Link State ID

            This field identifies the piece of the routing domain that
            is being described by the advertisement.  Depending on the
            advertisement's LS type, the Link State ID takes on the
            values listed in Table 16.


            Actually, for Type 3 summary link (LS type = 3)
            advertisements and AS external link (LS type = 5)
            advertisements, the Link State ID may additionally have one
            or more of the destination network's "host" bits set. For
            example, when originating an AS external link for the
            network 10.0.0.0 with mask of 255.0.0.0, the Link State ID

In my case, 1.1.1.0/24 and 1.1.1.0/25 would the same LS ID 1.1.1.0 so, to differentiate and to generate separated LS for both, the OSPF used the host bits, as expected per RFC 1583. In this case, 1.1.1.127.

Perfect.

Thanks Alain.

Review Cisco Networking for a $25 gift card