OSPF Areas Types, OSPF Router Types & OSPF Route Types

Unlock Best Pricing with In-stock, Ready-to-Ship Products

OSPF is a link state routing protocol that updates the routing table only when network changes occur, rather than at a predefined interval. OSPF supports variable length subnet masks (VLSM) and route summarization.

Watch the video to learn OSPF:

OSPF routers and links are grouped logically into areas that are identified by assigned numbers. All OSPF networks have at least one area with the default being area 0. If more than one area exists, area 0 is defined as the backbone area and is used to connect all other areas. Each area has its own link state databases.OSPF Router Types

OSPF Areas Types

Normal Areas: These areas can either be standard areas or transit (backbone) areas. Standard areas are defined as areas that can accept intra-area, inter-area and external routes. The backbone area is the central area to which all other areas in OSPF connect.

Note: Intra-area routes refer to updates that are passed within the area. Inter-area routes refer to updates that are passed between areas. External routes refer to updates passed from another routing protocol into the OSPF domain by the Autonomous System Border Router (ASBR).

Stub Areas: These areas do not accept routes belonging to external autonomous systems (AS); however, these areas have inter-area and intra-area routes. In order to reach the outside networks, the routers in the stub area use a default route which is injected into the area by the Area Border Router (ABR). A stub area is typically configured in situations where the branch office need not know about all the routes to every other office, instead it could use a default route to the central office and get to other places from there. Hence the memory requirement of the leaf node routers is reduced, and so is the size of the OSPF database.

To define an area as a stub area, use the OSPF router configuration command, area <area id> stub

Totally Stub Areas: These areas do not allow routes other than intra-area and the default routes to be propagated within the area. The ABR injects a default route into the area and all the routers belonging to this area use the default route to send any traffic outside the area.

To define a totally stub area; use the OSPF router configuration command, area <area id> stub no-summary, on the ABR.

NSSA: This type of area allows the flexibility of importing a few external routes into the area while still trying to retain the stub characteristic. Assume that one of the routers in the stub area is connected to an external AS running a different routing protocol, it now becomes the ASBR, and hence the area can no more be called a stub area. However, if the area is configured as a NSSA, then the ASBR generates a NSSA external link-state advertisement (LSA) (Type-7) which can be flooded throughout the NSSA area. These Type-7 LSAs are converted into Type-5 LSAs at the NSSA ABR and flooded throughout the OSPF domain

To define a NSSA, use the OSPF router configuration command, area <area id> nssa no-summary.

For more information on NSSA, refer to OSPF Not-So-Stubby Area.

 

Normal, Stub, Totally Stub and NSSA Area Differences:

Restriction
Normal None
Stub No Type 5 AS-external LSA allowed
Totally Stub No Type 3, 4 or 5 LSAs allowed except the default summary route
NSSA No Type 5 AS-external LSAs allowed, but Type 7 LSAs that convert to Type 5 at the NSSA ABR can traverse
NSSA Totally Stub No Type 3, 4 or 5 LSAs except the default summary route, but Type 7 LSAs that convert to Type 5 at the NSSA ABR are allowed

Refer to the Types of OSPF Areas section of How Does OSPF Generate Default Routes? to learn more about different types of areas.

 

OSPF Router Types

Internal Router: Responsible for maintaining a current and accurate database of subnets within the area. Forwards data to other networks using the shortest path.

Backbone Router: Has an interface connected to the backbone (Area 0).

Area Border Router (ABR): Has interfaces in multiple areas with at least one interface in area 0. Connects other areas to the backbone and maintains routing information for each connected area.

Autonomous System Boundary Router (ASBR): Router located between OSPF autonomous system and a non-OSPF network.

Used to redistribute routing information between networks.

Must reside in a non-stub area. Also, a router becomes an ASBR when OSPF is redistributing from other routing protocols, including static routes, and it may reside in a pure OSPF network.

OSPF LSA Types

Type 1: Router link advertisements generated by each router for each area it belongs to. Flooded to a single area only (intra-area route). In a multi-area OSPF network, routes, originated within an area, are known by the routers in the same area as Intra-Area routes. These routes are flagged as O in the “show ip route” command output.

Type 2: Network link advertisements generated by designated routers describing the set of routers attached to a particular network. Flooded to the area that contains the network (intra-area route). When a route crosses an OSPF Area Border Router (ABR), the route is known as an OSPF Inter-Area route. These routes are flagged as O IA in the “show ip route” command output.

Both Intra and Inter-Area routes are also called OSPF Internal routes, as they are generated by OSPF itself, when an interface is covered with the OSPF network command.

Type 3/4: Summary link advertisements generated by ABRs describing inter-area routes. Type 3 describes routes to networks and is used for summarization. The “default-information originate” is also Type 3. Type 4 describes routes to the ASBR (interarea summary route).

Type 5: Generated by the ASBR and describes links external to the Autonomous System (AS). These are the redistributed (from other routing protocols including static routes) routes. Flooded to all areas except stub areas (external route). Routes which were redistributed into OSPF, such as ConnectedStatic, or other Routing Protocol, are known as External Type-2 or External Type-1. These routes are flagged as O E2 or O E1 in the “show ip route” command output.

Type 6: Group membership link entry generated by multicast OSPF routers.

Type 7: NSSA external routes generated by ASBR. Only flooded to the NSSA. External routes injected internally by ASBRs within each POP (Areas other than Area 0) are LSAs of type 7. The ABR between will translate LASs type 7 to LSAs type 5 from each POP/Area to Area 0 (external route). When an area is configured as a Not-So-Stub Area (NSSA), and routes are redistributed into OSPF, the routes are known asNSSA external type 2 or NSSA external type 1. These routes are flagged as O N2 or O N1 in the “how ip route” command output.

OSPF Route Types

There are several types of OSPF routes:

Intra-Area: In a multiarea OSPF network, routes, originated within an area, are known by the routers in the same area as Intra-Area routes. These routes are flagged as O in the show ip route command output..

Inter-Area: When a route crosses an OSPF Area Border Router (ABR), the route is known as an OSPF Inter-Area route. These routes are flagged as O IA in the show ip route command output.

Both Intra and Inter-Area routes are also called OSPF Internal routes, as they are generated by OSPF itself, when an interface is covered with the OSPF network command.

External Routes: They fall under two categories, External Type-1 and External Type-2. The difference between the two is in the way the cost (metric) of the route is being calculated. The cost of a Type-2 route is always the external cost, irrespective of the interior cost to reach that route. A Type-1 cost is the addition of the external cost and the internal cost used to reach that route. A Type-1 route is always preferred over a Type-2 route for the same destination.

External Type-2 or External Type-1—Routes which were redistributed into OSPF, such as Connected, Static, or other Routing Protocol, are known as External Type-2 or External Type-1. These routes are flagged as O E2 or O E1 in the show ip route command output. External Type-2 is the default.

NSSA external type 2 or NSSA external type 1: When an area is configured as a Not-So-Stub Area (NSSA), and routes are redistributed into OSPF, the routes are known as NSSA external type 2 or NSSA external type 1. These routes are flagged as O N2 or O N1 in the show ip route command output.

OSPF Preferred Route Decision Order

According to section 11 of RFC 2328 , the order of preference for OSPF routes is:

– intra-area routes, O

– interarea routes, O IA

– external routes type 1, O E1

– external routes type 2, O E2

This rule of preference cannot be changed. However, it applies only within a single OSPF process. If a router is running more than one OSPF process, route comparison occurs. With route comparison, the metrics and administrative distances (if they have been changed) of the OSPF processes are compared. Route types are disregarded when routes supplied by two different OSPF processes are compared.

Realizing where each component of an OSPF network fits is the first step to understanding how to effectively use OSPF. Cisco provides lots of OSPF design information and advice. Check out the following links for more information:

– Cisco’s OSPF design guide

– Configuring OSPF (Network Protocols Configuration Guidel)

– OSPF Commands (from Cisco IOS Command Reference Ver 12.4)

More Related OSPF Tutorials:

How to Troubleshoot OSPF?

How to Configure OSPF in a Single Area?

OSPF, How to Configure OSPF in the Cisco IOS?

Share This Post

Post Comment