カテゴリ:

今回はIPv6 RIPにおける経路の集約を行います。R1とR2はF0/0で接続されていて、Lo0と共にそれぞれリンクローカルアドレスを設定してあります。R2のLo0には集約で使うアドレスを4つ追加しました。

R1(config)#do sh ipv int b
FastEthernet0/0            [up/up]
    FE80::1
Loopback0                  [up/up]
    FE80::1

R2(config-if)#do sh ipv int b
FastEthernet0/0            [up/up]
    FE80::2
Loopback0                  [up/up]
    FE80::2
    2001:0:0:2::2
    2001:0:0:22::2
    2001:0:0:222::2
    2001:0:0:2222::2

R1とR2のF0/0でRIPを有効にします。

R1(config)#do sh run int f0/0
〜略〜
interface FastEthernet0/0
ipv6 address FE80::1 link-local
ipv6 rip RIP6 enable

R1(config)#do deb ipv rip
RIP Routing Protocol debugging is on
R1(config)#do sh ipv rip RIP6
RIP process "RIP6", port 521, multicast-group FF02::9, pid 246
     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 58, trigger updates 11
  Interfaces:
    Loopback0
    FastEthernet0/0
  Redistribution:
    None

R1のルーティングテーブルにR2のアドレスが表示されることが分かります。

R1(config-if)#do sh ipv rou rip
IPv6 Routing Table - 5 entries
Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP
       U - Per-user Static route, M - MIPv6
       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
       D - EIGRP, EX - EIGRP external
R   2001:0:0:2::/64 [120/2]
     via FE80::2, FastEthernet0/0
R   2001:0:0:22::/64 [120/2]
     via FE80::2, FastEthernet0/0
R   2001:0:0:222::/64 [120/2]
     via FE80::2, FastEthernet0/0
R   2001:0:0:2222::/64 [120/2]
     via FE80::2, FastEthernet0/0

4つのアドレスにpingを実行します。

R1(config)#do pin 2001:0:0:2::2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:2::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/10/28 ms
R1(config)#do pin 2001:0:0:22::2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:22::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/8/12 ms
R1(config)#do pin 2001:0:0:222::2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:222::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/8 ms
R1(config)#do pin 2001:0:0:2222::2

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:2222::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/7/8 ms

pingの実行が確認できたので集約を行います。利用するのはipv6 rip summary-addressコマンドで、ここでは単純に/64を/48に集約します。コマンドを設定するのは集約アドレスを流したいインターフェースで、この場合はR2のF0/0上で利用します。

R2(config-if)#int f0/0
R2(config-if)#ipv rip RIP6 summary-address 2001::/48

RIPでのこの様な設定はOSPFやEIGRPと違い、反映に時間がかかります。CCIE Lab受験時など早く結果を得たい時にはインターフェースを一度shutしルーティングテーブルを消してからno shutします。

設定後、確認すると下記のようにすっきりした形になります。

R1(config)#do sh ipv rou rip
IPv6 Routing Table - 2 entries
Codes: C - Connected, L - Local, S - Static, R - RIP, B - BGP
       U - Per-user Static route, M - MIPv6
       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
       D - EIGRP, EX - EIGRP external
R   2001::/48 [120/2]
     via FE80::2, FastEthernet0/0

pingを実行します。ここではforeachを使っています。CCIE Lab受験時には多くのアドレスに対してpingを実行しますので、foreachの使い方を覚えおくと便利です。

R1(tcl)#foreach router {
+>(tcl)#2001:0:0:2::2
+>(tcl)#2001:0:0:22::2
+>(tcl)#2001:0:0:222::2
+>(tcl)#2001:0:0:2222::2
+>(tcl)#} { puts [ exec "ping $router"]}

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:2::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 8/9/16 ms

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:22::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/8/12 ms

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:222::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/6/8 ms

Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 2001:0:0:2222::2, timeout is 2 seconds:
!!!!!
Success rate is 100 percent (5/5), round-trip min/avg/max = 4/6/8 ms

R1(tcl)#tclquit