OSPF LSA Types and Their Functions.
In this blog, we will discuss OSPF LSA types and how OSPF uses Link-State Advertisements (LSAs) to exchange information about the network topology between routers. A router's Link-State Database stores received LSAs, and OSPF uses the Shortest Path First (SPF) algorithm to determine the best routes for each network once the LSDBs between routers are synchronized. It's important to understand that LSAs are route-related data sent inside Link State Update (LSU) packets. Therefore, it's essential for any network engineer to comprehend how LSAs are contained within an LSU. Let's delve into OSPF LSA types, but first, we need to have a basic understanding of Link State Advertisement (LSA).
What is LSA in OSPF?
LSA stands for "Link State Advertisement“ in OSPF (Open Shortest Path First). In the OSPF Protocol, routers exchange information about the network topology by sharing LSAs. LSAs are packets containing details about the router's interfaces, neighboring routers, and network links. Each router in an OSPF network generates LSAs and sends them to all other routers within the same OSPF area. LSAs enable routers to create a synchronized view of the network, calculate shortest paths, and maintain routing tables for efficient packet forwarding.
OSPF LSA Types – Quick Overview
Here is a quick overview of OSPF LSA types that we will be discussing further –
Functions of LSAs in OSPF
OSPF uses LSA exchanges to create multiple paths throughout the network. The following are the activities in which LSAs are used:
1. Discovering neighbors
2. Electing a DR and BDR
3. Establishing adjacencies and synchronizing databases
LSAs act as the building blocks of the OSPF LSDB. Individually, they act as database records, and when combined, they describe the entire topology of an OSPF area. There are several types of OSPF network LSAs, but not all are in use.
OSPF LSA Types
Now, let's discuss each OSPF LSA type one by one.
OSPF LSA Type 1 – OSPF Router LSA
Type 1 LSAs are generated by IRs. They carry the information of all directly connected routes, and these LSAs always stay within the area. The router-id of the originating router can be found in the link-state id field. Once the routing is done on the OSPF router, it generates the Type-1 LSA. You can use the following command to verify the LSA:
#SHOW IP OSPF DATABASE
This will display an LSA Type-1 like the one in the OSPF database table.
OSPF LSA Type 2 – Network LSA
The DR generates it on a multi-access network segment and always stays within the area when the neighborship is formed between two routers. Same you can verify in the database table of OSF.
Summary LSA
Using a summary prefix, the ABRs produce it into all other areas in order to summarise the area to which it is directly connected and to promote inter-area router information to other areas to which it is connected.
Summary LSAs are further classified into 2 types:
OSPF LSA Type 3 – Summary LSA
Routes to destinations in other areas within the OSPF network, i.e., inter-area destinations (O-IA). Basically, when multi-areas in OSPF are configured then, only this LSA type is generated in OSPF.
OSPF LSA Type 4 – ASBR Summary LSA
LSA Type 5 (ASBR External LSA) packets are created by the ASBR in order to advertise externally redistributed routes into the OSPF’s AS. They describe the routes to the destinations external to the OSPF network. These LSAs are forwarded to all the connected and redistributed areas.
OSPF LSA Type 5 – AS External LSA
The ASBR generates LSA Type 5 (ASBR External LSA) packets to advertise external redistributed routes into the OSPF’s AS. They describe the routes to the destinations external to the OSPF network. These LSAs are forwarded to all the connected and redistributed areas.
OSPF LSA Type 6 – Multicast OSPF LSA
Not supported and not used by OSPF. Cisco iOS doesn’t support this LSA type. They use (PIM) Protocol independent Multicast.
OSPF LSA Type 7 – NSSA LSA
It is produced by an ASBR inside an NSSA to characterize routes that have been redistributed there. As LSA 7 exits the NSSA, it is converted into LSA 5.
NSSA area routers will be type 7 LSAs, but for other areas (other than NSSA), ABRs will convert them into type 5, which are easily understandable and acceptable in these areas.
OSPF LSA Type 8 – External attributes LSA
LSA Type 8 carries information about external routes, including their destination network addresses, path costs, and external route tags. When an OSPF router receives routing information from an external routing protocol, such as BGP (Border Gateway Protocol), it generates an LSA Type 5 called External LSA.
The remaining 3 LSA types are opaque. We have also mentioned some information about them.
OSPF LSA Type 9 – OSPF Link Scope Opaque (OSPFv2)
OSPF LSA Type 9, also known as OSPF Link Scope Opaque, is used in OSPFv2 to carry non-standardized or proprietary information within the OSPF domain. LSA Type 9 enables OSPF routers to exchange opaque data, allowing for custom extensions and additional functionality beyond the standard OSPF protocol.
OSPF LSA Type 10 – OSPF Area Scope Opaque LSA
OSPF LSA Type 10, known as OSPF Area Scope Opaque LSA, is used to carry opaque data specific to a particular OSPF area, enabling the transmission of custom information within that specific area.
OSPF LSA Type 11 – OSPF AS (Autonomous System) Scope Opaque LSA
OSPF LSA Type 11, referred to as OSPF AS (Autonomous System) Scope Opaque LSA, is utilized to transmit opaque data throughout the entire OSPF Autonomous System, allowing the exchange of custom information across the entire OSPF domain.
These are the various OSPF LSA types. Now let’s get a hold of another important topic OSPF LSA Header.
OSPF LSA Header
LINK STATE ADVERTISEMENT (LSA) PACKET STRUCTURE (WITHIN A LINK STATE UPDATE – LSU)
All the data required to exchange network information inside an OSPF network is contained in the header of each LSA packet. This graphic will allow us to understand what data is contained in an LSA packet.
The 20-byte LSA header section contains the following fields:
Frequently Asked Questions
Q1 – What is a LSA in OSPF?
LSAs, or Link State Advertisements, are multicast messages exchanged among routers within the OSPF domain. Internal routers utilize them to notify the DR/BDR routers about any modifications or updates.
Q2 – What are the LSA types in OSPF?
There are 11 LSA types which are – Router LSA, Network LSA, Summary LSA, Summary ASBR LSA, Autonomous system external LSA, Multicast OSPF LSA, Not-so-stubby area LSA, External attribute LSA, and 3 Opaque LSA Types.
Q3 – What is Type 3 LSA in OSPF?
Type 3 LSA in OSPF (Open Shortest Path First) is known as the Network Summary LSA. It is responsible for advertising summarized network information to routers within the same OSPF area, enabling efficient routing and reducing the size of the routing tables.
Q4 – What is OSPF Type 4 LSA?
OSPF LSA Type 4, OSPF ASBR Summary LSA, is used to advertise the summary information of an Autonomous System Boundary Router (ASBR) within an OSPF area. It provides a summarized view of the ASBR’s external routes, enabling efficient routing decisions within the OSPF domain.
Conclusion
In this blog, we have discussed everything related to OSPF LSA types. OSPF is a part of our CCNA and CCNP Encor training. For a more detailed explanation, you can check out the OSPF BGP Training. In conclusion, OSPF (Open Shortest Path First) utilizes various Link State Advertisements (LSAs) to exchange critical routing information within the OSPF domain.
Each LSA type serves a specific purpose, such as advertising network topology, summarizing routes, or carrying custom opaque data. Understanding the different OSPF LSA types is essential for network administrators to effectively design, optimize, and maintain OSPF-based networks, enabling efficient routing and seamless connectivity across the entire OSPF infrastructure.Training. In conclusion, OSPF (Open Shortest Path First) utilizes various Link State Advertisements (LSAs) to exchange critical routing information within the OSPF domain.
Each LSA type serves a specific purpose, such as advertising network topology, summarizing routes, or carrying custom opaque data. Understanding the different OSPF LSA types is essential for network administrators to effectively design, optimize, and maintain OSPF-based networks, enabling efficient routing and seamless connectivity across the entire OSPF infrastructure.