※noteから引っ越してきた記事
初期設定
show ipv6 protocols
show ipv6 ospf
show ipv6 ospf neighbor
show ipv6 ospf database
show ipv6 route
show ipv6 ospf int
リンクローカルの扱いとか確認しておきたい。
RT1
en
terminal length 0
conf t
hostname iosv-0
line console 0
logging synchronous
exit
!
ipv6 unicast-routing
!
int gi0/0
ipv6 address 2001:1:1:12::1/64
ipv6 ospf 1 area 0
no shut
exit
!
int gi0/1
ipv6 address 2001:1:1:1::1/64
ipv6 ospf 1 area 1
no shut
exit
!
ipv6 router ospf 1
router-id 1.1.1.1
end
!
infraexpertには記載あるけど必要あるのか?
int range gi0/0-1
ipv6 address fe80::1 link-local
あとで追加(RT1,2共通)
int gi0/0
ipv6 ospf network point-to-point
あとで追加2(RT1,2共通)
ipv6 ospf 1
passive-interface gi0/1
RT2
en
terminal length 0
conf t
hostname iosv-1
line console 0
logging synchronous
exit
!
ipv6 unicast-routing
!
int gi0/0
ipv6 address 2001:1:1:12::2/64
ipv6 ospf 1 area 0
no shut
exit
!
int gi0/1
ipv6 address 2001:1:1:2::2/64
ipv6 ospf 1 area 2
no shut
exit
!
ipv6 router ospf 1
router-id 2.2.2.2
end
!
iosv-1(config)#router ospf 1
iosv-1(config-router)#router-id 1.1.1.1
iosv-1#sh ipv6 ospf neighbor
%OSPFv3 1 address-family ipv6 not running, please configure a router-id
ルータIDを設定しなさいと言われるも、直前で設定してるじゃんという気持ち。典型的な罠。
iosv-1(config)#router ospfv3 1
iosv-1(config-router)#router-id 1.1.1.1
*Jun 19 12:15:13.678: %OSPFv3-5-ADJCHG: Process 1, IPv6, Nbr 2.2.2.2 on GigabitEthernet0/0 from LOADING to FULL, Loading Done
router ospfv3 でルータIDを設定しないといけなかったんですね。
iosv-1#sh ipv6 ospf neighbor
OSPFv3 Router with ID (1.1.1.1) (Process ID 1)
Neighbor ID Pri State Dead Time Interface ID Interface
2.2.2.2 1 FULL/DR 00:00:35 2 GigabitEthernet0/0
iosv-1#sh ipv6 route | b Application
lA - LISP away, a - Application
C 2001:1:1:1::/64 [0/0]
via GigabitEthernet0/1, directly connected
L 2001:1:1:1::1/128 [0/0]
via GigabitEthernet0/1, receive
OI 2001:1:1:2::/64 [110/2]
via FE80::2, GigabitEthernet0/0
C 2001:1:1:10::/64 [0/0]
via GigabitEthernet0/0, directly connected
L 2001:1:1:10::1/128 [0/0]
via GigabitEthernet0/0, receive
L FF00::/8 [0/0]
via Null0, receive
OSPFで学習したルートのネクストホップがリンクローカルになっている
iosv-2(config)#int gi0/0
iosv-2(config-if)#no ipv6 address fe80::2 link-local
iosv-2(config-if)#
*Jun 19 12:33:36.072: %OSPFv3-5-ADJCHG: Process 1, IPv6, Nbr 1.1.1.1 on GigabitEthernet0/0 from FULL to DOWN, Neighbor Down: Interface down or detached
iosv-2(config-if)#
*Jun 19 12:33:37.273: %OSPFv3-5-ADJCHG: Process 1, IPv6, Nbr 1.1.1.1 on GigabitEthernet0/0 from LOADING to FULL, Loading Done
iosv-1#sh ipv6 route | b Application
lA - LISP away, a - Application
C 2001:1:1:1::/64 [0/0]
via GigabitEthernet0/1, directly connected
L 2001:1:1:1::1/128 [0/0]
via GigabitEthernet0/1, receive
OI 2001:1:1:2::/64 [110/2]
via FE80::5054:FF:FE17:9B97, GigabitEthernet0/0
C 2001:1:1:10::/64 [0/0]
via GigabitEthernet0/0, directly connected
L 2001:1:1:10::1/128 [0/0]
via GigabitEthernet0/0, receive
L FF00::/8 [0/0]
via Null0, receive
・手動設定したリンクローカルを削除すると、一旦ネイバーが解除されたあとすぐに復活
・今度は自動生成されたリンクローカルアドレスがネクストホップになる
↑v6のHelloが送信されていることを確認
iosv-1(config)#int gi0/0
iosv-1(config-if)#ipv6 ospf network point-to-point
(iosv-2でも同様に設定)
iosv-1#sh ipv6 ospf neighbor
OSPFv3 Router with ID (1.1.1.1) (Process ID 1)
Neighbor ID Pri State Dead Time Interface ID Interface
2.2.2.2 0 FULL/ - 00:00:39 2 GigabitEthernet0/0
・動作はv4と同じでDR/BDRを選出しなくなる