OSPFv3 Prefix Suppression

Prefix Suppression, as explained in this OSPFv2 lesson is a method to get rid of transit prefixes. Here’s a quick example:

Ospfv3 Transit Prefixes Example

Above we have three routers running OSPFv3. H1 and H2 are host devices, and the only thing we care about in this topology is having connectivity between these two hosts. This means R3 needs to know about prefix 2001:DB8:0:3::/64 and R3 about prefix 2001:DB8:0:1::/64.

We also have prefix 2001:DB8:0:12::/64 in between R1 and R2 and prefix 2001:DB8:0:23::/64 in between R2 and R3 but we don’t really need to have these prefixes in our routing tables, those are only transit prefixes. Unlike OSPFv2 where you do have to configure IP addresses on your transit links, OSPFv3 doesn’t need this. You only need link-local IPv6 addresses in order for OSPFv3 to establish a neighbor adjacency so we could just remove these two prefixes.

However, if you do have configured transit prefixes on your routers and you have a reason to keep them…you can still suppress them with prefix suppression.

Prefix suppression in OSPFv3 is much simpler than OSPFv2. In OSPFv2, prefixes are found in the router (type 1) LSA and the network (type 2) LSA.

OSPFv3 separates topology and prefix information. LSA type 1 and 2 are used for topology information and the new link (type 8) LSA and intra area prefix (type 9) LSA contain addressing information.

The link LSA associates a list of IPv6 addresses to a link and has a link-local flooding scope. The intra area prefix LSA associates a list of IPv6 addresses with a router by referencing a router LSA or with a broadcast/NBMA network by referencing a network LSA.

When the router refers a network LSA, the prefixes from the link LSA are copied into the intra area prefix LSA by the DR.

To hide prefixes, OSPFv3 removes information from the link LSA and intra area prefix LSA.

Configuration

To demonstrate OSPFv3 prefix suppression, I use the following topology:

Ospfv3 Prefix Suppression Topology

In the topology above, each router has a loopback interface. The goal is that each router should be able to ping any of the other loopback interfaces. I also added two transit prefixes:

  • 2001:DB8:0:123::/64 in between R1, R2 and R3
  • 2001:DB8:0:34::/64 in between R3 and R4

R1 and R2 will learn about 2001:DB8:0:34/64 and R4 will learn 2001:DB8:0:123::/64. Both prefixes are unnecessary.

Since R3 and R4 are only connected to each other, this link has been configured as an OSPF point-to-point network type.

Configurations

Want to take a look for yourself? Here you will find the startup configuration of each device.

R1

hostname R1
!
ipv6 unicast-routing
ipv6 cef
!
interface Loopback0
 ipv6 address 2001:DB8:1:1::1/128
 ipv6 ospf 1 area 0
!
interface GigabitEthernet0/1
 ipv6 address 2001:DB8:0:123::1/64
 ipv6 enable
 ipv6 ospf 1 area 0
!
ipv6 router ospf 1
 router-id 1.1.1.1
!
end

R2

hostname R2
!
ipv6 unicast-routing
ipv6 cef
!
interface Loopback0
 ipv6 address 2001:DB8:2:2::2/128
 ipv6 ospf 1 area 0
!
interface GigabitEthernet0/0
 ip address 10.255.2.72 255.255.0.0
!
interface GigabitEthernet0/1
 ipv6 address 2001:DB8:0:123::2/64
 ipv6 enable
 ipv6 ospf 1 area 0
!
ipv6 router ospf 1
 router-id 2.2.2.2
!
end

R3

hostname R3
!
ipv6 unicast-routing
ipv6 cef
!
interface Loopback0
 ipv6 address 2001:DB8:3:3::3/128
 ipv6 ospf 1 area 0
!
interface GigabitEthernet0/1
 ipv6 address 2001:DB8:0:123::3/64
 ipv6 enable
 ipv6 ospf 1 area 0
!
interface GigabitEthernet0/2
 ipv6 address 2001:DB8:0:34::3/64
 ipv6 enable
 ipv6 ospf 1 area 0
 ipv6 ospf network point-to-point
!
ipv6 router ospf 1
 router-id 3.3.3.3
!
end

R4

hostname R4
!
ipv6 unicast-routing
ipv6 cef
!
interface Loopback0
 ipv6 address 2001:DB8:4:4::4/128
 ipv6 ospf 1 area 0
!
interface GigabitEthernet0/1
 ipv6 address 2001:DB8:0:34::4/64
 ipv6 enable
 ipv6 ospf 1 area 0
 ipv6 ospf network point-to-point
!
ipv6 router ospf 1
 router-id 4.4.4.4
!
end

Prefix Suppression Disabled

Prefix suppression is disabled by default. Let’s take a look at the routing tables of R1, R2, and R4:

R1#show ipv6 route ospf 

O   2001:DB8:0:34::/64 [110/2]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1
O   2001:DB8:2:2::2/128 [110/1]
     via FE80::F816:3EFF:FE2A:1133, GigabitEthernet0/1
O   2001:DB8:3:3::3/128 [110/1]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1
O   2001:DB8:4:4::4/128 [110/2]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1
R2#show ipv6 route ospf 

O   2001:DB8:0:34::/64 [110/2]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1
O   2001:DB8:1:1::1/128 [110/1]
     via FE80::F816:3EFF:FEC6:CDB1, GigabitEthernet0/1
O   2001:DB8:3:3::3/128 [110/1]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1
O   2001:DB8:4:4::4/128 [110/2]
     via FE80::F816:3EFF:FEE3:9BA6, GigabitEthernet0/1

Above we see that R1 and R2 have learned 2001:DB8:0:34::/64. Here is R4:

R4#show ipv6 route ospf 

O   2001:DB8:0:123::/64 [110/2]
     via FE80::F816:3EFF:FE4A:6854, GigabitEthernet0/1
O   2001:DB8:1:1::1/128 [110/2]
     via FE80::F816:3EFF:FE4A:6854, GigabitEthernet0/1
O   2001:DB8:2:2::2/128 [110/2]
     via FE80::F816:3EFF:FE4A:6854, GigabitEthernet0/1
O   2001:DB8:3:3::3/128 [110/1]
     via FE80::F816:3EFF:FE4A:6854, GigabitEthernet0/1

R4 has 2001:DB8:0:123::/64 in its routing table.

Link LSA

Prefix information is stored in the link LSA and the intra area prefix LSA. Let’s look at R3, our DR (Designated Router) in this topology. First, we’ll take a look at the link LSA:

R3#show ipv6 ospf database link self-originate   

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

                Link (Type-8) Link States (Area 0)

  LS age: 599
  Options: (V6-Bit, E-Bit, R-Bit, DC-Bit)
  LS Type: Link-LSA (Interface: GigabitEthernet0/2)
  Link State ID: 4 (Interface ID)
  Advertising Router: 3.3.3.3
  LS Seq Number: 80000003
  Checksum: 0xA820
  Length: 56
  Router Priority: 1
  Link Local Address: FE80::F816:3EFF:FE4A:6854
  Number of Prefixes: 1
  Prefix Address: 2001:DB8:0:34::
  Prefix Length: 64, Options: None

  LS age: 599
  Options: (V6-Bit, E-Bit, R-Bit, DC-Bit)
  LS Type: Link-LSA (Interface: GigabitEthernet0/1)
  Link State ID: 3 (Interface ID)
  Advertising Router: 3.3.3.3
  LS Seq Number: 80000003
  Checksum: 0x9525
  Length: 56
  Router Priority: 1
  Link Local Address: FE80::F816:3EFF:FEE3:9BA6
  Number of Prefixes: 1
  Prefix Address: 2001:DB8:0:123::
  Prefix Length: 64, Options: None

Above we see the two transit prefixes. I highlighted the interesting part. Once prefix suppression is enabled, this will be removed from the link LSA. Below is R4:

R4#show ipv6 ospf database link self-originate 

            OSPFv3 Router with ID (4.4.4.4) (Process ID 1)

                Link (Type-8) Link States (Area 0)

  LS age: 646
  Options: (V6-Bit, E-Bit, R-Bit, DC-Bit)
  LS Type: Link-LSA (Interface: GigabitEthernet0/1)
  Link State ID: 3 (Interface ID)
  Advertising Router: 4.4.4.4
  LS Seq Number: 80000003
  Checksum: 0x4C21
  Length: 56
  Router Priority: 1
  Link Local Address: FE80::F816:3EFF:FEAF:7D32
  Number of Prefixes: 1
  Prefix Address: 2001:DB8:0:34::
  Prefix Length: 64, Options: None

R4 shows information about 2001:DB8:0:34::/64. This information will be removed once prefix suppression is enabled.

Intra Area Prefix LSA

Let’s look at the intra area prefix LSA. Let’s take a look at R3, our DR:

R3#show ipv6 ospf database prefix self-originate 

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

                Intra Area Prefix Link States (Area 0)

  LS age: 614
  LS Type: Intra-Area-Prefix-LSA
  Link State ID: 0
  Advertising Router: 3.3.3.3
  LS Seq Number: 80000002
  Checksum: 0x54B5
  Length: 64
  Referenced LSA Type: 2001
  Referenced Link State ID: 0
  Referenced Advertising Router: 3.3.3.3
  Number of Prefixes: 2
  Prefix Address: 2001:DB8:3:3::3
  Prefix Length: 128, Options: LA, Metric: 0
  Prefix Address: 2001:DB8:0:34::
  Prefix Length: 64, Options: None, Metric: 1

  LS age: 614
  LS Type: Intra-Area-Prefix-LSA
  Link State ID: 3072
  Advertising Router: 3.3.3.3
  LS Seq Number: 80000001
  Checksum: 0xD0C2
  Length: 44
  Referenced LSA Type: 2002
  Referenced Link State ID: 3
  Referenced Advertising Router: 3.3.3.3
  Number of Prefixes: 1
  Prefix Address: 2001:DB8:0:123::
  Prefix Length: 64, Options: None, Metric: 0

Above we find information about 2001:DB8:0:34::/64 and 2001:DB8:0:123::/64. The information I highlighted will be removed by prefix suppression. Let’s also take a look at R4:

R4#show ipv6 ospf database prefix self-originate 

            OSPFv3 Router with ID (4.4.4.4) (Process ID 1)

                Intra Area Prefix Link States (Area 0)

  LS age: 683
  LS Type: Intra-Area-Prefix-LSA
  Link State ID: 0
  Advertising Router: 4.4.4.4
  LS Seq Number: 80000004
  Checksum: 0xB844
  Length: 64
  Referenced LSA Type: 2001
  Referenced Link State ID: 0
  Referenced Advertising Router: 4.4.4.4
  Number of Prefixes: 2
  Prefix Address: 2001:DB8:4:4::4
  Prefix Length: 128, Options: LA, Metric: 0
  Prefix Address: 2001:DB8:0:34::
  Prefix Length: 64, Options: None, Metric: 1

Once prefix suppression is enabled, you’ll see that the information about transit prefix 2001:DB8:0:34::/64 will be removed.

Prefix Suppression Enabled

Time to enable prefix suppression. I use the global command on all routers:

R1, R2, R3 & R4
(config)#ipv6 router ospf 1
(config-rtr)#prefix-suppression

That’s it.

You can also enable prefix suppression with the interface command ipv6 ospf prefix-suppression.

Let’s start by checking the routing tables of R1, R2, and R4:

We're Sorry, Full Content Access is for Members Only...

If you like to keep on reading, Become a Member Now! Here is why:

  • Learn any CCNA, CCNP and CCIE R&S Topic. Explained As Simple As Possible.
  • Try for Just $1. The Best Dollar You've Ever Spent on Your Cisco Career!
  • Full Access to our 660 Lessons. More Lessons Added Every Week!
  • Content created by Rene Molenaar (CCIE #41726)

505 Sign Ups in the last 30 days

satisfaction-guaranteed
100% Satisfaction Guaranteed!
You may cancel your monthly membership at any time.
No Questions Asked!

Tags:


Forum Replies

  1. Hi Rene

    Could you clarify the differences between this and OSPFv3 Prefix Suppression?

    I believe the main difference is that type 8’s and 9’s are suppressed rather than type 1 or 2’s.

    Are stub’s advertised as /128’s?

    Also how does OSPF detect that a prefix is part of a transit network?

  2. Hi @chrisnewnham17,

    In OSPFv3, there is no prefix information in LSA type 1 and 2 anymore, you can find those in LSA type 8 and 9 so yes, OSPFv3 prefix suppression removes it from LSA type 8 and 9.

    About the prefix / transit network. Here’s a quick example with three routers connected like this:

    R1-R2-R3

    All routers are in area 0 and R3 is the DR:

    R3#show ipv6 ospf database prefix self-originate  
    
                OSPFv3 Router with ID (3.3.3.3) (Process ID 1)
    
                    Intra Area Prefix Link States (Area 0)
    
      LS age: 8
      LS Type: Intra-Area-Prefix-LSA
      Li
    ... Continue reading in our forum

  3. Hello Ruwan

    There are two types of LSAs that we have to deal with in this lesson: The Router LSA, that is a type 1 LSA that contains prefix information about the 192.168.30.0/24 network, and the Network LSA< that is a type 2 LSA that contains prefix information about the 192.168.123.0/24 subnet.

    If you notice, in each of the LSAs described, the only networks th

    ... Continue reading in our forum

  4. Hello Nitay

    This is an excellent question. Yes, even though network 3.3.3.3 is considered a stub network in the LSDB it is not removed by the prefix suppression feature. However, the 192.168.34.0 network which is also indicated as a stub network in the LSDB is removed.

    The difference between the two is that 192.168.34.0 is also indicated as a point to point network with a neighboring router ID of 4.4.4.4 and a next hop ID of 192.168.34.3. So the router knows that although the network itself is configured as a stub network when viewed as a destination, it is

    ... Continue reading in our forum

  5. Thanks you very much,

    That was realy helpful but I have another question:

    how would R3 advertise his Network LSA to R4?
    From the lesson’s statement it says

    “The prefix isn’t advertised directly in LSA type 2 but with the IP address of the DR and the subnet mask, the router can calculate what prefix we are using (192.168.123.0/24).”

    but there is also a statement which says that the Network LSA will do be advertised so maybe I didn’t understand that right, could you explain me what the quote meant to say?

3 more replies! Ask a question or join the discussion by visiting our Community Forum