< Home

Principle of OSPFv3

Running on IPv6, OSPFv3 (defined in RFC 2740) is an independent routing protocol whose functions are enhanced on the basis of OSPFv2.

Formats of OSPFv3 Packets

Table 1 Formats of OSPFv3 Packets
Packet Type Description
Hello message Hello messages are sent regularly to discover and maintain OSPFv3 neighbor relationships.
Database Description (DD) packet A DD packet contains the summary of the local LSDB. It is exchanged between two OSPFv3 routers to update the LSDBs.
Link State Request (LSR) packet

LSR packets are sent to the neighbor to request the required LSAs.

An OSPFv3 router sends LSR packets to its neighbor only after they exchange DD packets.

Link State Update (LSU) packet The LSU packet is used to transmit required LSAs to the neighbor.
Link State Acknowledgment (LSAck) packet The LSAck packet is used to acknowledge the received LSA packets.

LSA Type

Table 2 LSA Type
LSA Type Description
Router-LSA(Type1) Generated by a router for each area to which an OSPFv3 interface belongs, the router LSA describes the status and costs of links of the router and is advertised in the area where the OSPFv3 interface belongs.
Network-LSA(Type2) Generated by a designated router (DR), the network LSA describes the link status and is broadcast in the area that the DR belongs to.
Inter-Area-Prefix-LSA(Type3) Generated on the area border router (ABR), an inter-area prefix LSA describes the route of a certain network segment within the local area and is used to inform other areas of the route.
Inter-Area-Router-LSA(Type4) Generated on the ABR, an inter-area router LSA describes the route to the autonomous system boundary router (ASBR) and is advertised to all related areas except the area that the ASBR belongs to.
AS-external-LSA(Type5) Generated on the ASBR, the AS-external LSA describes the route to a destination outside the AS and is advertised to all areas except the stub area and NSSA area.
NSSA-LSA (Type7) Describes routes to a destination outside the AS. It is generated by an ASBR and advertised in NSSAs only.
Link-LSA(Type8) Each router generates a link LSA for each link. A link LSA describes the link-local address and IPv6 address prefix associated with the link and the link option set in the network LSA. It is transmitted only on the link.
Intra-Area-Prefix-LSA(Type9)

Each router or DR generates one or more intra-area prefix LSAs and transmits it in the local area.

  • An LSA generated on a router describes the IPv6 address prefix associated with the router LSA.
  • An LSA generated on a DR describes the IPv6 address prefix associated with the network LSA.

Router Type

Figure 1 Router type

Table 3 Router types and descriptions
Router Type Description
Internal router All interfaces on an internal router belong to the same OSPFv3 area.
Area border router (ABR)

An ABR can belong to two or more areas, but one of the areas must be a backbone area.

An ABR is used to connect the backbone area and the non-backbone areas. It can be physically or logically connected to the backbone area.

Backbone router

At least one interface on a backbone router belongs to the backbone area.

All ABRs and internal routers in Area 0, therefore, are backbone routers.

AS boundary router (ASBR)

A router that exchanges routing information with other ASs is called an ASBR.

An ASBR may not locate on the boundary of an AS. It can be an internal router or an ABR. If an OSPFv3 router imports the external routing information, the router is an ASBR.

OSPFv3 Route Type

Inter-area routes and intra-area routes describe the network structure of an AS. External routes describe how to select a route to the destination outside an AS. OSPFv3 classifies the imported AS external routes into Type 1 routes and Type 2 routes.

Table 4 lists route types in a descending order of priority.

Table 4 Types of OSPFv3 routes
Route Type Description
Intra Area Intra-area routes
Inter Area Inter-area routes
Type1 external routes

Because of the high reliability of Type 1 external routes, the calculated cost of external routes is equal to that of AS internal routes, and can be compared with the cost of OSPFv3 routes.

That is, the cost of a Type1 external route equals the cost of the route from the router to the corresponding ASBR plus the cost of the route from the ASBR to the destination address.

Type2 external routes

Because of the low reliability of Type2 external routes, the cost of the route from the ASBR to a destination outside the AS is considered far greater than the cost of any internal path to an ASBR.

Therefore, OSPFv3 only takes the cost of the route from the ASBR to a destination outside the AS into account when calculating route costs. That is, the cost of a Type2 external route equals the cost of the route from the ASBR to the destination of the route.

Area

When a large number of routers run OSPFv3, link state databases (LSDBs) become very large and require a large amount of storage space. Large LSDBs also complicate shortest path first (SPF) computation and are computationally intensive for the routers. Network expansion causes the network topology to change, which results in route flapping and frequent OSPFv3 packet transmission. When a large number of OSPFv3 packets are transmitted on the network, bandwidth usage efficiency decreases. Each change in the network topology causes all routers on the network to recalculate routes.

OSPFv3 resolves this problem by partitioning an AS into different areas. An area is regarded as a logical group, and each group is identified by an area ID. A router, not a link, resides at the border of an area. A network segment or link can belong only to one area. An area must be specified for each OSPFv3 interface.

OSPFv3 areas include common areas, stub areas, and not-so-stubby areas (NSSAs), as described in Table 5.

Table 5 OSPF areas
Area Type Description Notes
Common area

By default, OSPFv3 areas are defined as common areas. Common areas include:

  • Standard area: transmits intra-area, inter-area, and external routes.
  • Backbone area: connects to all other OSPFv3 areas and transmits inter-area routes. The backbone area is represented by area 0. Routes between non-backbone areas must be forwarded through the backbone area.
  • The backbone area must have all its devices connected.
  • All non-backbone areas must remain connected to the backbone area.
Stub area

A stub area is a non-backbone area with only one ABR and generally resides at the border of an AS. The area border router (ABR) in a stub area does not transmit received AS external routes, which significantly decreases the number of entries in the routing table on the ABR and the amount of routing information to be transmitted. To ensure the reachability of AS external routes, the ABR in the stub area generates a default route and advertises the route to non-ABRs in the stub area.

A totally stub area allows only intra-area routes and ABR-advertised Type 3 link state advertisements (LSAs) carrying a default route to be advertised within the area.

  • The backbone area cannot be configured as a stub area.
  • An autonomous system boundary router (ASBR) cannot exist in a stub area. Therefore, AS external routes cannot be advertised within the stub area.
  • A virtual link cannot pass through a stub area.
NSSA

An NSSA is similar to a stub area. An NSSA does not advertise Type 5 LSAs but can import AS external routes. ASBRs in an NSSA generate Type 7 LSAs to carry the information about the AS external routes. The Type 7 LSAs are advertised only within the NSSA. When the Type 7 LSAs reach an ABR in the NSSA, the ABR translates the Type 7 LSAs into Type 5 LSAs and floods them to the entire AS.

A totally NSSA area allows only intra-area routes to be advertised within the area.

  • ABRs in an NSSA advertise Type 3 LSAs carrying a default route within the NSSA. All inter-area routes are advertised by ABRs.
  • A virtual link cannot pass through an NSSA.

Network Types Supported by OSPFv3

OSPFv3 classifies networks into the following types according to link layer protocols.

Table 6 Types of OSPFv3 networks
Network Type Description
Broadcast

If the link layer protocol is Ethernet or FDDI, OSPFv3 defaults the network type to broadcast.

In this type of networks, the following situations occur:

  • Hello messages, LSU packets, and LSAck packets are transmitted in multicast mode (FF02::5 is the reserved IPv6 multicast address of the OSPFv3 router; FF02::6 is the reserved IPv6 multicast address of the OSPFv3 DR or BDR).
  • DD packets and LSR packets are transmitted in unicast mode.
Non-broadcast Multiple Access (NBMA)

If the link layer protocol is frame relay, ATM, or X.25, OSPFv3 defaults the network type to NBMA.

In this type of networks, protocol packets such as Hello messages, DD packets, LSR packets, LSU packets, and LSAck packets, are transmitted in unicast mode.

Point-to-Multipoint (P2MP)

Regardless of the link layer protocol, OSPFv3 does not default the network type to P2MP. A P2MP network must be forcibly changed from other network types. The common practice is to change a non-fully connected NBMA to a P2MP network.

In this type of networks, the following situations occur:

  • Hello messages are transmitted in multicast mode with the multicast address as FF02::5.
  • Other protocol packets, including DD packets, LSR packets, LSU packets, and LSAck packets, are transmitted in unicast mode.
Point-to-point (P2P)

If the link layer protocol is PPP, or LAPB, OSPFv3 defaults the network type to P2P.

In this type of network, the protocol packets, including Hello messages, DD packets, LSR packets, LSU packets, and LSAck packets, are transmitted to the multicast address FF02::5.

OSPFv3 Route Aggregation

Routing information can be decreased after route aggregation so that the size of routing tables is reduced, which improves the performance of routers.

The procedure for OSPFv3 route aggregation is as follows:

  • Route summarization on an ABR

    An ABR can summarize routes with the same prefix into one route and advertise the summarized route in other areas.

    When sending routing information to other areas, an ABR generates Type 3 LSAs based on IPv6 prefixes. If consecutive IPv6 prefixes exist in an area and route summarization is enabled on the ABR of the area, the IPv6 prefixes can be summarized into one prefix. If there are multiple LSAs that have the same prefix, the ABR summarizes these LSAs and advertises only one summarized LSA. The ABR does not advertise any specific LSAs.

  • Route summarization on an ASBR

    An ASBR can summarize imported routes with the same prefix into one route and then advertise the summarized route to other areas.

    After being enabled with route summarization, an ASBR summarizes imported Type 5 LSAs within the summarized address range. After route summarization, the ASBR does not generate a separate Type 5 LSA for each specific prefix within the configured range. Instead, the ASBR generates a Type 5 LSA for only the summarized prefix. In an NSSA, an ASBR summarizes multiple imported Type 7 LSAs within the summarized address range into one Type 7 LSA.

OSPFv3 Virtual Link

A virtual link refers to a logical channel established between two ABRs through a non-backbone area.

  • A virtual link must be set up on both ends of the link; otherwise, it does not take effect.
  • The transmit area refers to the area that provides an internal route of a non-backbone area for both the ends of the virtual link.

In actual applications, the physical connectivity between non-backbone areas and the backbone area cannot be ensured owing to various limitations. To solve this problem, you can configure OSPFv3 virtual links.

The virtual link is similar to a point-to-point connection between two ABRs. Similar to physical interfaces, the interfaces on the virtual link can be configured with parameters such as the hello interval.

Figure 2 OSPFv3 virtual link

As shown in Figure 2, OSPFv3 packets transmitted between two ABRs are only forwarded by the OSPFv3 devices that reside between the two ABRs. The OSPFv3 devices detect that they are not the destinations of the packets, so they forward the packets as common IP packets.

OSPFv3 Multi-process

OSPFv3 supports multi-process. More than one OSPFv3 process can run on the same router because processes are independent of each other. Route interaction between different OSPFv3 processes is similar to the route interaction between different routing protocols.

An interface of a router belongs to only a certain OSPFv3 process.

Copyright © Huawei Technologies Co., Ltd.
Copyright © Huawei Technologies Co., Ltd.
Next topic >