A stub area is a non-transit area. In other words, an area that does not originate or propagate external routes. AS-external-LSAs are not flooded into the stub area; routing to AS external networks is based on a single per-area default route. This reduces the link-state-database size and memory requirements for routers within stub areas.
Handy for reducing routing table size, a stub area is a “dead-end” in which there is no other way to enter or exit except through an Area Border Router (ABR). No ASE (Autonomous System External) or NSSA routes are permitted in a stub area. Each router in a stub area must specify that they are members of the stub area. When specifying that the ABR is a member of the stub area, the ABR will inject a default route into the area.
Routing to external designations from stub areas is based on a default route injected by a stub area‘s ABR. A default route is automatically created by the stub area‘s ABR. This default route is injected into the stub area to enable other stub routers within the stub area to reach any external routes that are no longer inserted into the stub area.
A stub area can be configured such that the ABR is prevented from sending type 3 summary LSAs into the stub area using the no-summary option. In this case, all destinations outside of the stub area are represented by means of a default route.
There are a couple of restrictions on the use of stub areas. Virtual-links cannot be configured through stub areas, and AS boundary routers cannot be placed internal to stub areas.
Use the area stub command in OSPF router configuration command mode to configure an area as a stub.
A cost value can be set for the default route that is sent into a stub area by an ABR. Configuration of the stub area default route cost is restricted to the ABR attached to this stub area.
Use the area default-cost command in OSPFv3 router configuration command mode on the ABR attached to this stub area to configure the stub area default route cost.