不連続サブネットとOSPF(その2)

不連続サブネットとOSPF(その1)」では、下図のネットワークをOSPFで構築しました。

各ルータで、「show ip route」コマンドを実行します。

●R1ルータの「show ip route」出力

R1#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       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, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

     10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       10.0.0.0/30 is directly connected, Serial0/0/0
L       10.0.0.2/32 is directly connected, Serial0/0/0
     20.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       20.0.0.0/30 is directly connected, Serial0/0/1
L       20.0.0.1/32 is directly connected, Serial0/0/1
     30.0.0.0/30 is subnetted, 1 subnets
O       30.0.0.0/30 [110/3124] via 10.0.0.1, 00:15:36, Serial0/0/0
                    [110/3124] via 20.0.0.2, 00:15:36, Serial0/0/1
     172.16.0.0/24 is subnetted, 4 subnets
O       172.16.0.0/24 [110/1563] via 10.0.0.1, 00:16:06, Serial0/0/0
O       172.16.1.0/24 [110/1563] via 10.0.0.1, 00:17:01, Serial0/0/0
O       172.16.2.0/24 [110/1563] via 20.0.0.2, 00:15:36, Serial0/0/1
O       172.16.3.0/24 [110/1563] via 20.0.0.2, 00:15:36, Serial0/0/1

●R2ルータの「show ip route」出力

R2#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       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, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

     10.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       10.0.0.0/30 is directly connected, Serial0/0/0
L       10.0.0.1/32 is directly connected, Serial0/0/0
     20.0.0.0/30 is subnetted, 1 subnets
O       20.0.0.0/30 [110/3124] via 10.0.0.2, 00:17:04, Serial0/0/0
                    [110/3124] via 30.0.0.2, 00:17:04, Serial0/0/1
     30.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       30.0.0.0/30 is directly connected, Serial0/0/1
L       30.0.0.1/32 is directly connected, Serial0/0/1
     172.16.0.0/16 is variably subnetted, 6 subnets, 2 masks
C       172.16.0.0/24 is directly connected, GigabitEthernet0/0
L       172.16.0.10/32 is directly connected, GigabitEthernet0/0
C       172.16.1.0/24 is directly connected, GigabitEthernet0/1
L       172.16.1.10/32 is directly connected, GigabitEthernet0/1
O       172.16.2.0/24 [110/1563] via 30.0.0.2, 00:17:04, Serial0/0/1
O       172.16.3.0/24 [110/1563] via 30.0.0.2, 00:17:04, Serial0/0/1

●R3ルータの「show ip route」出力

R3#show ip route
Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP
       D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area
       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2
       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, ia - IS-IS inter area
       * - candidate default, U - per-user static route, o - ODR
       P - periodic downloaded static route

Gateway of last resort is not set

     10.0.0.0/30 is subnetted, 1 subnets
O       10.0.0.0/30 [110/3124] via 20.0.0.1, 00:19:00, Serial0/0/0
                    [110/3124] via 30.0.0.1, 00:19:00, Serial0/0/1
     20.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       20.0.0.0/30 is directly connected, Serial0/0/0
L       20.0.0.2/32 is directly connected, Serial0/0/0
     30.0.0.0/8 is variably subnetted, 2 subnets, 2 masks
C       30.0.0.0/30 is directly connected, Serial0/0/1
L       30.0.0.2/32 is directly connected, Serial0/0/1
     172.16.0.0/16 is variably subnetted, 6 subnets, 2 masks
O       172.16.0.0/24 [110/1563] via 30.0.0.1, 00:19:00, Serial0/0/1
O       172.16.1.0/24 [110/1563] via 30.0.0.1, 00:19:00, Serial0/0/1
C       172.16.2.0/24 is directly connected, GigabitEthernet0/0
L       172.16.2.10/32 is directly connected, GigabitEthernet0/0
C       172.16.3.0/24 is directly connected, GigabitEthernet0/1
L       172.16.3.10/32 is directly connected, GigabitEthernet0/1

 各ルータの「show ip route」の出力から分かるように、すべてのサブネットがルーティングテーブル上にあることが確認できます。

 OSPFでは、デフォルトでルートの自動集約を行わないため、不連続な配置のサブネットにおいて、問題が発生し難いことが確認できました。

演習ファイルのダウンロード

 ネットワークの構成を Packet Tracer で一から設定していくのは大変かと思います。「ダウンロード」から演習で使用するファイルのダウンロードができます。ファイルは、McAfeeインターネットセキュリティでウイルスチェックをしておりますが、ダウンロードは自己責任でお願いいたします。

関連コンテンツ

YouTube解説