SPF provides many different ways to customize its operation to fit your network needs. This section discusses route summarization, default routes, stub areas, and virtual links.
OSPF Summarization
Summarization helps all routing protocols scale to larger networks, but OSPF especially benefits because its processes tax the memory and CPU resources of the routers. The SPF algorithm consumes all CPU resources when it runs. Summarization prevents topology changes from being passed outside an area and thus saves routers in other areas from
having to run the SPF algorithm. OSPF’s multiple databases use more memory the larger they are. Summarization decreases the number of routes exchanged, and thus the size of the databases. OSPF can produce summaries within a classful network (VLSM) or summaries of blocks of classful networks (CIDR). There are two types of summarizations:
Inter-area route summarizations are created on the ABR under the OSPF routing process using the area range command. The following command advertises 172.16.0.0/12 from area 1:
Router(config-router)#area 1 range 172.16.0.0 255.240.0.0
External route summarization is done on an ASBR using the summary-address command under the OSPF routing process. The following example summarizes a range of external routes to 192.168.0.0/16 and injects a single route into OSPF.
Router(config-router)#summary-address 192.168.0.0 255.255.0.0
Creating a Default Route
The default route is a special type of summarization; it summarizes all networks down to one route announcement. This provides the ultimate benefit of summarization by reducing routing information to a minimum. There are several ways to use the router IOS to place a default route into OSPF.
The best-known way to produce an OSPF default is to use the defaultinformation command under the OSPF routing process. This command, without the keyword always, readvertises a default route learned from another source into OSPF. If the always keyword is present, OSPF advertises a default even if one does not already exist in the routing table. The metric keyword sets the starting metric for this route.
Router(config-router)#default-information originate [always] [metric metric]
Alternatively, a default summary route can also be produced using the summary-address command or the area range command. These commands cause the router to advertise a default route pointing to itself.
Stub and Not-So-Stubby Areas
Another way to reduce the route information advertised is to make an area a stub area. Configuring an area as a stub area forces its ABR to drop all external (type 5) routes and replaces them with a default route. To limit routing information even more, an area can be made totally stubby using the no-summary keyword on the ABR only. In that case,
all interarea and external routes are dropped by the ABR and replaced by a default route. The default route starts with a cost of 1; to change it, use the area default-cost command. The example that follows shows area 2 configured as a totally stubby area, and the default route injected with a cost of 5:
Router(config-router)#area 2 stub no-summary
Router(config-router)#area 2 default-cost 5
Stub areas are attractive because of their low overhead. They do have some limitations, including the following:
Stub areas can’t include a virtual link.
Stub areas can’t include an ASBR.
Stubbiness must be configured on all routers in the area.
Another kind of stub area is a not-so-stubby area (NSSA). NSSA is like a stub or totally stub area, but allows an ASBR within the area. External routes are advertised as type 7 routes by the ASBR. The ABR converts them to type 5 external routes when it advertises them into adjacent areas. NSSA is configured with the area nssa command under the OSPF routing process. The no-summary keyword on the ABR configures the area as a totally NSSA area; this is a Cisco proprietary feature. By default, the ABR does not inject a default route back into an NSSA area. Use the default-information-originate keyword on the ABR or ASBR to create this route.
Router(config-router)#area 7 nssa [no-summary] [defaultinformation-originate]
Configuring Virtual Links
OSPF requires that all areas be connected to area 0 and that area 0 must be contiguous. When this is not possible, you can use a virtual link to bridge across an intermediate area. Figure 3-3 shows a virtual link connecting two portions of area 0.
No comments:
Post a Comment