Selecting the Appropriate Area Types

Problem

You want to limit the number of routes and entries in the Link State database to conserve router resources and ensure good convergence properties.

Solution

In the Introduction to this chapter, we talked about the various types of OSPF areas. You can configure these different types areas by using the appropriate keywords on the area command.

For a Stubby Area, use the stub keyword:

Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#router ospf 55
Router1(config-router)#area 100 stub 
Router1(config-router)#exit
Router1(config)#end
Router1#

To configure a Totally Stubby Area, combine the stub and no-summary keywords on the ABR router:

Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#router ospf 55
Router1(config-router)#area 100 stub no-summary
Router1(config-router)#exit
Router1(config)#end
Router1#

Only the ABRs needs the no-summary keyword, because they are the only routers that will be doing the route summarization. The other routers in a Totally Stubby Area need only be configured using the stub keyword, as in the previous example.

For Not So Stubby Areas (NSSA), you need to specify the nssa keyword. In this case we have also included the default-information-originate option so that the router can summarize external routes to a single default route:

Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#router ospf 55 
Router1(config-router)#area 100 nssa default-information-originate 
Router1(config-router)#exit
Router1(config)#end
Router1#

In the Introduction we also discussed an interesting variant, called the Totally Stubby, Not So Stubby Area. You can configure it as follows on the ABR:

Router1#configure terminal
Enter configuration commands, one per line. End with CNTL/Z.
Router1(config)#router ospf 55
Router1(config-router)#area 100 nssa no-summary
Router1(config-router)#exit
Router1(config)#end
Router1#

Once again, you can simply configure the other routers in this area with the nssa keyword.

Discussion

In all of the configuration examples, we showed the configuration for just one router. It is important to remember that the routers in an area have to agree on the area type. However, it is mostly the ABR that cares about the area type, because it has to decide what kinds of information to forward from other parts of the network. Every router in a stub area must be configured as stub, although only the ABR needs to worry about the difference between stub and totally stub. Every router in an NSSA area must be configured to support NSSA type 7 LSA messages. But, once again, only the ABR cares about the difference between NSSA and totally stub NSSA.

If you have any ASBR devices that inject routes from other autonomous systems in this area, then they also need to use the area type information. The other routers are only really concerned with forwarding the LSAs around the area.

When you look at the routing table, you can see there are several kinds of routes:

Router3#show ip route ospf
O E1 192.168.10.0/24 [110/3611] via 172.20.1.1, 00:00:20, Serial0.1
 172.16.0.0/24 is subnetted, 1 subnets
O IA 172.16.2.0 [110/3581] via 172.20.1.1, 00:00:20, Serial0.1
 172.20.0.0/16 is variably subnetted, 5 subnets, 3 masks
O 172.20.220.1/32 [110/11] via 172.20.10.2, 00:00:20, Ethernet0
O 172.20.200.1/32 [110/11] via 172.20.10.2, 00:00:20, Ethernet0
 172.22.0.0/24 is subnetted, 1 subnets
O IA 172.22.1.0 [110/3581] via 172.20.1.1, 00:00:20, Serial0.1
 172.25.0.0/16 is variably subnetted, 3 subnets, 2 masks
O IA 172.25.25.6/32 [110/3582] via 172.20.1.1, 00:00:20, Serial0.1
O IA 172.25.25.1/32 [110/3572] via 172.20.1.1, 00:00:20, Serial0.1
O IA 172.25.1.0/24 [110/3581] via 172.20.1.1, 00:00:20, Serial0.1
 172.24.0.0/24 is subnetted, 1 subnets
O E1 172.24.1.0 [110/3611] via 172.20.1.1, 00:00:20, Serial0.1
 10.0.0.0/8 is variably subnetted, 4 subnets, 3 masks
O IA 10.2.2.2/32 [110/5134] via 172.20.1.1, 00:00:20, Serial0.1
O E1 10.2.2.0/30 [110/3606] via 172.20.1.1, 00:00:20, Serial0.1
O IA 10.1.1.0/30 [110/5133] via 172.20.1.1, 00:00:20, Serial0.1
O E1 10.100.1.0/24 [110/3611] via 172.20.1.1, 00:00:20, Serial0.1
O E2 192.168.50.0/24 [110/20] via 172.20.1.1, 00:00:20, Serial0.1
Router3#

This output shows only routes that were learned via OSPF, which is indicated by the O at the start of each line. In this routing table, there are several external routes. Most of them are Type 1 externals, which are labeled E1. There is also one Type 2 external route, which is labeled E2 in the output. Some of the other routes have IA beside them, which indicates they are interarea routes, meaning that they did not originate in this area. The remaining routes, such as 172.20.220.1/32, represent networks in this area.

This routing table shows no summarization. For example, the 10.0.0.0/8 classful network has several distinct subnets, including both 10.2.2.0/30 and its subnet 10.2.2.2/32. It's also useful to look at the OSPF database on this router to see how different routes are categorized:

Router3#show ip ospf database

 OSPF Router with ID (172.25.25.2) (Process ID 44)

 Router Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Link count
172.20.220.1 172.20.220.1 47 0x80000004 0xB352 3
172.25.25.1 172.25.25.1 89 0x80000067 0xE771 2
172.25.25.2 172.25.25.2 47 0x80000065 0x4C66 4

 Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.20.10.1 172.25.25.2 42 0x80000002 0xF11B 

 Summary Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
10.1.1.0 172.25.25.1 173 0x80000002 0x86AC 
10.2.2.2 172.25.25.1 173 0x80000002 0x77B3 
172.16.2.0 172.25.25.1 173 0x80000002 0xBFD3 
172.22.1.0 172.25.25.1 173 0x80000002 0x820C 
172.25.1.0 172.25.25.1 173 0x80000002 0x5E2D 
172.25.25.1 172.25.25.1 173 0x80000002 0xF08A 
172.25.25.6 172.25.25.1 173 0x80000002 0x2349 

 Summary ASB Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.25.1.7 172.25.25.1 173 0x80000001 0xC78 
172.25.25.1 172.25.25.1 173 0x80000001 0xBCDF 

 Type-5 AS External Link States

Link ID ADV Router Age Seq# Checksum Tag
10.2.2.0 172.25.25.1 1138 0x8000000A 0x9588 0
10.100.1.0 172.25.25.1 1138 0x80000009 0x4A6B 0
172.24.1.0 172.25.25.1 1138 0x80000009 0x9BC3 0
192.168.10.0 172.25.25.1 1138 0x80000009 0x6C45 0
192.168.50.0 172.25.1.7 428 0x80000002 0xFF36 0
Router3#

This represents a relatively small OSPF network. But it's a useful example because there are some instances of each type of route.

When we configure this area to be a Stubby Area, the ABR prevents External routes from being propagated into the area and replaces them with a default route. ASBRs are not permitted in stubby areas:

Router3#show ip route ospf
 172.16.0.0/24 is subnetted, 1 subnets
O IA 172.16.2.0 [110/3581] via 172.20.1.1, 00:00:07, Serial0.1
 172.20.0.0/16 is variably subnetted, 5 subnets, 3 masks
O 172.20.220.1/32 [110/11] via 172.20.10.2, 00:00:20, Ethernet0
O 172.20.200.1/32 [110/11] via 172.20.10.2, 00:00:20, Ethernet0
 172.22.0.0/24 is subnetted, 1 subnets
O IA 172.22.1.0 [110/3581] via 172.20.1.1, 00:00:07, Serial0.1
 172.25.0.0/16 is variably subnetted, 3 subnets, 2 masks
O IA 172.25.25.6/32 [110/3582] via 172.20.1.1, 00:00:07, Serial0.1
O IA 172.25.25.1/32 [110/3572] via 172.20.1.1, 00:00:07, Serial0.1
O IA 172.25.1.0/24 [110/3581] via 172.20.1.1, 00:00:07, Serial0.1
 10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
O IA 10.2.2.2/32 [110/5134] via 172.20.1.1, 00:00:07, Serial0.1
O IA 10.1.1.0/30 [110/5133] via 172.20.1.1, 00:00:07, Serial0.1
O*IA 0.0.0.0/0 [110/3572] via 172.20.1.1, 00:00:07, Serial0.1
Router3# 

As you can see, all of the external routes are gone, but the tnterarea routes remain. Looking at the OSPF database, you can see that there is considerably less information for the router to keep track of:

Router3#show ip ospf database 

 OSPF Router with ID (172.25.25.2) (Process ID 44)

 Router Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Link count
172.20.220.1 172.20.220.1 22 0x80000006 0xCD38 3
172.25.25.1 172.25.25.1 86 0x80000069 0xFB5F 2
172.25.25.2 172.25.25.2 22 0x80000068 0x644D 4

 Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.20.10.1 172.25.25.2 17 0x80000003 0xEFF 

 Summary Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
0.0.0.0 172.25.25.1 92 0x80000001 0x213D 
10.1.1.0 172.25.25.1 92 0x80000003 0xA291 
10.2.2.2 172.25.25.1 92 0x80000003 0x9398 
172.16.2.0 172.25.25.1 92 0x80000003 0xDBB8 
172.22.1.0 172.25.25.1 92 0x80000003 0x9EF0 
172.25.1.0 172.25.25.1 92 0x80000003 0x7A12 
172.25.25.1 172.25.25.1 92 0x80000003 0xD6F 
172.25.25.6 172.25.25.1 92 0x80000003 0x3F2E 
Router3#

Totally stubby areas prevent external routes like ordinary stub areas. But the ABRs for totally stubby areas also prevent interarea routes from being propagated into the area, replacing them with a single default route instead. The default route is the only summary route allowed. ASBRs are not permitted in stub or Totally Stubby areas:

Router3#show ip route ospf 
 172.20.0.0/16 is variably subnetted, 5 subnets, 3 masks
O 172.20.220.1/32 [110/11] via 172.20.10.2, 00:00:15, Ethernet0
O 172.20.200.1/32 [110/11] via 172.20.10.2, 00:00:15, Ethernet0
O*IA 0.0.0.0/0 [110/3572] via 172.20.1.1, 00:00:15, Serial0.1
Router3#

The Totally Stubby Area has radically reduced the size of the routing table, as well as the OSPF database:

Router3#show ip ospf database 

 OSPF Router with ID (172.25.25.2) (Process ID 44)

 Router Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Link count
172.20.220.1 172.20.220.1 104 0x80000006 0xCD38 3
172.25.25.1 172.25.25.1 22 0x8000006B 0xF761 2
172.25.25.2 172.25.25.2 104 0x80000068 0x644D 4

 Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.20.10.1 172.25.25.2 99 0x80000003 0xEFF 

 Summary Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
0.0.0.0 172.25.25.1 23 0x80000002 0x1F3E 
Router3#

There are two main differences between stubby and NSSA areas. The first is that the NSSA prevents the ABR from propagating external routes throughout the area, but does not replace them with a single default route. The second is that the NSSA may contain ASBRs, which use Type 7 LSAs to carry information about external routes. These Type 7 LSAs are flooded throughout the NSSA area. When they reach the ABR, they are translated into Type 5 LSAs and forwarded to the rest of the OSPF network:

Router3#configure terminal 
Enter configuration commands, one per line. End with CNTL/Z.
Router3(config)#ip route 192.168.88.0 255.255.255.0 172.20.10.2
Router3(config)#router ospf 44
Router3(config-router)#redistribute static subnet
Router3(config-router)#area 100 nssa default-information-originate
Router3(config-router)#exit
Router3(config)#end
Router3#

With the default-information-originate option, the ABR will forward a default route to summarize all external routes that originate outside of the area:

Router3#show ip route ospf
 172.16.0.0/24 is subnetted, 1 subnets
O IA 172.16.2.0 [110/3581] via 172.20.1.1, 00:07:43, Serial0.1
 172.20.0.0/16 is variably subnetted, 5 subnets, 3 masks
O 172.20.220.1/32 [110/11] via 172.20.10.2, 00:07:43, Ethernet0
O 172.20.200.1/32 [110/11] via 172.20.10.2, 00:07:43, Ethernet0
 172.22.0.0/24 is subnetted, 1 subnets
O IA 172.22.1.0 [110/3581] via 172.20.1.1, 00:07:43, Serial0.1
 172.25.0.0/16 is variably subnetted, 3 subnets, 2 masks
O IA 172.25.25.6/32 [110/3582] via 172.20.1.1, 00:07:43, Serial0.1
O IA 172.25.25.1/32 [110/3572] via 172.20.1.1, 00:07:43, Serial0.1
O IA 172.25.1.0/24 [110/3581] via 172.20.1.1, 00:07:43, Serial0.1
 10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
O IA 10.2.2.2/32 [110/5134] via 172.20.1.1, 00:07:43, Serial0.1
O IA 10.1.1.0/30 [110/5133] via 172.20.1.1, 00:07:43, Serial0.1
O*N2 0.0.0.0/0 [110/1] via 172.20.1.1, 00:07:43, Serial0.1
Router3#

The OSPF database for an NSSA area shows information about Type 7 LSAs:

Router3#show ip ospf database 

 OSPF Router with ID (172.25.25.2) (Process ID 44)

 Router Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Link count
172.20.220.1 172.20.220.1 973 0x80000008 0x51AA 3
172.25.25.1 172.25.25.1 502 0x80000072 0x77D0 2
172.25.25.2 172.25.25.2 968 0x8000006E 0xE5BB 4

 Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.20.10.1 172.25.25.2 967 0x80000004 0x9371 

 Summary Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
10.1.1.0 172.25.25.1 1124 0x80000003 0x2A02 
10.2.2.2 172.25.25.1 1124 0x80000003 0x1B09 
172.16.2.0 172.25.25.1 1124 0x80000003 0x6329 
172.22.1.0 172.25.25.1 1124 0x80000003 0x2661 
172.25.1.0 172.25.25.1 1124 0x80000003 0x282 
172.25.25.1 172.25.25.1 1124 0x80000003 0x94DF 
172.25.25.6 172.25.25.1 1124 0x80000003 0xC69E 

 Type-7 AS External Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Tag
0.0.0.0 172.25.25.1 508 0x80000001 0xF31B 0
10.2.2.0 172.25.25.1 1123 0x80000001 0x2FE7 0
10.100.1.0 172.25.25.1 1123 0x80000001 0xE90B 0
172.24.1.0 172.25.25.1 1123 0x80000001 0x3B63 0
192.168.10.0 172.25.25.1 1123 0x80000001 0xCE4 0
192.168.88.0 172.25.25.2 974 0x80000001 0x3AEC 0
Router3#

It is also interesting to look at the routing table entry for one of these Type 7 routes on another router within the same area:

Router1#show ip route 192.168.88.0
Routing entry for 192.168.88.0/24
 Known via "ospf 55", metric 20, type NSSA extern 2, forward metric 1572
 Last update from 172.20.1.2 on Serial0/0.2, 00:08:56 ago
 Routing Descriptor Blocks:
 * 172.20.1.2, from 172.25.25.2, 00:08:56 ago, via Serial0/0.2
 Route metric is 20, traffic share count is 1
Router1#

The aptly named Totally Stubby Not So Stubby Area is similar to an NSSA area, but it also acts like a Totally Stubby area in preventing the ABR from advertising Inter Area routes and replaces them with a single summary route, the default route. The ABR for a Totally Stubby NSSA will create a default route by default:

Router3#show ip route ospf
 172.20.0.0/16 is variably subnetted, 5 subnets, 3 masks
O 172.20.220.1/32 [110/11] via 172.20.10.2, 00:00:47, Ethernet0
O 172.20.200.1/32 [110/11] via 172.20.10.2, 00:00:47, Ethernet0
O*IA 0.0.0.0/0 [110/3572] via 172.20.1.1, 00:00:47, Serial0.1
Router3#

Despite the confusing name, this is an extremely useful type of area. In many large OSPF networks, most of the routes in the routing table are interarea routes. But you can also put an ASBR in this type of area and use it as a transit area to connect to external networks:

Router3#show ip ospf database 

 OSPF Router with ID (172.25.25.2) (Process ID 44)

 Router Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Link count
172.20.220.1 172.20.220.1 1209 0x80000008 0x51AA 3
172.25.25.1 172.25.25.1 91 0x80000074 0x73D2 2
172.25.25.2 172.25.25.2 1204 0x8000006E 0xE5BB 4

 Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
172.20.10.1 172.25.25.2 1203 0x80000004 0x9371 

 Summary Net Link States (Area 100)

Link ID ADV Router Age Seq# Checksum
0.0.0.0 172.25.25.1 92 0x80000001 0xA8AD 

 Type-7 AS External Link States (Area 100)

Link ID ADV Router Age Seq# Checksum Tag
10.2.2.0 172.25.25.1 88 0x80000002 0x2DE8 0
10.100.1.0 172.25.25.1 82 0x80000003 0xE50D 0
172.24.1.0 172.25.25.1 88 0x80000002 0x3964 0
192.168.10.0 172.25.25.1 88 0x80000002 0xAE5 0
192.168.88.0 172.25.25.2 86 0x80000002 0x38ED 0
Router3#

Like an NSSA area, the ABR translates Type 7 to Type 5 LSAs:

Router1#show ip ospf 
 Routing Process "ospf 55" with ID 172.25.25.1
 
 Area 100
 Number of interfaces in this area is 1
 It is a NSSA area
 Perform type-7/type-5 LSA translation
 Area has no authentication
 SPF algorithm executed 75 times
 Area ranges are
 Number of LSA 13. Checksum Sum 0x6B01B 
 Number of opaque link LSA 0. Checksum Sum 0x0 
 Number of DCbitless LSA 0
 Number of indication LSA 0
 Number of DoNotAge LSA 0
 Flood list length 0
Router1#

 

See Also

IP Routing by Ravi Malhotra (O'Reilly)

Router Configuration and File Management

Router Management

User Access and Privilege Levels

TACACS+

IP Routing

RIP

EIGRP

OSPF

BGP

Frame Relay

Handling Queuing and Congestion

Tunnels and VPNs

Dial Backup

NTP and Time

DLSw

Router Interfaces and Media

Simple Network Management Protocol

Logging

Access-Lists

DHCP

NAT

First Hop Redundancy Protocols

IP Multicast

IP Mobility

IPv6

MPLS

Security

Appendix 1. External Software Packages

Appendix 2. IP Precedence, TOS, and DSCP Classifications

Index



Cisco IOS Cookbook
Cisco IOS Cookbook (Cookbooks (OReilly))
ISBN: 0596527225
EAN: 2147483647
Year: 2004
Pages: 505

Flylib.com © 2008-2020.
If you may any questions please contact us: flylib@qtcs.net