Consolidation of multiple routes into one single advertisement is called Route Summarization. In a nut shell, route summarization is the process of summarizing subnets into a larger subnet to be advertised to upstream routers for ease of management/troubleshooting and resource conservation.
There are two types of route summarization in OSPF.
1. Inter-Area Route Summarization
Although summarization could be configured between any two areas, it is better to summarize in the direction of the backbone. This way the backbone receives all the aggregate addresses and in turn will injects them, already summarized, into other areas.
Inter-Area route summarization can only be done on the Area Boarder Router (ABR) and summarize routes from one particular area into the another Area.
To specify an address range, perform the following task in router configuration mode:
area area-id range address mask
Where the “area-id” is the area containing networks to be summarized. The “address” and “mask” will specify the range of addresses to be summarized in one range.
2. External Route Summarization
External route summarization is specific to external routes that are injected into OSPF via redistribution.
Summarization is done via the following router ospf subcommand:
summary-address ip-address mask
This command is effective only on ASBRs doing redistribution into OSPF.
We will use following network topology for our discussion.
Pre-Configuration R1: interface FastEthernet0/0 ip address 10.10.123.1 255.255.255.0 ! interface FastEthernet0/1 ip address 192.168.16.1 255.255.255.0 ! router eigrp 100 redistribute ospf 1 network 192.168.16.1 0.0.0.0 default-metric 10000 100 255 1 1500 no auto-summary ! router ospf 1 router-id 1.1.1.1 summary-address 192.168.0.0 255.255.0.0 redistribute eigrp 100 subnets network 10.0.0.0 0.255.255.255 area 0 R2: interface FastEthernet0/0 ip address 10.10.123.2 255.255.255.0 ! interface FastEthernet0/1 ip address 10.10.24.2 255.255.255.0 ip ospf network point-to-point ! router ospf 1 router-id 2.2.2.2 network 10.10.24.2 0.0.0.0 area 1 network 10.10.123.2 0.0.0.0 area 0 R3: interface FastEthernet0/0 ip address 10.10.123.3 255.255.255.0 ! interface FastEthernet0/1 ip address 10.10.35.3 255.255.255.0 ip ospf network point-to-point ! router ospf 1 router-id 3.3.3.3 network 10.10.35.3 0.0.0.0 area 2 network 10.10.123.3 0.0.0.0 area 0 R4: interface Loopback4 ip address 10.4.4.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback5 ip address 10.4.5.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback6 ip address 10.4.6.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback7 ip address 10.4.7.1 255.255.255.0 ip ospf network point-to-point ! interface FastEthernet0/0 ip address 10.10.24.4 255.255.255.0 ip ospf network point-to-point ! router ospf 1 router-id 4.4.4.4 network 10.0.0.0 0.255.255.255 area 1 R5: interface Loopback0 ip address 10.5.0.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback1 ip address 10.5.1.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback2 ip address 10.5.2.1 255.255.255.0 ip ospf network point-to-point ! interface Loopback3 ip address 10.5.3.1 255.255.255.0 ip ospf network point-to-point ! interface FastEthernet0/0 ip address 10.10.35.5 255.255.255.0 ip ospf network point-to-point ! router ospf 1 router-id 5.5.5.5 network 10.0.0.0 0.255.255.255 area 2 R6: interface Loopback0 ip address 192.168.0.1 255.255.255.0 ! interface Loopback1 ip address 192.168.1.1 255.255.255.0 ! interface Loopback2 ip address 192.168.2.1 255.255.255.0 ! interface Loopback3 ip address 192.168.3.1 255.255.255.0 ! interface FastEthernet0/0 ip address 192.168.16.6 255.255.255.0 ! router eigrp 100 network 192.168.0.0 0.0.255.255 no auto-summary Note: Loopback Interfaces are used to simulate different networks connected to routers.
OSPF neighborships are UP and all routers have end-to-end network reachability.
R1#sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 2.2.2.2 1 FULL/BDR 00:00:34 10.10.123.2 FastEthernet0/0 3.3.3.3 1 FULL/DR 00:00:31 10.10.123.3 FastEthernet0/0 R2#sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 1.1.1.1 1 FULL/DROTHER 00:00:31 10.10.123.1 FastEthernet0/0 3.3.3.3 1 FULL/DR 00:00:31 10.10.123.3 FastEthernet0/0 4.4.4.4 0 FULL/ - 00:00:34 10.10.24.4 FastEthernet0/1 R3#sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 1.1.1.1 1 FULL/DROTHER 00:00:31 10.10.123.1 FastEthernet0/0 2.2.2.2 1 FULL/BDR 00:00:34 10.10.123.2 FastEthernet0/0 5.5.5.5 0 FULL/ - 00:00:33 10.10.35.5 FastEthernet0/1 R4#sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 2.2.2.2 0 FULL/ - 00:00:32 10.10.24.2 FastEthernet0/0 R5#sh ip ospf neighbor Neighbor ID Pri State Dead Time Address Interface 3.3.3.3 0 FULL/ - 00:00:38 10.10.35.3 FastEthernet0/0 R6#sh ip eigrp neighbors IP-EIGRP neighbors for process 100 H Address Interface Hold Uptime SRTT RTO Q Seq (sec) (ms) Cnt Num 0 192.168.16.1 Fa0/0 13 02:30:57 28 675 0 50 Routing Tables: R1#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O IA 10.4.6.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.4.7.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.4.4.0 [110/3] via 10.10.123.2, 00:29:08, FastEthernet0/0 O IA 10.4.5.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.5.3.0 [110/3] via 10.10.123.3, 00:28:53, FastEthernet0/0 O IA 10.5.2.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.1.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.0.0 [110/3] via 10.10.123.3, 00:27:56, FastEthernet0/0 O IA 10.10.24.0 [110/2] via 10.10.123.2, 00:30:27, FastEthernet0/0 O IA 10.10.35.0 [110/2] via 10.10.123.3, 00:30:27, FastEthernet0/0 C 10.10.123.0 is directly connected, FastEthernet0/0 D 192.168.0.0/24 [90/156160] via 192.168.16.6, 02:30:25, FastEthernet0/1 C 192.168.16.0/24 is directly connected, FastEthernet0/1 D 192.168.1.0/24 [90/156160] via 192.168.16.6, 02:30:26, FastEthernet0/1 D 192.168.2.0/24 [90/156160] via 192.168.16.6, 02:30:26, FastEthernet0/1 D 192.168.3.0/24 [90/156160] via 192.168.16.6, 01:06:06, FastEthernet0/1 R2#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O 10.4.6.0 [110/2] via 10.10.24.4, 00:29:13, FastEthernet0/1 O 10.4.7.0 [110/2] via 10.10.24.4, 00:29:13, FastEthernet0/1 O 10.4.4.0 [110/2] via 10.10.24.4, 00:29:13, FastEthernet0/1 O 10.4.5.0 [110/2] via 10.10.24.4, 00:29:13, FastEthernet0/1 O IA 10.5.3.0 [110/3] via 10.10.123.3, 00:28:53, FastEthernet0/0 O IA 10.5.2.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.1.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.0.0 [110/3] via 10.10.123.3, 00:27:56, FastEthernet0/0 C 10.10.24.0 is directly connected, FastEthernet0/1 O IA 10.10.35.0 [110/2] via 10.10.123.3, 00:29:13, FastEthernet0/0 C 10.10.123.0 is directly connected, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.123.1, 00:29:13, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 00:29:13, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.123.1, 00:29:13, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.123.1, 00:29:14, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.123.1, 00:29:14, FastEthernet0/0 R3#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O IA 10.4.6.0 [110/3] via 10.10.123.2, 00:28:53, FastEthernet0/0 O IA 10.4.7.0 [110/3] via 10.10.123.2, 00:28:53, FastEthernet0/0 O IA 10.4.4.0 [110/3] via 10.10.123.2, 00:28:53, FastEthernet0/0 O IA 10.4.5.0 [110/3] via 10.10.123.2, 00:28:53, FastEthernet0/0 O 10.5.3.0 [110/2] via 10.10.35.5, 00:28:53, FastEthernet0/1 O 10.5.2.0 [110/2] via 10.10.35.5, 00:27:46, FastEthernet0/1 O 10.5.1.0 [110/2] via 10.10.35.5, 00:27:46, FastEthernet0/1 O 10.5.0.0 [110/2] via 10.10.35.5, 00:27:56, FastEthernet0/1 O IA 10.10.24.0 [110/2] via 10.10.123.2, 00:28:53, FastEthernet0/0 C 10.10.35.0 is directly connected, FastEthernet0/1 C 10.10.123.0 is directly connected, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.123.1, 00:28:53, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 00:28:53, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.123.1, 00:28:53, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.123.1, 00:28:54, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.123.1, 00:28:54, FastEthernet0/0 R4#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets C 10.4.6.0 is directly connected, Loopback6 C 10.4.7.0 is directly connected, Loopback7 C 10.4.4.0 is directly connected, Loopback4 C 10.4.5.0 is directly connected, Loopback5 O IA 10.5.3.0 [110/4] via 10.10.24.2, 00:28:53, FastEthernet0/0 O IA 10.5.2.0 [110/4] via 10.10.24.2, 00:27:46, FastEthernet0/0 O IA 10.5.1.0 [110/4] via 10.10.24.2, 00:27:46, FastEthernet0/0 O IA 10.5.0.0 [110/4] via 10.10.24.2, 00:27:56, FastEthernet0/0 C 10.10.24.0 is directly connected, FastEthernet0/0 O IA 10.10.35.0 [110/3] via 10.10.24.2, 00:30:27, FastEthernet0/0 O IA 10.10.123.0 [110/2] via 10.10.24.2, 00:30:57, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.24.2, 00:29:24, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.24.2, 00:29:31, FastEthernet0/0 R5#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O IA 10.4.6.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 O IA 10.4.7.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 O IA 10.4.4.0 [110/4] via 10.10.35.3, 00:29:03, FastEthernet0/0 O IA 10.4.5.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 C 10.5.3.0 is directly connected, Loopback3 C 10.5.2.0 is directly connected, Loopback2 C 10.5.1.0 is directly connected, Loopback1 C 10.5.0.0 is directly connected, Loopback0 O IA 10.10.24.0 [110/3] via 10.10.35.3, 00:30:27, FastEthernet0/0 C 10.10.35.0 is directly connected, FastEthernet0/0 O IA 10.10.123.0 [110/2] via 10.10.35.3, 00:30:57, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.35.3, 00:29:24, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.35.3, 00:29:31, FastEthernet0/0 R6#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets D EX 10.4.6.0 [170/284160] via 192.168.16.1, 00:29:12, FastEthernet0/0 D EX 10.4.7.0 [170/284160] via 192.168.16.1, 00:29:12, FastEthernet0/0 D EX 10.4.4.0 [170/284160] via 192.168.16.1, 00:29:08, FastEthernet0/0 D EX 10.4.5.0 [170/284160] via 192.168.16.1, 00:29:12, FastEthernet0/0 D EX 10.5.3.0 [170/284160] via 192.168.16.1, 00:28:53, FastEthernet0/0 D EX 10.5.2.0 [170/284160] via 192.168.16.1, 00:27:46, FastEthernet0/0 D EX 10.5.1.0 [170/284160] via 192.168.16.1, 00:27:46, FastEthernet0/0 D EX 10.5.0.0 [170/284160] via 192.168.16.1, 00:27:56, FastEthernet0/0 D EX 10.10.24.0 [170/284160] via 192.168.16.1, 00:30:27, FastEthernet0/0 D EX 10.10.35.0 [170/284160] via 192.168.16.1, 00:30:27, FastEthernet0/0 D EX 10.10.123.0 [170/284160] via 192.168.16.1, 02:12:11, FastEthernet0/0 C 192.168.0.0/24 is directly connected, Loopback0 C 192.168.16.0/24 is directly connected, FastEthernet0/0 C 192.168.1.0/24 is directly connected, Loopback1 C 192.168.2.0/24 is directly connected, Loopback2 C 192.168.3.0/24 is directly connected, Loopback3
First we want to summarize Area 1 routes. R2 is the ABR (Area Border Router), connecting Area1 to Backbone Area (Area 0). Here, R2 will do the inter-area route summarization and send summary advertisement into Area 0.
These four IP subnets can be summarized as follows:
10.4.4.0/24
10.4.5.0/24
10.4.6.0/24
10.4.7.0/24
Summary Network: 10.4.4.0
Mask: 255.255.252.0
R2#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R2(config)#router ospf 1
R2(config-router)#area 1 range 10.4.4.0 255.255.252.0
R2(config-router)#end
R2#
Let’s see the changes in routing tables on other routers
R1 Before Route Summarization: R1#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O IA 10.4.6.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.4.7.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.4.4.0 [110/3] via 10.10.123.2, 00:29:08, FastEthernet0/0 O IA 10.4.5.0 [110/3] via 10.10.123.2, 00:29:13, FastEthernet0/0 O IA 10.5.3.0 [110/3] via 10.10.123.3, 00:28:53, FastEthernet0/0 O IA 10.5.2.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.1.0 [110/3] via 10.10.123.3, 00:27:46, FastEthernet0/0 O IA 10.5.0.0 [110/3] via 10.10.123.3, 00:27:56, FastEthernet0/0 O IA 10.10.24.0 [110/2] via 10.10.123.2, 00:30:27, FastEthernet0/0 O IA 10.10.35.0 [110/2] via 10.10.123.3, 00:30:27, FastEthernet0/0 C 10.10.123.0 is directly connected, FastEthernet0/0 D 192.168.0.0/24 [90/156160] via 192.168.16.6, 02:30:25, FastEthernet0/1 C 192.168.16.0/24 is directly connected, FastEthernet0/1 D 192.168.1.0/24 [90/156160] via 192.168.16.6, 02:30:26, FastEthernet0/1 D 192.168.2.0/24 [90/156160] via 192.168.16.6, 02:30:26, FastEthernet0/1 D 192.168.3.0/24 [90/156160] via 192.168.16.6, 01:06:06, FastEthernet0/1 R1 After Route Summarization: R1#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 8 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 00:01:47, FastEthernet0/0 O IA 10.5.3.0/24 [110/3] via 10.10.123.3, 00:56:18, FastEthernet0/0 O IA 10.5.2.0/24 [110/3] via 10.10.123.3, 00:55:11, FastEthernet0/0 O IA 10.5.1.0/24 [110/3] via 10.10.123.3, 00:55:11, FastEthernet0/0 O IA 10.5.0.0/24 [110/3] via 10.10.123.3, 00:55:21, FastEthernet0/0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 00:57:52, FastEthernet0/0 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 00:57:52, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 D 192.168.0.0/24 [90/156160] via 192.168.16.6, 02:57:50, FastEthernet0/1 C 192.168.16.0/24 is directly connected, FastEthernet0/1 D 192.168.1.0/24 [90/156160] via 192.168.16.6, 02:57:49, FastEthernet0/1 D 192.168.2.0/24 [90/156160] via 192.168.16.6, 02:57:49, FastEthernet0/1 D 192.168.3.0/24 [90/156160] via 192.168.16.6, 01:33:29, FastEthernet0/1 R5 Before Route Summarization: R5#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets O IA 10.4.6.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 O IA 10.4.7.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 O IA 10.4.4.0 [110/4] via 10.10.35.3, 00:29:03, FastEthernet0/0 O IA 10.4.5.0 [110/4] via 10.10.35.3, 00:29:12, FastEthernet0/0 C 10.5.3.0 is directly connected, Loopback3 C 10.5.2.0 is directly connected, Loopback2 C 10.5.1.0 is directly connected, Loopback1 C 10.5.0.0 is directly connected, Loopback0 O IA 10.10.24.0 [110/3] via 10.10.35.3, 00:30:27, FastEthernet0/0 C 10.10.35.0 is directly connected, FastEthernet0/0 O IA 10.10.123.0 [110/2] via 10.10.35.3, 00:30:57, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.35.3, 00:29:24, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.35.3, 00:29:29, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.35.3, 00:29:31, FastEthernet0/0 R5 After Route Summarization: R5#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 8 subnets, 2 masks O IA 10.4.4.0/22 [110/4] via 10.10.35.3, 00:06:30, FastEthernet0/0 C 10.5.3.0/24 is directly connected, Loopback3 C 10.5.2.0/24 is directly connected, Loopback2 C 10.5.1.0/24 is directly connected, Loopback1 C 10.5.0.0/24 is directly connected, Loopback0 O IA 10.10.24.0/24 [110/3] via 10.10.35.3, 01:02:34, FastEthernet0/0 C 10.10.35.0/24 is directly connected, FastEthernet0/0 O IA 10.10.123.0/24 [110/2] via 10.10.35.3, 01:03:04, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.35.3, 01:01:32, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.35.3, 01:01:36, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.35.3, 01:01:36, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.35.3, 01:01:36, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.35.3, 01:01:36, FastEthernet0/0
Let’s do the same for Area 2. R3 is the ABR here and doing the route summarization for following networks.
10.5.0.0/24
10.5.1.0/24
10.5.2.0/24
10.5.3.0/24
Summary Network: 10.5.0.0
Mask: 255.255.252.0
R3#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R3(config)#router ospf 1
R3(config-router)#area 2 range 10.5.0.0 255.255.252.0
R3(config-router)#end
R3#
Let’s see the changes in routing tables on other routers
Before Route Summarization: R1#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 8 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 00:01:47, FastEthernet0/0 O IA 10.5.3.0/24 [110/3] via 10.10.123.3, 00:56:18, FastEthernet0/0 O IA 10.5.2.0/24 [110/3] via 10.10.123.3, 00:55:11, FastEthernet0/0 O IA 10.5.1.0/24 [110/3] via 10.10.123.3, 00:55:11, FastEthernet0/0 O IA 10.5.0.0/24 [110/3] via 10.10.123.3, 00:55:21, FastEthernet0/0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 00:57:52, FastEthernet0/0 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 00:57:52, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 D 192.168.0.0/24 [90/156160] via 192.168.16.6, 02:57:50, FastEthernet0/1 C 192.168.16.0/24 is directly connected, FastEthernet0/1 D 192.168.1.0/24 [90/156160] via 192.168.16.6, 02:57:49, FastEthernet0/1 D 192.168.2.0/24 [90/156160] via 192.168.16.6, 02:57:49, FastEthernet0/1 D 192.168.3.0/24 [90/156160] via 192.168.16.6, 01:33:29, FastEthernet0/1 R1# After Route Summarization: R1#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 5 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 00:35:14, FastEthernet0/0 O IA 10.5.0.0/22 [110/3] via 10.10.123.3, 00:01:40, FastEthernet0/0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 01:31:19, FastEthernet0/0 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 01:31:19, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 D 192.168.0.0/24 [90/156160] via 192.168.16.6, 03:31:17, FastEthernet0/1 C 192.168.16.0/24 is directly connected, FastEthernet0/1 D 192.168.1.0/24 [90/156160] via 192.168.16.6, 03:31:16, FastEthernet0/1 D 192.168.2.0/24 [90/156160] via 192.168.16.6, 03:31:16, FastEthernet0/1 D 192.168.3.0/24 [90/156160] via 192.168.16.6, 02:06:56, FastEthernet0/1
Let’s summarize external routes now. Router R1 is the ASBR connected to both EIGRP and OSPF domains and doing route redistribution between EIGRP and OSPF.
R1 (ASBR) will do the route summarization for external routes into OSPF.
These four IP subnets can be summarized as follows:
192.168.0.0/24
192.168.1.0/24
192.168.2.0/24
192.168.3.0/24
Summary Network: 192.168.0.0
Mask: 255.255.252.0
R1#conf t
Enter configuration commands, one per line. End with CNTL/Z.
R1(config)#router ospf 1
R1(config-router)#summary-address 192.168.0.0 255.255.252.0
R1(config-router)#end
R1#
Let’s see the changes in routing tables on other routers
Before Route Summarization: R2#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 12 subnets, 2 masks O 10.4.6.0/24 [110/2] via 10.10.24.4, 00:03:02, FastEthernet0/1 O 10.4.7.0/24 [110/2] via 10.10.24.4, 00:03:02, FastEthernet0/1 O 10.4.4.0/24 [110/2] via 10.10.24.4, 00:03:02, FastEthernet0/1 O 10.4.4.0/22 is a summary, 00:03:02, Null0 O 10.4.5.0/24 [110/2] via 10.10.24.4, 00:03:02, FastEthernet0/1 O IA 10.5.3.0/24 [110/3] via 10.10.123.3, 00:03:02, FastEthernet0/0 O IA 10.5.2.0/24 [110/3] via 10.10.123.3, 00:03:02, FastEthernet0/0 O IA 10.5.1.0/24 [110/3] via 10.10.123.3, 00:03:02, FastEthernet0/0 O IA 10.5.0.0/24 [110/3] via 10.10.123.3, 00:03:02, FastEthernet0/0 C 10.10.24.0/24 is directly connected, FastEthernet0/1 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 00:03:02, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.123.1, 00:03:02, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 00:03:03, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.123.1, 00:03:03, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.123.1, 00:03:03, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.123.1, 00:03:03, FastEthernet0/0 After Route Summarization: R2#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 9 subnets, 2 masks O 10.4.6.0/24 [110/2] via 10.10.24.4, 00:43:59, FastEthernet0/1 O 10.4.7.0/24 [110/2] via 10.10.24.4, 00:43:59, FastEthernet0/1 O 10.4.4.0/24 [110/2] via 10.10.24.4, 00:43:59, FastEthernet0/1 O 10.4.4.0/22 is a summary, 00:43:59, Null0 O 10.4.5.0/24 [110/2] via 10.10.24.4, 00:43:59, FastEthernet0/1 O IA 10.5.0.0/22 [110/3] via 10.10.123.3, 00:10:24, FastEthernet0/0 C 10.10.24.0/24 is directly connected, FastEthernet0/1 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 00:43:59, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 00:43:59, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 00:00:57, FastEthernet0/0 R2#
Let’s see the routing tables on R4 and verify end-to-end connectivity.
Before Route Summarization: R4#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/24 is subnetted, 11 subnets C 10.4.6.0 is directly connected, Loopback6 C 10.4.7.0 is directly connected, Loopback7 C 10.4.4.0 is directly connected, Loopback4 C 10.4.5.0 is directly connected, Loopback5 O IA 10.5.3.0 [110/4] via 10.10.24.2, 00:28:53, FastEthernet0/0 O IA 10.5.2.0 [110/4] via 10.10.24.2, 00:27:46, FastEthernet0/0 O IA 10.5.1.0 [110/4] via 10.10.24.2, 00:27:46, FastEthernet0/0 O IA 10.5.0.0 [110/4] via 10.10.24.2, 00:27:56, FastEthernet0/0 C 10.10.24.0 is directly connected, FastEthernet0/0 O IA 10.10.35.0 [110/3] via 10.10.24.2, 00:30:27, FastEthernet0/0 O IA 10.10.123.0 [110/2] via 10.10.24.2, 00:30:57, FastEthernet0/0 O E2 192.168.0.0/24 [110/20] via 10.10.24.2, 00:29:24, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.1.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.2.0/24 [110/20] via 10.10.24.2, 00:29:29, FastEthernet0/0 O E2 192.168.3.0/24 [110/20] via 10.10.24.2, 00:29:31, FastEthernet0/0 After Route Summarization: R4#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 8 subnets, 2 masks C 10.4.6.0/24 is directly connected, Loopback6 C 10.4.7.0/24 is directly connected, Loopback7 C 10.4.4.0/24 is directly connected, Loopback4 C 10.4.5.0/24 is directly connected, Loopback5 O IA 10.5.0.0/22 [110/4] via 10.10.24.2, 00:12:19, FastEthernet0/0 C 10.10.24.0/24 is directly connected, FastEthernet0/0 O IA 10.10.35.0/24 [110/3] via 10.10.24.2, 01:41:58, FastEthernet0/0 O IA 10.10.123.0/24 [110/2] via 10.10.24.2, 01:42:28, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.24.2, 01:41:00, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.24.2, 00:02:51, FastEthernet0/0 R4# R4#ping 192.168.1.1 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 192.168.1.1, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 60/64/84 ms R4#ping 10.5.1.1 Type escape sequence to abort. Sending 5, 100-byte ICMP Echos to 10.5.1.1, timeout is 2 seconds: !!!!! Success rate is 100 percent (5/5), round-trip min/avg/max = 52/64/88 ms
So far we have seen that when route summarization is configured , either type inter-area or external, it advertise summary route and suppress advertisement of specific network advertisements.
Another point to note is, OSPF router advertise summary routes only if it is receiving advertisement for atleast one route, which falls within the summary network range.
R5 is sending LSA advertisements for networks (10.5.0.0/24, 10.5.1.0/24, 10.5.2.0/24 and 10.5.3.0/24) and R3 is sending a single summary route (10.5.0.0/22) advertisement for those networks.
These Loopback interfaces are simulating different 10.5.x.x networks connected to R5. R5#sh ip int brief Interface IP-Address OK? Method Status Protocol FastEthernet0/0 10.10.35.5 YES manual up up FastEthernet0/1 unassigned YES unset up up Loopback0 10.5.0.1 YES manual up up Loopback1 10.5.1.1 YES manual up up Loopback2 10.5.2.1 YES manual up up Loopback3 10.5.3.1 YES manual up up R5#conf t Enter configuration commands, one per line. End with CNTL/Z. R5(config)#int l0 R5(config-if)#shut R5(config-if)#int l1 R5(config-if)# *Mar 1 04:36:28.214: %LINK-5-CHANGED: Interface Loopback0, changed state to administratively down *Mar 1 04:36:29.214: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to down R5(config-if)#shut R5(config-if)#int l2 R5(config-if)# *Mar 1 04:36:33.582: %LINK-5-CHANGED: Interface Loopback1, changed state to administratively down *Mar 1 04:36:34.582: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback1, changed state to down R5(config-if)#shut R5(config-if)# *Mar 1 04:36:37.922: %LINK-5-CHANGED: Interface Loopback2, changed state to administratively down *Mar 1 04:36:38.922: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback2, changed state to down R5(config-if)# Loopback 0,1 and 2 are shutdown now.
See routing table on R3, It has route for 10.5.3.0/24 only now, but still sending advertisement for summary route 10.5.0.0/22.
R3#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 6 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 01:24:03, FastEthernet0/0 O 10.5.3.0/24 [110/2] via 10.10.35.5, 01:24:03, FastEthernet0/1 O 10.5.0.0/22 is a summary, 01:24:03, Null0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 01:24:03, FastEthernet0/0 C 10.10.35.0/24 is directly connected, FastEthernet0/1 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 01:24:03, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 01:14:35, FastEthernet0/0
Routing table on R2, it is still receiving summary advertisement from R3.
R2#show ip route | b Gateway
Gateway of last resort is not set
10.0.0.0/8 is variably subnetted, 9 subnets, 2 masks
O 10.4.6.0/24 [110/2] via 10.10.24.4, 02:00:05, FastEthernet0/1
O 10.4.7.0/24 [110/2] via 10.10.24.4, 02:00:05, FastEthernet0/1
O 10.4.4.0/24 [110/2] via 10.10.24.4, 02:00:05, FastEthernet0/1
O 10.4.4.0/22 is a summary, 02:00:05, Null0
O 10.4.5.0/24 [110/2] via 10.10.24.4, 02:00:05, FastEthernet0/1
O IA 10.5.0.0/22 [110/3] via 10.10.123.3, 01:26:30, FastEthernet0/0
C 10.10.24.0/24 is directly connected, FastEthernet0/1
O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 02:00:05, FastEthernet0/0
C 10.10.123.0/24 is directly connected, FastEthernet0/0
O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 02:00:05, FastEthernet0/0
O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 01:17:02, FastEthernet0/0
Let’s shutdown interface loopback 3 also on R5.
R5(config-if)#int l3 R5(config-if)#shut R5(config-if)# *Mar 1 05:09:59.566: %LINK-5-CHANGED: Interface Loopback3, changed state to administratively down *Mar 1 05:10:00.566: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback3, changed state to down R5(config-if)#
If we see routing table on R3.It has lost all routes for 10.5.x.x networks, and now it will not send advertisement for summary route.
R3#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 4 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 01:36:57, FastEthernet0/0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 01:36:57, FastEthernet0/0 C 10.10.35.0/24 is directly connected, FastEthernet0/1 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 01:36:57, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 01:27:30, FastEthernet0/0 R2#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 8 subnets, 2 masks O 10.4.6.0/24 [110/2] via 10.10.24.4, 02:11:46, FastEthernet0/1 O 10.4.7.0/24 [110/2] via 10.10.24.4, 02:11:46, FastEthernet0/1 O 10.4.4.0/24 [110/2] via 10.10.24.4, 02:11:46, FastEthernet0/1 O 10.4.4.0/22 is a summary, 02:11:46, Null0 O 10.4.5.0/24 [110/2] via 10.10.24.4, 02:11:46, FastEthernet0/1 C 10.10.24.0/24 is directly connected, FastEthernet0/1 O IA 10.10.35.0/24 [110/2] via 10.10.123.3, 02:11:46, FastEthernet0/0 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 02:11:46, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 01:28:43, FastEthernet0/0 R2#show ip route 10.5.0.0 % Subnet not in table R2#
Enable all Loopback interfaces on R5.
R5(config-if)#int l0 R5(config-if)#no shut R5(config-if)#int l1 R5(config-if)#no shut R5(config-if)# *Mar 1 05:20:26.106: %LINK-3-UPDOWN: Interface Loopback0, changed state to up *Mar 1 05:20:27.106: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback0, changed state to up R5(config-if)#int l2 R5(config-if)#no shu *Mar 1 05:20:28.898: %LINK-3-UPDOWN: Interface Loopback1, changed state to up *Mar 1 05:20:29.898: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback1, changed state to up R5(config-if)#no shut R5(config-if)#int l3 R5(config-if)#no shut R5(config-if)# *Mar 1 05:20:32.470: %LINK-3-UPDOWN: Interface Loopback2, changed state to up *Mar 1 05:20:33.470: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback2, changed state to up R5(config-if)# *Mar 1 05:20:35.922: %LINK-3-UPDOWN: Interface Loopback3, changed state to up *Mar 1 05:20:36.922: %LINEPROTO-5-UPDOWN: Line protocol on Interface Loopback3, changed state to up R5(config-if)#do sh ip int brief Interface IP-Address OK? Method Status Protocol FastEthernet0/0 10.10.35.5 YES manual up up FastEthernet0/1 unassigned YES unset up up Loopback0 10.5.0.1 YES manual up up Loopback1 10.5.1.1 YES manual up up Loopback2 10.5.2.1 YES manual up up Loopback3 10.5.3.1 YES manual up up R5(config-if)#
Now R3 has routes for all those networks and sending advertisement for summary address into Backbone Area.
R3#show ip route | b Gateway Gateway of last resort is not set 10.0.0.0/8 is variably subnetted, 9 subnets, 2 masks O IA 10.4.4.0/22 [110/3] via 10.10.123.2, 01:46:59, FastEthernet0/0 O 10.5.3.0/24 [110/2] via 10.10.35.5, 00:00:31, FastEthernet0/1 O 10.5.2.0/24 [110/2] via 10.10.35.5, 00:00:31, FastEthernet0/1 O 10.5.1.0/24 [110/2] via 10.10.35.5, 00:00:31, FastEthernet0/1 O 10.5.0.0/24 [110/2] via 10.10.35.5, 00:00:41, FastEthernet0/1 O 10.5.0.0/22 is a summary, 00:00:41, Null0 O IA 10.10.24.0/24 [110/2] via 10.10.123.2, 01:46:59, FastEthernet0/0 C 10.10.35.0/24 is directly connected, FastEthernet0/1 C 10.10.123.0/24 is directly connected, FastEthernet0/0 O E2 192.168.16.0/24 [110/20] via 10.10.123.1, 01:46:59, FastEthernet0/0 O E2 192.168.0.0/22 [110/20] via 10.10.123.1, 01:37:31, FastEthernet0/0 R3#
Did you notice this route on R3?
O 10.5.0.0/22 is a summary, 00:00:41, Null0
This is called a discard route.
Prior to Cisco IOS Software Release 12.1(6), it was recommended to manually configure, on the ABR, a discard static route for the summary address in order to prevent possible routing loops. For the summary route shown above, you can use this command:
ip route 10.5.0.0 255.255.252.0 null0
In IOS 12.1(6) and higher, the discard route is automatically generated by default. If for any reason you don’t want to use this discard route, you can configure the following commands under router ospf:
[no] discard-route internal
or
[no] discard-route external