RIPng デフォルトルートの配信 (ipv6 rip RIPng default-information only)





条件
・R5 から BB2 間のネットワークにて ipv6 をアドレッシングしてください。
・R5 にて次にアドレスで lo0 を作成してください。 2001:CC1E:1:5::5/64
・R3 にて下記のアドレスを追加してください。
2001:220:20:3::1/64
2001:222:22:2::1/64
2001:205:90:31::1/64
・すべての ipv6 インターフェースにて RIPng を有効にしてください。
・R3 にて R2 向けにデフォルトルートを生成してください
・R2 は上記 R3 の lo0 アドレスは見えないようにしてください。
・上記条件を達成するため、prefix-listを使用しないでください。またメトリックを変更しないでください。


まずは、ipv6 アドレッシングをするところまで設定しちゃいます。あと R5,R3 の lo インターフェースも。

R1
ipv6 unicast-routing

interface Serial1/0
 encapsulation frame-relay
 ipv6 address 2001:CC1E:1:125::1/64
 frame-relay map ipv6 2001:CC1E:1:125::2 102 broadcast
 frame-relay map ipv6 2001:CC1E:1:125::5 105 broadcast

R2
ipv6 unicast-routing

interface Serial1/0
 encapsulation frame-relay
 ipv6 address 2001:CC1E:1:125::2/64
 frame-relay map ipv6 2001:CC1E:1:125::1 201 broadcast
 frame-relay map ipv6 2001:CC1E:1:125::5 201 broadcast

interface Serial1/1
 ipv6 address 2001:CC1E:1:23::2/64

R3
ipv6 unicast-routing

interface Serial1/1
 ipv6 address 2001:CC1E:1:23::3/64

interface Fastethernet0/0
 ipv6 address 2001:CC1E:1:3::3/64

interface Loopback100
 ipv6 address 2001:220:20:3::1/64

interface Loopback101
 ipv6 address 2001:222:22:2::1/64

interface Loopback102
 ipv6 address 2001:205:90:31::1/64

R5
ipv6 unicast-routing

interface Serial1/0
 encap frame-relay
 ipv6 address 2001:CC1E:1:125::5/64
 frame-relay map ipv6 2001:CC1E:1:125::1 501 broadcast
 frame-relay map ipv6 2001:CC1E:1:125::2 501 broadcast

interface lo0
 ipv6 address 2001:CC1E:1:5::5/64

BB2
ipv6 unicast-routing

interface Fastethernet0/0
ipv6 address 2001:CC1E:1:3::10/64

というかんじですね。この辺はそらでできるようにせねば。。


で、次に RIPng も設定しちゃいます。
なぜかframe-relay上では link-local address も設定しているのでこちらも含めます。

R1
int s1/0
ipv6 address FE80::1 link-local
ipv6 rip RIPng enable

frame-relay map ipv6 FE80::2 102
frame-relay map ipv6 FE80::5 105

ipv6 router rip RIPng
no split-horizon

R2
int s1/0
ipv6 address FE80::2 link-local
ipv6 rip RIPng enable
frame-relay map ipv6 FE80::1 201
frame-relay map ipv6 FE80::5 201

int s1/1
ipv6 rip RIPng enable

R3
int s1/1
ipv6 rip RIPng enable

int f0/0
ipv6 rip RIPng enable

int lo100
ipv6 rip RIPng enable

int lo101
ipv6 rip RIPng enable

int lo102
ipv6 rip RIPng enable

R5
int s1/0
ipv6 address FE80::5 link-local
ipv6 rip RIPng enable
frame-relay map ipv6 FE80::1 501
frame-relay map ipv6 FE80::2 501

int lo0
ipv6 rip RIPng enable

BB2
int f0/0
ipv6 rip RIPng enable

というかんじで、追加します。忘れてはいけないのが、赤字で示しました split-horizon の無効化です。
R1 の s1/0 で split-horizon が有効化されていると R2 から入ってきた情報が R5 へ渡されません。(逆もしかり)

R5 にて sh ipv6 route を見るとこんな感じです。

R5#sh ipv6 route
IPv6 Routing Table - 12 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   ::/0 [120/4]
     via FE80::1, Serial1/0
R   2001:205:90:31::/64 [120/4]
     via FE80::1, Serial1/0
R   2001:220:20:3::/64 [120/4]
     via FE80::1, Serial1/0
R   2001:222:22:2::/64 [120/4]
     via FE80::1, Serial1/0
R   2001:CC1E:1:3::/64 [120/4]
     via FE80::1, Serial1/0
C   2001:CC1E:1:5::/64 [0/0]
     via ::, Loopback0
L   2001:CC1E:1:5::5/128 [0/0]
     via ::, Loopback0
R   2001:CC1E:1:23::/64 [120/3]
     via FE80::1, Serial1/0
C   2001:CC1E:1:125::/64 [0/0]
     via ::, Serial1/0
L   2001:CC1E:1:125::5/128 [0/0]
     via ::, Serial1/0
L   FE80::/10 [0/0]
     via ::, Null0
L   FF00::/8 [0/0]
     via ::, Null0


ほかに参照できるコマンドも載せておきます。


R5#sh ipv6 rip database
RIP process "RIPng", local RIB
 2001:205:90:31::/64, metric 4, installed
     Serial1/0/FE80::1, expires in 171 secs
 2001:220:20:3::/64, metric 4, installed
     Serial1/0/FE80::1, expires in 171 secs
 2001:222:22:2::/64, metric 4, installed
     Serial1/0/FE80::1, expires in 171 secs
 2001:CC1E:1:3::/64, metric 4, installed
     Serial1/0/FE80::1, expires in 171 secs
 2001:CC1E:1:5::/64, metric 3
     Serial1/0/FE80::1, expires in 171 secs
 2001:CC1E:1:23::/64, metric 3, installed
     Serial1/0/FE80::1, expires in 171 secs
 2001:CC1E:1:125::/64, metric 2
     Serial1/0/FE80::1, expires in 171 secs

R5#sh ipv6 rip
RIP process "RIPng", port 521, multicast-group FF02::9, pid 208
     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 391, trigger updates 10
  Interfaces:
    Serial1/0
    Loopback0
  Redistribution:
    None


ちなみにタイマーの設定は下記のように設定するようです。
くわしくは後日やりたい。

R5(config-rtr)#timers ?
<5-4294967295> Update period

R5(config-rtr)#timers 15
% Incomplete command.

R5(config-rtr)#timers 15 ?
<1-4294967295> Route timeout period

R5(config-rtr)#timers 15 45 ?
<0-4294967295> Route holddown period

R5(config-rtr)#timers 15 45 45 ?
<1-4294967295> Route garbage collection period

R5(config-rtr)#timers 15 45 45 60 ?



次に下記の条件を設定します。

・R3 にて R2 向けにデフォルトルートを生成してください
・R2 は上記 R3 の lo0 アドレスは見えないようにしてください。

デフォルトルートを設定するコマンドは下記のとおりです。

(config-if)# ipv6 rip RIPng default-information [originate | only]

originate か only どちらかを設定します。
originate だと デフォルトルート生成と個別のルートも配信します。
only だとデフォルトルートのみで他のルートは配信しません。

まず何も設定しないで R2 のルート確認します。


R2#sh ipv6 route rip
IPv6 Routing Table - 11 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   2001:205:90:31::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:220:20:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:222:22:2::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:5::/64 [120/3]
     via FE80::1, Serial1/0

それぞれ個別のルートは配信されていることがわかりますね。
で、ipv6 rip RIPng default-information originate を設定してみます。

R3
interface s1/1
ipv6 rip RIPng default-information originate


R2#sh ipv6 route rip
IPv6 Routing Table - 12 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   ::/0 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:205:90:31::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:220:20:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:222:22:2::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:5::/64 [120/3]
     via FE80::1, Serial1/0

sh ipv6 route を見てみると、::/0 でデフォルトルートが配信されていることがわかります。
はしょりますが、このルートは R5 でもちゃんと学習されます。

これだと他のルートも配信されますので、条件どおりになってません。
ということで only オプションにて設定してみます。

R3
interface s1/1
ipv6 rip RIPng defaut-information only

R2#sh ipv6 route
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   ::/0 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1

C   2001:CC1E:1:23::/64 [0/0]
     via ::, Serial1/1
L   2001:CC1E:1:23::2/128 [0/0]
     via ::, Serial1/1
C   2001:CC1E:1:125::/64 [0/0]
     via ::, Serial1/0
L   2001:CC1E:1:125::2/128 [0/0]
     via ::, Serial1/0
L   FE80::/10 [0/0]
     via ::, Null0
L   FF00::/8 [0/0]
     via ::, Null0

only オプションを設定すると、デフォルトルートだけが配信されていることがわかります。



ちなみに、 default-information を使用せずにデフォルトルートを配信するにはどうするか
設定してみたいと思います。

R3
ipv6 route ::/0 f0/0

ipv6 router rip RIPng
redistribute static metric 1

こんな感じですね。ipv4 と同じようにスタティックを設定して再配送してやります。
R2 にて ルーティングを見ると先ほどと同じようにデフォルトルートは配信されていることがわかります。


R2#sh ipv6 route rip
IPv6 Routing Table - 12 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   ::/0 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:205:90:31::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:220:20:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:222:22:2::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:3::/64 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:5::/64 [120/3]
     via FE80::1, Serial1/0


で、デフォルトルート以外を配信しないようにするには、、 distribute-list ですね。

R3
ipv6 prefix-list REDIST permit ::/0

ipv6 router rip RIPng
distribute-list prefix-list REDIST out s1/1

同じく R2 にてルーティングを見るとデフォルトルートのみが配信されていることがわかります。



R2#sh 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   ::/0 [120/2]
     via FE80::C803:1BFF:FEF0:8, Serial1/1
R   2001:CC1E:1:5::/64 [120/3]
     via FE80::1, Serial1/0

更新日:2012/10/09
TOPに戻る