Note that all the routes show up except the external routes that were replaced by a default route of 0.0.0.0. The cost of the route happened to be 65 (64 for a T1 line+1 advertised by RTC). You will now configure area 2 to be totally stubby and change the default cost of 0.0.0.0 to 10:
RTC# interface Ethernet 0 ip address 220.127.116.11 255.255.255.0 interface Serial1 ip address 18.104.22.168 255.255.255.252 router ospf 10 network 22.214.171.124 0.0.0.255 area 2 network 126.96.36.199 0.0.0.255 area 0 area 2 stub no-summary RTE#sh ip route Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default Gateway of last resort is not set 188.8.131.52 255.255.255.252 is subnetted, 1 subnets C 184.108.40.206 is directly connected, Serial0 220.127.116.11 255.255.255.240 is subnetted, 1 subnets O 18.104.22.168 [110/74] via 22.214.171.124, 00:31:27, Serial0 O*IA 0.0.0.0 0.0.0.0 [110/74] via 126.96.36.199, 00:00:00, Serial0
Note that the only routes that show up are the intra-area routes (O) and the default-route 0.0.0.0. The external and inter-area routes have been blocked. The cost of the default route is now 74 (64 for a T1 line+10 advertised by RTC). No configuration is needed on RTE in this case. The area is already stub, and the no-summary command does not affect the hello packet at all as the stub command does.
Totally Stubby Areas
Cisco indicates a TSA when configuring the routers by adding the no summary keyword to the configuration command. Thus, the configuration command needed is area # stub no summary.
A TSA blocks external routes and summary routes from entering the area. This leaves the default route and intra-area routes as the only types being advertised throughout the area. This is most complete summarization technique possible in OSPF and results in extremely small routing tables made up only of networks found with the area.
As mentioned in Chapter 4, Introduction to OSPF, NSSAs have their own RFC and are a rather new concept to OSPF. The advent of this new type of hybrid stub area also introduced a new LSA, Type 7, which is responsible for carrying external route information.
The two main benefits of the Type-7 LSA are that it can be filtered and flexibly summarized. Generally speaking, the use of a NSSA is advised when it lies between a ASBR and ABR, where the ASBR is connected to different routing protocol and the ABR is connected to OSPFs area 0.
The operation of an NSSA is rather straightforward. You have an ASBR connected to a network running RIP. This router is also configured as part of an NSSA. The router will redistribute the routes learned from RIP into an OSPF Type-7 LSA for transmission into the NSSA. The NSSA ABR will see these advertisements and want to forward them onto area 0 for distribution throughout the network. The ABR will then redistribute the Type-7 LSAs into Type-5 LSAs.
OSPF Route Selection
When designing an OSPF internetwork for efficient route selection, you need to consider three important topics:
Tuning OSPF Metrics
The default value for OSPF metrics (cost) is based on bandwidth. The following characteristics show how OSPF metrics are generated:
In some cases, your network might implement a media type that is faster than the fastest default media configurable for OSPF (FDDI). An example of a faster media is ATM. By default, a faster media will be assigned a cost equal to the cost of an FDDI linka link-state metric cost of 1. Given an environment with both FDDI and a faster media type, you must manually configure link costs to configure the faster link with a lower metric. Configure any FDDI link with a cost greater than 1, and configure the faster link with a cost less than the assigned FDDI link cost. Use the ip ospf cost interface configuration command to modify link-state cost.
When route summarization is enabled, OSPF uses the metric of the best route in the summary.
Types of External Metrics: E1 and E2
Routes that originate from other routing protocols (or different OSPF processes) and that are injected into OSPF via redistribution are called external routes. There are two forms of external metrics: type 1 (E1) and type 2 (E2). These routes are represented by O E2 or O E1 in the IP routing table. They are examined after the router is done building its internal routing table. After they are examined, they are flooded throughout the Autonomous System (AS), unaltered. External information could come from a variety of sources, such as another routing protocol.
E1 metrics result in routes adding the internal OSPF metric to the external route metric; they are also expressed in the same terms as an OSPF link-state metric. The internal OSPF metric is the total cost of reaching the external destination, including whatever internal OSPF network costs are incurred to get there. These costs are calculated by the router wanting to reach the external route.
E2 metrics do not add the internal OSPF metric to the cost of external routes; they are also the default type used by OSPF. The E1 metric is generally preferred. The use of E2 metrics assumes that you are routing between AS; therefore, the cost is considered greater than any internal metrics. This eliminates the need to add the internal OSPF metrics. Figure 5-12 shows a nice comparison of the two metrics.