Configuring a non-backbone area as a stub area can reduce routing entries in the area in an AS does not transmit routes learned from other areas in the AS or AS external routes. This reduces bandwidth and storage resource consumption.
The number of LSAs can be reduced by partitioning an AS into different areas. To reduce the number of entries in the routing table and the number of LSAs to be transmitted in a non-backbone area, configure the non-backbone area on the border of the AS as a stub area.
Configuring a stub area is optional. A stub area generally resides on the border of an AS. For example, a non-backbone area with only one ABR can be configured as a stub area. In a stub area, the number of entries in the routing table and the amount of routing information to be transmitted greatly decrease.
Note the following points when configuring a stub area:
Before configuring a stub area, complete the following tasks:
Configuring IP addresses for interfaces to ensure that neighboring routers are reachable at the network layer
The system view is displayed.
The OSPF process view is displayed.
The OSPF area view is displayed.
The specified area is configured as a stub area.
The ABR is prevented from sending Type 3 LSAs to the stub area.
The ABR is prevented from checking the neighbor status when it generates a default Type 3 LSA and advertises it to the stub area.
A cost is set for the default route advertised to the stub area.
To ensure the reachability of AS external routes, the ABR in the stub area generates a default route and advertises it to non-ABR routers in the stub area.
The configuration is committed.
After configuring the stub area, verify the configuration.
Run the display ospf [ process-id ] lsdb command to check OSPF LSDB information.
Run the display ospf [ process-id ] peer command to check information about OSPF neighbors.
Run the display ospf [ process-id ] routing command to check information about the OSPF routing table.
When routers are in a common area, there are AS external routes in the routing table. After the area where the router resides is configured as a stub area, AS external routes no longer exist in the routing table, and the ASE field is displayed as 0 in the command output.