EIGRP



●前置き

 個人でルータ等をオークションで入手し、キャリアデザイン塾さんのサイトを参照して自習用として、また、その結果を記載しています。
 キャリアデザイン塾はルータの設定を一切したことのない人にとっては非常に有用なサイトです。
 みなさんも是非参照してチャレンジしてはいかがでしょうか。CCNA資格取得講習等に高いお金を支払うより、そのお金で中古ルータを数台購入してキャリアデザイン塾のサイトを利用する方がおおいに有用です。

●基本ネットワーク

 ネットワーク構成は下記の通りです。

experiment-eigrp1.png

Router_C、Router_Dに着目します。

 設定条件は
  • 構成図のネットワークをEIGRPで構築
  • ルーティングテーブルの確認
  • EIGRPルーティングアップデートの確認
 EIGRPは、IGRPと同様にCisco Systemsが開発した独自のルーティングプロトコルです。ディスタンスベクタープロトコルとリンクステートプロトコルの特徴を併せ持つので、ハイブリッド型ルーティングプロトコルと分類することもできます。コンバージェンステクノロジーにはDUALアルゴリズムを使い、ループのない動作を保証します。
 IGRPと同様、自律システム(AS)内でルーティングアップデートを交換します。異なるASとはルーティングアップデートを交換しません。

 経路計算のメトリックとして、「帯域幅」「遅延」「負荷」「信頼性」「MTU」の5つを使います。IGRPと同じです。

 メトリックの計算式は、

  メトリック=[K1×帯域幅 + (K2 × 帯域幅) ÷ (256 - 負荷) + (K3 × 遅延)] × [K5 ÷ (信頼度 + K4)] × 256

係数であるK1~K5のデフォルト値は

  K1=1,K2=0,K3=1,K4=0,K5=0
になっています。なのでデフォルトでは、

メトリック = 帯域幅 + 遅延

になります。もちろんこの時の帯域幅は、10の七乗を宛先までの最小帯域幅で割った数です。遅延は、宛先までの遅延合計を10で割った数です。

 設定条件から、設定確認項目を洗い出します。
  1. 各ルータにホスト名、IPアドレス設定
  2. EIGRPの設定
  3. ルーティングテーブル確認
  4. EIGRPのルーティングアップデート動作確認
  5. Router_A--Loopback0間での疎通確認
 各ルータの設定を実施します。
  1. 各ルータにホスト名、IPアドレス設定
  2. EIGRPの設定
の作業を行います。RouterAとRouterBにホスト名、インタフェース設定、EIGRP設定を行います。
Router_Cの設定内容
!
hostname Router_C
!
interface Loopback0
 ip address 10.1.1.1 255.255.255.0
!
interface Loopback1
 ip address 10.1.2.1 255.255.255.128
!
interface Loopback2
 ip address 10.1.2.129 255.255.255.192
!
interface Loopback3
 ip address 10.1.2.193 255.255.255.224
!
interface FastEthernet0
 ip address 172.40.1.2 255.255.0.0
 duplex auto
 speed auto
!
interface FastEthernet1
 ip address 172.42.1.1 255.255.0.0
 duplex auto
 speed auto
!
router eigrp 1
 network 10.1.1.0 0.0.0.255
 network 10.1.2.0 0.0.0.127
 network 10.1.2.128 0.0.0.63
 network 10.1.2.192 0.0.0.31
 network 172.42.0.0
!
Router_Dの設定内容
!
hostname Router_D
!
interface FastEthernet0
 ip address 172.41.1.2 255.255.0.0
 duplex auto
 speed auto
!
interface FastEthernet1
 ip address 172.42.1.2 255.255.0.0
 duplex auto
 speed auto
!
router eigrp 1
 network 172.41.0.0
 network 172.42.0.0
!
 バックグランドで動いているテクノロジーは全然別のものですが、設定自体は、IGRPと同じです。ルーティングプロセスの起動にはAS番号を指定します。
 一点違うのは、ルータコンフィグレーションモードでの「network」コマンドの使い方です。
  • クラスフルのネットワークアドレスで指定
  • ワイルドカードマスクを使い指定
の二種類です。クラスフルについては、RIP、IGRPと同じです。そのネットワークに含まれるインタフェースで各ルーティングプロセスが動作します。
 クラスフルの指定ですと範囲が広すぎますので、EIGRPを動かしたくないインタフェースでも動作してしまう可能性があります。その為に、ワイルドカードマスクを使用し個別のインタフェースで動作するよう指定できます。
 「bandwidth」の設定を忘れずに行います。EIGRPはBandwidthを見てメトリックを計算するので、忘れずに設定する必要があります。

 EIGRPの設定確認をします。
  1. ルーティングテーブル確認
  2. EIGRPのルーティングアップデート動作確認
  3. Router_A--Loopback0間での疎通確認
の作業を行います。まずは各ルータのルーティングプロセスを確認します。確認コマンドは「show ip protocols」を使用します。
Router_Cの「show ip protocols」
Router_C#sh ip protocols
Routing Protocol is "eigrp 1"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Default networks flagged in outgoing updates
  Default networks accepted from incoming updates
  EIGRP-IPv4 Protocol for AS(1)
    Metric weight K1=1, K2=0, K3=1, K4=0, K5=0
    NSF-aware route hold timer is 240
    Router-ID: 10.1.2.193
    Topology : 0 (base) 
      Active Timer: 3 min
      Distance: internal 90 external 170
      Maximum path: 4
      Maximum hopcount 100
      Maximum metric variance 1
  Automatic Summarization: disabled
  Maximum path: 4
  Routing for Networks:
    10.1.1.0/24
    10.1.2.0/25
    10.1.2.128/26
    10.1.2.192/27
    172.42.0.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    172.42.1.2            90      01:07:45
  Distance: internal 90 external 170
Router_Dの「show ip protocols」
Router_D#sh ip protocols 
*** IP Routing is NSF aware ***
Routing Protocol is "eigrp 1"
  Outgoing update filter list for all interfaces is not set
  Incoming update filter list for all interfaces is not set
  Default networks flagged in outgoing updates
  Default networks accepted from incoming updates
  Redistributing: eigrp 1
  EIGRP-IPv4 Protocol for AS(1)
    Metric weight K1=1, K2=0, K3=1, K4=0, K5=0
    NSF-aware route hold timer is 240
    Router-ID: 172.42.1.2
    Topology : 0 (base) 
      Active Timer: 3 min
      Distance: internal 90 external 170
      Maximum path: 4
      Maximum hopcount 100
      Maximum metric variance 1
  Automatic Summarization: disabled
  Maximum path: 4
  Routing for Networks:
    172.41.0.0
    172.42.0.0
  Routing Information Sources:
    Gateway         Distance      Last Update
    172.42.1.1            90      01:01:41
  Distance: internal 90 external 170
 緑字部分を確認します。
   「eigrp 1
 ここでAS番号が1でルーティングプロセスを起動していることが確認できます。
   「Routing for Networks:
    172.41.0.0
    172.42.0.0
を確認することで、ルータコンフィグレーションモードでの「network」コマンドで指定したネットワークが確認できます。

 次に経路情報が交換されているか、ルーティングテーブルを確認します。
Router_Cの「show ip route」
Router_C#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override
Gateway of last resort is not set
      10.0.0.0/8 is variably subnetted, 8 subnets, 5 masks
C        10.1.1.0/24 is directly connected, Loopback0
L        10.1.1.1/32 is directly connected, Loopback0
C        10.1.2.0/25 is directly connected, Loopback1
L        10.1.2.1/32 is directly connected, Loopback1
C        10.1.2.128/26 is directly connected, Loopback2
L        10.1.2.129/32 is directly connected, Loopback2
C        10.1.2.192/27 is directly connected, Loopback3
L        10.1.2.193/32 is directly connected, Loopback3
D     172.41.0.0/16 [90/30720] via 172.42.1.2, 01:31:49, FastEthernet1
      172.42.0.0/16 is variably subnetted, 2 subnets, 2 masks
C        172.42.0.0/16 is directly connected, FastEthernet1
L        172.42.1.1/32 is directly connected, FastEthernet1
Router_Dの「show ip route」
Router_D#sh 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
       i - IS-IS, su - IS-IS summary, 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, H - NHRP, l - LISP
       + - replicated route, % - next hop override
Gateway of last resort is not set
      10.0.0.0/8 is variably subnetted, 4 subnets, 4 masks
D        10.1.1.0/24 [90/156160] via 172.42.1.1, 01:30:49, FastEthernet1
D        10.1.2.0/25 [90/156160] via 172.42.1.1, 01:28:45, FastEthernet1
D        10.1.2.128/26 [90/156160] via 172.42.1.1, 01:28:37, FastEthernet1
D        10.1.2.192/27 [90/156160] via 172.42.1.1, 01:28:07, FastEthernet1
      172.41.0.0/16 is variably subnetted, 2 subnets, 2 masks
C        172.41.0.0/16 is directly connected, FastEthernet0
L        172.41.1.2/32 is directly connected, FastEthernet0
      172.42.0.0/16 is variably subnetted, 2 subnets, 2 masks
C        172.42.0.0/16 is directly connected, FastEthernet1
L        172.42.1.2/32 is directly connected, FastEthernet1
 緑字部分
D     172.41.0.0/16 [90/30720] via 172.42.1.2, 01:31:49, FastEthernet1
を確認します。先頭の「D」は、EIGRPを表しています、DUALのDです。
 また、メトリックの値「30720」がIGRPと比べて大きいです。これはメトリック計算の最後に256を掛けるからです。IGRPは24ビット、EIGRPは32ビットでメトリックを表します。8ビットの差があるので、256を掛けます。

 次に、実際のアップデートをリアルタイムに確認します。
#   Router_C#debug ip eigrp \
 何も表示されません。EIGRPはIGRPと違い定期的なアップデートは行いません。あくまでトポロジーの変更があった場合に差分アップデートを行います。
 コンバージェンス後には、アップデート交換をしない為、帯域を圧迫しません。
 一旦、RouterAのFastEthernet 0/0をリンクダウン後すぐにアップさせます。その時のRouterBでの「debug ip eigrp」を確認します。

.Apr 18 00:32:44.848: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet1, changed state to down
.Apr 18 00:32:45.216: %DUAL-5-NBRCHANGE: EIGRP-IPv4 1: Neighbor 172.42.1.2 (FastEthernet1) is down: holding time expired
.Apr 18 00:32:45.848: %LINK-3-UPDOWN: Interface FastEthernet1, changed state to down
.Apr 18 00:33:34.141: %LINK-3-UPDOWN: Interface FastEthernet1, changed state to up
.Apr 18 00:33:35.141: %LINEPROTO-5-UPDOWN: Line protocol on Interface FastEthernet1, changed state to up
.Apr 18 00:33:36.869: %DUAL-5-NBRCHANGE: EIGRP-IPv4 1: Neighbor 172.42.1.2 (FastEthernet1) is up: new adjacency
.Apr 18 00:33:38.877: EIGRP-IPv4(1): table(default): 10.1.1.0/24 - do advertise out FastEthernet1
.Apr 18 00:33:38.877: EIGRP-IPv4(1): table(default): 10.1.2.0/25 - do advertise out FastEthernet1
.Apr 18 00:33:38.877: EIGRP-IPv4(1): table(default): 10.1.2.128/26 - do advertise out FastEthernet1
.Apr 18 00:33:38.877: EIGRP-IPv4(1): table(default): 10.1.2.192/27 - do advertise out FastEthernet1
.Apr 18 00:33:38.877: EIGRP-IPv4(1): table(default): 172.42.0.0/16 - do advertise out FastEthernet1
.Apr 18 00:33:38.885: EIGRP-IPv4(1): Int 172.41.0.0/16 M 30720 - 25600 5120 SM 28160 - 25600 2560
.Apr 18 00:33:38.885: EIGRP-IPv4(1): table(default): route installed for 172.41.0.0/16 (90/30720) origin(172.42.1.2)
.Apr 18 00:33:38.893: EIGRP-IPv4(1): Int 10.1.1.0/24 M 4294967295 - 25600 4294967295 SM 4294967295 - 25600 4294967295
.Apr 18 00:33:38.893: EIGRP-IPv4(1): Int 10.1.2.0/25 M 4294967295 - 25600 4294967295 SM 4294967295 - 25600 4294967295
.Apr 18 00:33:38.893: EIGRP-IPv4(1): Int 10.1.2.128/26 M 4294967295 - 25600 4294967295 SM 4294967295 - 25600 4294967295
.Apr 18 00:33:38.893: EIGRP-IPv4(1): Int 10.1.2.192/27 M 4294967295 - 25600 4294967295 SM 4294967295 - 25600 4294967295
.Apr 18 00:33:43.877: EIGRP-IPv4(1): table(default): 10.1.1.0/24 - do advertise out FastEthernet1
.Apr 18 00:33:43.877: EIGRP-IPv4(1): table(default): 10.1.2.0/25 - do advertise out FastEthernet1
.Apr 18 00:33:43.877: EIGRP-IPv4(1): table(default): 10.1.2.128/26 - do advertise out FastEthernet1
.Apr 18 00:33:43.877: EIGRP-IPv4(1): table(default): 10.1.2.192/27 - do advertise out FastEthernet1
.Apr 18 00:33:43.877: EIGRP-IPv4(1): table(default): 172.42.0.0/16 - do advertise out FastEthernet1

 リンクダウン、アップでEIGRPが動作していることが確認できます。リンクダウン時には、メトリックが無効な値「4294967295」になっています。リンクアップ時には、UPDATEを受信し経路を復活させているのが確認できます。

●リンク

 EIGRPとは
 EIGRPの5種類のパケット
 EIGRP - 複合メトリックの算出方法
 EIGRP - サクセサとフィージブルサクセサ
 EIGRP - 基本設定
 EIGRP - sh ip protocols / sh ip eigrp neighbors / sh ip eigrp int
 EIGRP - sh ip eigrp neighbors / sh ip eigrp topology / sh ip route / debug ip eigrp
 EIGRP - maximum-paths / variance / auto-summary / no auto-summary / passive-interface 設定
 
 

 EIGRPの基本設定
 ・show ip protocols
 ・debug eigrp packets
 ・show ip eigrp neighbors
 ・show ip eigrp topology
  【ルーターの種類】サクセサ、フィージブル・サクセサの説明有り。
  【メトリックの種類】フィージブル・ディスタンス(FD)、アドバタイズド・ディスタンス(AD)の説明有り。
 ・show ip eigrp topology all-links
 等
 EIGRPのパッシブインターフェース
 EIGRPの不等コスト・ロードバランシング
  負荷分散方法について記載有り。
  メトリックの計算方法について記載有り。
 EIGRPのタイマーの設定
  Helloインターバルとholdタイマーについて記載有り。
 NBMAネットワークにおけるEIGRPの設定
  スプリット・ホライズンによる通信断