API Guide

7. 在接口上启用 OSPFv3
ipv6 ospfv3 process-id area area-id
process-id 输入特定 OSPFv3 进程的 OSPFv3 进程 ID 1 65535
area-id OSPF 区域 ID 输入为 A.B.C.D 格式或数字 1 65535 IP 地址。
启用 OSPFv3
OS10(config)# ip vrf vrf-blue
OS10(config-vrf-blue)# router ospfv3 100 vrf vrf-blue
OS10(config-router-ospfv3-100)# exit
OS10(config)# interface ethernet 1/1/2
OS10(conf-if-eth1/1/2)# no shutdown
OS10(conf-if-eth1/1/2)# no switchport
OS10(conf-if-eth1/1/2)# ip vrf forwarding vrf-blue
OS10(conf-if-eth1/1/1)# ipv6 ospfv3 300 area 0.0.0.0
:
如果您想要将与一个 VRF 实例相关联的接口移至另一个默认或非默认 VRF 实例则必须先删除该接口上已经存在的 OSPF
Layer3 配置。如果将接口从一个 VRF 实例移至另一个实例而不删除这些现有的 Layer3 OSPF 配置则这些配置不会在新
VRF 实例中生效。
请考虑在默认 VRF 实例上配置了 OSPF 实例 100 的情况并在名为 VRF-Red 的非默认 VRF 实例上配置 OSPF 实例 200。默
VRF 实例上的接口 eth1/1/1 连接到 OSPF 进程 100 区域 1。在这种情况下如果您想要将 eth1/1/1 从默认 VRF 实例移至
VRF-Red则必须先移除接口 eth1/1/1 当前连接到的 OSPF 区域配置。
Identifier GUID-975C163B-CE72-4213-9081-5F98E0E73DA4
Version 3
Status Translation approved
分配路由器 ID
您可以为 OSPFv3 进程分配路由器 ID。为每个路由器配置 IP 地址格式的任意值。每个路由器 ID 必须是唯一的。为活动的 OSPFv3
路由器进程使用固定的路由器 ID。更改路由器 ID 会导致现有 OSPFv3 邻接。新的路由器 ID 将立即变为有效。
ROUTER-OSPFv3 模式下为 OSPFv3 进程分配路由器 ID
router-id ip-address
分配路由器 ID
OS10(config)# router ospfv3 100
OS10(config-router-ospfv3-100)# router-id 10.10.1.5
查看 OSPFv3 状态
OS10# show ipv6 ospf
Routing Process ospfv3 100 with ID 10.10.1.5
It is an Area Border Router
Min LSA origination 5000 msec, Min LSA arrival 1000 msec
Min LSA hold time 0 msec, Max LSA wait time 0 msec
Number of area in this router is 2, normal 2 stub 0 nssa
Area (0.0.0.0)
Number of interface in this area is 1
SPF algorithm executed 42 times
Area (0.0.0.1)
Number of interface in this area is 1
SPF algorithm executed 42 times
672 3