DynagenでCCIEを目指す
20100408 RIPng 複数プロセスの起動
最終更新:
it_certification
-
view
目的
- RIPngの基本的な使い方を確認します。
構成
- 設定概要
- RIPngでルーティングします。
- RIPngはFOOとBAAの2つのプロセスを使用します。
- 初期設定時では不備があるため、正しくルーティングする事はできません。
- 構成図

- netファイル
ghostios = True sparsemem = True model = 3620 [localhost] [[3620]] image = C:\Program Files\Dynamips\images\c3620-j1s3-mz.123-18.bin ram = 256 [[ROUTER R1]] e0/0 = R2 e0/0 [[ROUTER R2]] e0/1 = R3 e0/1 e0/2 = R4 e0/2 [[ROUTER R3]] [[ROUTER R4]]
- 初期設定 R1
! version 12.3 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R1 ! boot-start-marker boot-end-marker ! ! no aaa new-model ip subnet-zero ! ! ! ip cef ipv6 unicast-routing ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Ethernet0/0 no ip address full-duplex ipv6 address 2000::1/116 ipv6 rip BAA enable ipv6 rip FOO enable ! interface Ethernet0/1 no ip address full-duplex ipv6 address 2000::101:1/116 ipv6 rip FOO enable no keepalive ! interface Ethernet0/2 no ip address full-duplex ipv6 address 2000::201:1/116 ipv6 rip BAA enable no keepalive ! interface Ethernet0/3 no ip address shutdown half-duplex ! ip http server ip classless ! ! ipv6 router rip FOO ! ipv6 router rip BAA ! ! ! ! ! ! ! line con 0 line aux 0 line vty 0 4 ! ! end
- 初期設定 R2
! version 12.3 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R2 ! boot-start-marker boot-end-marker ! ! no aaa new-model ip subnet-zero ! ! ! ip cef ipv6 unicast-routing ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Ethernet0/0 no ip address full-duplex ipv6 address 2000::2/116 ipv6 rip BAA enable ipv6 rip FOO enable ! interface Ethernet0/1 no ip address full-duplex ipv6 address 2000::102:2/116 ipv6 rip FOO enable ! interface Ethernet0/2 no ip address full-duplex ipv6 address 2000::202:2/116 ipv6 rip BAA enable ! interface Ethernet0/3 no ip address shutdown half-duplex ! ip http server ip classless ! ! ipv6 router rip FOO ! ipv6 router rip BAA ! ! ! ! ! ! ! line con 0 line aux 0 line vty 0 4 ! ! end
- 初期設定 R3
! version 12.3 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R3 ! boot-start-marker boot-end-marker ! ! no aaa new-model ip subnet-zero ! ! ! ip cef ipv6 unicast-routing ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Ethernet0/0 no ip address shutdown half-duplex ! interface Ethernet0/1 no ip address full-duplex ipv6 address 2000::102:3/116 ipv6 rip FOO enable ! interface Ethernet0/2 no ip address shutdown half-duplex ! interface Ethernet0/3 no ip address shutdown half-duplex ! ip http server ip classless ! ! ipv6 router rip FOO ! ! ! ! ! ! ! line con 0 line aux 0 line vty 0 4 ! ! end
- 初期設定 R4
! version 12.3 service timestamps debug datetime msec service timestamps log datetime msec no service password-encryption ! hostname R4 ! boot-start-marker boot-end-marker ! ! no aaa new-model ip subnet-zero ! ! ! ip cef ipv6 unicast-routing ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! interface Ethernet0/0 no ip address shutdown half-duplex ! interface Ethernet0/1 no ip address shutdown half-duplex ! interface Ethernet0/2 no ip address full-duplex ipv6 address 2000::202:4/116 ipv6 rip BAA enable ! interface Ethernet0/3 no ip address shutdown half-duplex ! ip http server ip classless ! ! ipv6 router rip BAA ! ! ! ! ! ! ! line con 0 line aux 0 line vty 0 4 ! ! end
検証1 プロセス分離方法の確認
- ルーティングテーブルの確認
初期設定の状態では、想定通りのルーティングができていない事を確認します。
R3では本来知らないはずのルート2000::201:0/116が見られます。また、R4では本来知っているはずのルート2000::201:0/116が見られません。
R3では本来知らないはずのルート2000::201:0/116が見られます。また、R4では本来知っているはずのルート2000::201:0/116が見られません。
R3#show ipv6 route rip IPv6 Routing Table - 7 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::101:0/116 [120/3] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::201:0/116 [120/3] <- RIPng BAAに属す、本来テーブルに載らないルート via FE80::CE01:8FF:FE10:1, Ethernet0/1 R4#show ipv6 route rip IPv6 Routing Table - 5 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:2, Ethernet0/2
- RIP databaseの確認
R2のRIP databaseを確認すると、BAAに属すべきエントリが全てFOOの方に属しています。ルーティングテーブルが想定外の結果になった原因がR2のRIP databaseである事が確認できます。
R2#show ipv6 rip database RIP process "FOO", local RIB 2000::/116, metric 2 Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 178 secs 2000::101:0/116, metric 2, installed Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 178 secs 2000::102:0/116, metric 2 Ethernet0/1/FE80::CE02:8FF:FE10:1, expires in 156 secs 2000::201:0/116, metric 2, installed Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 169 secs RIP process "BAA", local RIB 2000::202:0/116, metric 2 Ethernet0/2/FE80::CE03:8FF:FE10:2, expires in 168 secs
- UDPポートの変更
想定外の結果となった原因は、BAAとFOOが同じUDPポート番号を使用している事です。まず、デフォルトで使用されているUDPポート番号を調べます。
R1#show ipv6 rip RIP process "BAA", port 521, multicast-group FF02::9, pid 107 <- 521番ポートを使用 Administrative distance is 120. Maximum paths is 16 Updates every 30 seconds, expire after 180 Holddown lasts 0 seconds, garbage collect after 120 Split horizon is on; poison reverse is off Default routes are not generated Periodic updates 40, trigger updates 2 Interfaces: Ethernet0/2 Ethernet0/0 Redistribution: None RIP process "FOO", port 521, multicast-group FF02::9, pid 108 <- 521番ポートを使用 Administrative distance is 120. Maximum paths is 16 Updates every 30 seconds, expire after 180 Holddown lasts 0 seconds, garbage collect after 120 Split horizon is on; poison reverse is off Default routes are not generated Periodic updates 40, trigger updates 0 Interfaces: Ethernet0/1 Ethernet0/0 Redistribution: None
RIPng BAAに対し、ポート番号と経路交換に使用するマルチキャストアドレスを指定します(マルチキャストアドレスはデフォルトで使用するアドレスで構いません)。この設定をRIPng BAAを使用する全ルータ(R1, R2, R4)に投入します。
R1(config)#ipv6 router rip BAA R1(config-rtr)#port 522 multicast-group FF02::9
- ルーティングテーブルの確認
ルーティングテーブルを確認します。R3からは本来知らないはずのルート2000::201:0/116が消えました。しかし、R4には依然2000::201:0/116が載りません。
R3#show ipv6 route rip IPv6 Routing Table - 6 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::101:0/116 [120/3] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R4#show ipv6 route rip IPv6 Routing Table - 5 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:2, Ethernet0/2
- RIP databaseの確認
2000::201:0/116がR4に載らない原因を調査します。R2のRIP databaseを確認したことろ、問題はないようです。
R2#show ipv6 rip database RIP process "FOO", local RIB 2000::/116, metric 2 Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 152 secs 2000::101:0/116, metric 2, installed Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 152 secs 2000::102:0/116, metric 2 Ethernet0/1/FE80::CE02:8FF:FE10:1, expires in 152 secs RIP process "BAA", local RIB 2000::/116, metric 2 Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 154 secs 2000::201:0/116, metric 2, installed Ethernet0/0/FE80::CE00:8FF:FE10:0, expires in 154 secs 2000::202:0/116, metric 2 Ethernet0/2/FE80::CE03:8FF:FE10:2, expires in 150 secs
- データベース消去後の確認
R2, R4のRIP databaseを消去します。
R2#clear ipv6 rip BAA R4#clear ipv6 rip BAA
RIP database消去後に、再度ルーティングテーブルを確認すると、2000::201:0/116が確認できました。なぜ、このような現象が生じたかは不明です。
R4#show ipv6 route rip IPv6 Routing Table - 6 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:2, Ethernet0/2 R 2000::201:0/116 [120/3] via FE80::CE01:8FF:FE10:2, Ethernet0/2
- パケットキャプチャによる確認
R2 e0/0を通過するパケットを確認します。RIPngのUDP521と522が確認できます。なお、522はデフォルトのポート番号でないせいか、Wiresharkは綺麗に成形して表示してくれませんでした。


検証2 再配送
- 再配送の設定
R3,R4間で通信できるよう、RIPngのプロセス間で再配送を定義します。R2に以下の設定を投入します。
R2(config)#ipv6 router rip FOO R2(config-rtr)#redistribute connected R2(config-rtr)#redistribute rip BAA R2(config-rtr)#exit R2(config)#ipv6 router rip BAA R2(config-rtr)#redi R2(config-rtr)#redistribute connected R2(config-rtr)#redistribute rip FOO
- ルーティングテーブルの確認
ルーティングテーブルを見ると、R3, R4が互いに疎通可能になっている事が確認できます。
R3#show ipv6 route rip IPv6 Routing Table - 8 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::101:0/116 [120/3] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::201:0/116 [120/3] via FE80::CE01:8FF:FE10:1, Ethernet0/1 R 2000::202:0/116 [120/2] <- R4へのルート via FE80::CE01:8FF:FE10:1, Ethernet0/1 R4#show ipv6 route rip IPv6 Routing Table - 8 entries Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP U - Per-user Static route I1 - ISIS L1, I2 - ISIS L2, IA - ISIS interarea, IS - ISIS summary O - OSPF intra, OI - OSPF inter, OE1 - OSPF ext 1, OE2 - OSPF ext 2 ON1 - OSPF NSSA ext 1, ON2 - OSPF NSSA ext 2 R 2000::/116 [120/2] via FE80::CE01:8FF:FE10:2, Ethernet0/2 R 2000::101:0/116 [120/3] via FE80::CE01:8FF:FE10:2, Ethernet0/2 R 2000::102:0/116 [120/2] <- R3へのルート via FE80::CE01:8FF:FE10:2, Ethernet0/2 R 2000::201:0/116 [120/3] via FE80::CE01:8FF:FE10:2, Ethernet0/2