33-IPv6 PIM典型配置举例
本章节下载: 33-IPv6 PIM典型配置举例 (256.75 KB)
目 录
本章介绍了通过IPv6 PIM(Protocol Independent Multicast for IPv6,IPv6协议无关组播)协议生成IPv6组播路由表来指导IPv6组播转发的典型配置案例。
IPv6 PIM分为以下几种类型:
· IPv6 PIM-DM(Protocol Independent Multicast-Dense Mode for IPv6,IPv6协议无关组播—密集模式),属于ASM(Any-Source Multicast,任意信源组播)模型,通常适用于IPv6组播组成员相对比较密集的小型网络。
· IPv6 PIM-SM(Protocol Independent Multicast-Sparse Mode for IPv6,IPv6协议无关组播—稀疏模式),属于ASM(Any-Source Multicast,任意信源组播)模型,通常适用于IPv6组播组成员分布相对分散、范围较广的大中型网络。为了实现精细化管理,IPv6 PIM-SM中增加了IPv6管理域机制,通过私有组地址为特定区域提供专门的服务。
同一台设备所有接口上所启用的IPv6 PIM模式必须相同。
表1 配置适用的产品与软件版本关系
产品 |
软件版本 |
S5830V2&S5820V2系列以太网交换机 |
Release 2208P01,Release 2210 |
如图1所示,用户网络N1、N2和IPv6组播源网络分别与三层网络内的Switch A、Switch B、Switch C相连,整个网络IPv6单播路由正常。
现要求通过在该该网络内的各三层交换机上配置IPv6 PIM-DM,实现用户网络N1、N2内的IPv6组播接收者能通过该网络接收到IPv6组播源发来的组播数据报文。
图1 IPv6 PIM-DM典型配置组网图
设备 |
接口 |
IP地址 |
设备 |
接口 |
IP地址 |
Switch A |
Vlan-int100 |
1001::1/64 |
Switch C |
Vlan-int300 |
4001::1/64 |
|
Vlan-int102 |
1002::1/64 |
|
Vlan-int102 |
1002::2/64 |
Switch B |
Vlan-int200 |
2001::1/64 |
|
Vlan-int101 |
2002::2/64 |
|
Vlan-int101 |
2002::1/64 |
|
|
|
需要在三层网络中连接用户网络的边界三层交换机上使能MLD功能,以建立和维护各IPv6组播组成员关系。
(1) 配置IPv6地址和IPv6单播路由协议
请按照1.3.2 图1配置各接口的IPv6地址和前缀长度,具体配置过程略。
配置IPv6 PIM-DM域内的各交换机之间采用OSPFv3协议进行互连,确保IPv6 PIM-DM域内部在网络层互通,并且各交换机之间能够借助IPv6单播路由协议实现动态路由更新,具体配置过程略。
(2) 使能IPv6组播路由,并配置IPv6 PIM-DM功能
# 在Switch A上使能IPv6组播路由,在各接口上使能IPv6 PIM-DM。
<SwitchA> system-view
[SwitchA] ipv6 multicast routing-enable
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] ipv6 pim dm
[SwitchA-Vlan-interface100] quit
[SwitchA] interface vlan-interface 102
[SwitchA-Vlan-interface102] ipv6 pim dm
[SwitchA-Vlan-interface102] quit
Switch B和Switch C的配置与Switch A相似,配置过程略。
(3) 在连接网络N1和N2的设备接口上使能MLDv1功能
# 在Switch A的接口Vlan-interface100上使能MLD(缺省情况下,MLD的版本为MLDv1)。
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] mld enable
[SwitchA-Vlan-interface100] quit
Switch B的配置与Switch A相似,配置过程略。
配置完成后,通过Host A、Host C和Source检验一下配置效果:
· Host A和Host C分别发送MLDv1成员关系报告报文,指定加入IPv6组播组G(FF0E::101),成为该组播组的接收者;
· IPv6组播源S(4001::100/64)向该IPv6组播组G发送IPv6组播数据报文。
通过使用display ipv6 pim routing-table命令可以查看交换机上的IPv6 PIM路由表信息。例如:
# 查看Switch C上的PIM路由表信息。
[SwitchC] display ipv6 pim routing-table
Total 0 (*, G) entry; 1 (S, G) entry
(4001::100, FF0E::101)
Protocol: pim-dm, Flag: LOC ACT
UpTime: 00:02:19
Upstream interface: Vlan-interface300
Upstream neighbor: NULL
RPF prime neighbor: NULL
Downstream interface(s) information:
Total number of downstreams: 2
1: Vlan101
Protocol: pim-dm, UpTime: 00:02:19, Expires: -
2: Vlan102
Protocol: pim-dm, UpTime: 00:02:19, Expires: -
# 查看Switch A上的IPv6 PIM路由表信息。
[SwitchA] display ipv6 pim routing-table
Total 1 (*, G) entry; 1 (S, G) entry
(*, FF0E::101)
Protocol: pim-dm, Flag: WC
UpTime: 00:01:24
Upstream interface: NULL
Upstream neighbor: NULL
RPF prime neighbor: NULL
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan100
Protocol: mld, UpTime: 00:01:20, Expires: -
(4001::100, FF0E::101)
Protocol: pim-dm, Flag: ACT
UpTime: 00:01:20
Upstream interface: Vlan-interface102
Upstream neighbor: FE80::20F:E2FF:FE67:B323
RPF prime neighbor: FE80::20F:E2FF:FE67:B323
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan100
Protocol: pim-dm, UpTime: 00:01:20, Expires: -
# 查看Switch B上的IPv6 PIM路由表信息。
[SwitchB] display ipv6 pim routing-table
Total 1 (*, G) entry; 1 (S, G) entry
(*, FF0E::101)
Protocol: pim-dm, Flag: WC
UpTime: 00:01:24
Upstream interface: NULL
Upstream neighbor: NULL
RPF prime neighbor: NULL
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan200
Protocol: mld, UpTime: 00:01:20, Expires: -
(4001::100, FF0E::101)
Protocol: pim-dm, Flag: ACT
UpTime: 00:01:20
Upstream interface: Vlan-interface101
Upstream neighbor: FE80::20F:E2FF:FE67:B323
RPF prime neighbor: FE80::20F:E2FF:FE67:B323
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan200
Protocol: pim-dm, UpTime: 00:01:20, Expires: -
由上显示信息可见,当组播源S向IPv6组播组G发送组播数据时,会通过扩散生成SPT,SPT路径中各交换机(以Switch A和Switch B路径为例)上都存在(S,G)表项;因Host A向Switch A发送MLD成员关系报告报文进行注册,所以在Switch A上会生成(*,G)表项。
(1) Switch A配置信息
#
ipv6 multicast routing-enable
#
vlan 100
#
vlan 102
#
interface Vlan-interface100
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 1001::1/64
mld enable
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 1002::1/64
#
ospfv3 1
router-id 1.1.1.1
area 0.0.0.0
#
(2) Switch B配置信息
#
ipv6 multicast routing-enable
#
vlan 101
#
vlan 200
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 2002::1/64
#
interface Vlan-interface200
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 2001::1/64
mld enable
#
ospfv3 1
router-id 2.2.2.2
area 0.0.0.0
#
(3) Switch C配置信息
#
ipv6 multicast routing-enable
#
vlan 101 to 102
#
vlan 300
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 2002::2/64
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 1002::2/64
#
interface Vlan-interface300
ospfv3 1 area 0.0.0.0
ipv6 pim dm
ipv6 address 4001::1/64
#
ospfv3 1
router-id 3.3.3.3
area 0.0.0.0
#
表2 配置适用的产品与软件版本关系
产品 |
软件版本 |
S5830V2&S5820V2系列以太网交换机 |
Release 2208P01,Release 2210 |
如图2所示,三层网络内的Switch A连接用户网络N1,Switch B和Switch C共同连接用户网络N2,Switch D连接IPv6组播源网络,整个网络IPv6单播路由正常。
现要求通过在该网络内的各三层交换机上配置IPv6 PIM-SM,实现用户网络N1、N2内的IPv6组播接收者能通过该网络接收到IPv6组播源发来的FF0E::/64范围内的IPv6组播数据报文。
图2 IPv6 PIM-SM典型配置组网图
设备 |
接口 |
IP地址 |
设备 |
接口 |
IP地址 |
Switch A |
Vlan-int100 |
1001::1/64 |
Switch D |
Vlan-int300 |
4001::1/64 |
|
Vlan-int101 |
1002::1/64 |
|
Vlan-int101 |
1002::2/64 |
|
Vlan-int102 |
1003::1/64 |
|
Vlan-int105 |
4002::1/64 |
Switch B |
Vlan-int200 |
2001::1/64 |
Switch E |
Vlan-int104 |
3001::2/64 |
|
Vlan-int103 |
2002::1/64 |
|
Vlan-int103 |
2002::2/64 |
Switch C |
Vlan-int200 |
2001::2/64 |
|
Vlan-int102 |
1003::2/64 |
|
Vlan-int104 |
3001::1/64 |
|
Vlan-int105 |
4002::2/64 |
(1) 根据组网需求限定的IPv6组播组范围,来指定IPv6 PIM-SM网络中C-RP所服务的组播组范围。
(2) 为缓解单个RP的负担,可在IPv6 PIM-SM网络中配置多个C-RP,例如选取本例中Switch D和Switch E作为C-RP,通过自举机制,实现不同的C-RP服务于不同的IPv6组播组。
(3) 为避免因单个BSR发生故障致使网络中的IPv6组播业务被中断,可在IPv6 PIM-SM网络中配置多个C-BSR,例如选取与C-RP相同的设备作为C-BSR,这样,一旦BSR发生故障,其余C-BSR能够通过自动选举产生新的BSR。
· 用户网络所处的共享网段内有多台三层设备时,需要在各三层设备上都配置MLD和IPv6 PIM-SM,避免因某台三层设备出现故障,而中断IPv6组播流量转发。
· 建议候选BSR和候选RP应配置在骨干网的三层交换机上。
· 配置C-RP时,若不指定其所服务的IPv6组播组范围,该RP将为所有IPv6组播组服务。
(1) 配置IPv6地址和IPv6单播路由协议
请按照1.4.2 图2配置各接口的IPv6地址和前缀长度,具体配置过程略。
配置IPv6 PIM-SM域内的各交换机之间采用OSPFv3协议进行互连,确保IPv6 PIM-SM域内部在网络层互通,并且各交换机之间能够借助IPv6单播路由协议实现动态路由更新,具体配置过程略。
(2) 使能IPv6组播路由,并在各接口上使能IPv6 PIM-SM
# 在Switch A上使能IPv6组播路由,在各接口上使能IPv6 PIM-SM。
<SwitchA> system-view
[SwitchA] ipv6 multicast routing-enable
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] ipv6 pim sm
[SwitchA-Vlan-interface100] quit
[SwitchA] interface vlan-interface 101
[SwitchA-Vlan-interface101] ipv6 pim sm
[SwitchA-Vlan-interface101] quit
[SwitchA] interface vlan-interface 102
[SwitchA-Vlan-interface102] ipv6 pim sm
[SwitchA-Vlan-interface102] quit
Switch B、Switch C、Switch D和Switch E的配置与Switch A相似,配置过程略。
(3) 在连接网络N1和N2的接口上使能MLDv1功能
# 在Switch A的接口Vlan-interface100上使能MLD(缺省情况下,MLD的版本为MLDv1)。
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] mld enable
[SwitchA-Vlan-interface100] quit
Switch B和Switch C的配置与Switch A相似,配置过程略
(4) 配置C-BSR和C-RP
# 在Switch D上配置RP通告的服务范围,以及C-BSR和C-RP的位置,并指定哈希掩码长度为128,C-BSR的优先级为10。
<SwitchD> system-view
[SwitchD] acl ipv6 number 2005
[SwitchD-aclv6-basic-2005] rule permit source ff0e:: 64
[SwitchD-aclv6-basic-2005] quit
[SwitchD] ipv6 pim
[SwitchD-pim6] c-bsr 4002::1 hash-length 128 priority 10
[SwitchD-pim6] c-rp 4002::1 group-policy 2005
[SwitchD-pim6] quit
# 在Switch E上配置RP通告的服务范围,以及C-BSR和C-RP的位置,并指定哈希掩码长度为128,C-BSR的优先级为20。
<SwitchE> system-view
[SwitchE] acl ipv6 number 2005
[SwitchE-acl6-basic-2005] rule permit source ff0e:: 64
[SwitchE-acl6-basic-2005] quit
[SwitchE] ipv6 pim
[SwitchE-pim6] c-bsr 1003::2 hash-length 128 priority 20
[SwitchE-pim6] c-rp 1003::2 group-policy 2005
[SwitchE-pim6] quit
(1) 查看共享网络N2内MLD查询器选举信息和DR选举信息
配置完成后,查看接入共享网络N2的组播路由器Switch B和Switch C上MLD查询器选举信息和DR选举信息:
# 查看Switch B上MLD查询器选举信息。
[SwitchB] display mld interface
Vlan-interface200(FE80::223:89FF:FE5F:958B):
MLD is enabled
MLD version: 1
Query interval for MLD: 125s
Other querier present time for MLD: 255s
Maximum query response time for MLD: 10s
Querier for MLD: FE80::223:89FF:FE5F:958B (this router)
MLD groups reported in total: 1
# 查看Switch C上MLD查询器选举信息。
[SwitchC] display mld interface
Vlan-interface200(FE80::223:89FF:FE5F:958C):
MLD is enabled
MLD version: 1
Query interval for MLD: 125s
Other querier present time for MLD: 255s
Maximum query response time for MLD: 10s
Querier for MLD: FE80::223:89FF:FE5F:958B
MLD groups reported in total: 1
由上显示信息可知,通过查询器选举,Switch B成为本共享网段的MLD查询器(MLD查询器选举原则:共享网段中IPv6链路本地地址最小的路由器将成为查询器)。
# 查看Switch B上DR选举信息。
[SwitchB] display ipv6 pim interface
Interface NbrCnt HelloInt DR-Pri DR-Address
Vlan103 1 30 1 FE80::223:89FF:FE5F:958E
Vlan200 1 30 1 FE80::223:89FF:FE5F:958C
# 查看Switch C上DR选举信息。
[SwitchC] display ipv6 pim interface
Interface NbrCnt HelloInt DR-Pri DR-Address
Vlan104 1 30 1 FE80::223:89FF:FE5F:958E
Vlan200 1 30 1 FE80::223:89FF:FE5F:958C (local)
由上显示信息可知,通过DR选举,Switch C成为本共享网段的DR(DR选举原则:在Hello报文携带的DR竞选优先级相同的情况下,共享网段中IPv6链路本地地址最大的路由器将成为DR)。
(2) 查看交换机的IPv6 PIM路由表信息
配置完成后,通过Host A和IPv6组播源Source检验一下配置效果:
· Host A发送MLDv1成员关系报告报文,指定加入IPv6组播组G(FF0E::100),成为该组播组的接收者;
· IPv6组播源S(4001::100/64)向该IPv6组播组G发送IPv6组播数据报文。
通过使用display ipv6 pim routing-table命令可以查看交换机的IPv6 PIM路由表信息。例如:
# 查看Switch A上的IPv6 PIM路由表信息。
[SwitchA] display ipv6 pim routing-table
Total 1 (*, G) entry; 1 (S, G) entry
(*, FF0E::100)
RP: 1003::2
Protocol: pim-sm, Flag: WC
UpTime: 00:03:45
Upstream interface: Vlan-interface102
Upstream neighbor: FE80::223:89FF:FE5F:958E
RPF prime neighbor: FE80::223:89FF:FE5F:958E
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan100
Protocol: mld, UpTime: 00:02:15, Expires: -
(4001::100, FF0E::100)
RP: 1003::2
Protocol: pim-sm, Flag: SPT ACT
UpTime: 00:02:15
Upstream interface: Vlan-interface101
Upstream neighbor: FE80::223:89FF:FE5F:958D
RPF prime neighbor: FE80::223:89FF:FE5F:958D
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan100
Protocol: pim-sm, UpTime: 00:02:15, Expires: -
Switch B和Switch C上的显示信息与Switch A类似。
# 查看Switch D上的IPv6 PIM路由表信息。
[SwitchD] display ipv6 pim routing-table
Total 0 (*, G) entry; 1 (S, G) entry
(4001::100, FF0E::100)
RP: 1003::2
Protocol: pim-sm, Flag: SPT LOC ACT
UpTime: 00:14:44
Upstream interface: Vlan-interface300
Upstream neighbor: NULL
RPF prime neighbor: NULL
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan101
Protocol: mld, UpTime: 00:14:44, Expires: -
# 查看Switch E上的IPv6 PIM路由表信息。
[SwitchE] display ipv6 pim routing-table
Total 1 (*, G) entry; 1 (S, G) entry
(*, FF0E::100)
RP: 1003::2 (local)
Protocol: pim-sm, Flag: WC
UpTime: 00:16:56
Upstream interface: Register
Upstream neighbor: NULL
RPF prime neighbor: NULL
Downstream interface(s) information:
Total number of downstreams: 1
1: Vlan102
Protocol: pim-sm, UpTime: 00:16:56, Expires: -
(4001::100, FF0E::100)
RP: 1003::2 (local)
Protocol: pim-sm, Flag: RPT SPT ACT
UpTime: 00:25:32
Upstream interface: Vlan-interface105
Upstream neighbor: FE80::223:89FF:FE5F:958D
RPF prime neighbor: FE80::223:89FF:FE5F:958D
Downstream interface(s) information: None
由上显示信息可知:
· 根据哈希算法得出G对应的RP为Switch E。
· IPv6组播源侧DR(Switch D)和RP(Switch E)之间会生成组播源侧的SPT。
· 接收者侧DR(Switch A)和RP(Switch E)之间会生成RPT,RPT路径中的交换机(Switch A和Switch E)上会生成(*,G)表项。
· 当接收者侧DR(Switch A)收到IPv6组播数据后立即执行SPT的切换,在接收者侧DR和组播源侧DR之间建立新的SPT,新SPT路径中的交换机(Switch A和Switch D)上存在(S,G)表项。
(1) Switch A配置信息
#
ipv6 multicast routing-enable
#
vlan 100 to 102
#
interface Vlan-interface100
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1001::1/64
mld enable
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1002::1/64
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1003::1/64
#
ospfv3 1
router-id 1.1.1.1
area 0.0.0.0
#
(2) Switch B配置信息
#
ipv6 multicast routing-enable
#
vlan 103
#
vlan 200
#
interface Vlan-interface103
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 2002::1/64
#
interface Vlan-interface200
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 2001::1/64
mld enable
#
ospfv3 1
router-id 2.2.2.2
area 0.0.0.0
#
(3) Switch C配置信息
#
ipv6 multicast routing-enable
#
vlan 104
#
vlan 200
#
interface Vlan-interface104
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 3001::1/64
#
interface Vlan-interface200
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 2001::2/64
mld enable
#
ospfv3 1
router-id 3.3.3.3
area 0.0.0.0
#
(4) Switch D配置信息
#
ipv6 multicast routing-enable
#
acl ipv6 number 2005
rule 0 permit source FF0E::/64
#
vlan 101
#
vlan 105
#
vlan 300
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1002::2/64
#
interface Vlan-interface105
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 4002::1/64
#
interface Vlan-interface300
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 4001::1/64
#
ipv6 pim
c-bsr 4002::1 priority 10 hash-length 128
c-rp 4002::1 group-policy 2005
#
ospfv3 1
router-id 4.4.4.4
area 0.0.0.0
#
(5) Switch E配置信息
#
ipv6 multicast routing-enable
#
acl ipv6 number 2005
rule 0 permit source FF0E::/64
#
vlan 102 to 104
#
vlan 105
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1003::2/64
#
interface Vlan-interface103
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 2002::2/64
#
interface Vlan-interface104
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 3001::2/64
#
interface Vlan-interface105
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 4002::2/64
#
ipv6 pim
c-bsr 1003::2 priority 20 hash-length 128
c-rp 1003::2 group-policy 2005
#
ospfv3 1
router-id 5.5.5.5
area 0.0.0.0
#
表3 配置适用的产品与软件版本关系
产品 |
软件版本 |
S5830V2&S5820V2系列以太网交换机 |
Release 2208P01,Release 2210 |
在如图3所示,IPv6组播源(Source)和IPv6组播接收者(Receiver)之间通过三层交换机相连,整个网络IPv6单播路由正常。
现要求通过采用IPv6 PIM-SM管理域机制,将整个网络划分为管理域1、管理域2和Global域,从而实现:
· 管理域1内的IPv6组播源Source 1和管理域2内的IPv6组播源Source 2发送管理本地类型组地址范围内的组播组(Scope值为4的IPv6组播组)信息,只有各自管理域内的IPv6组播接收者可以点播。
· Global域内的公共组播源Source 3发送全球类型组地址范围内的组播组(Scope值为14的IPv6组播组)信息,网络内的所有IPv6组播接收者都可以进行点播。
图3 IPv6 PIM-SM管理域配置组网图
设备 |
接口 |
IP地址 |
设备 |
接口 |
IP地址 |
Switch A |
Vlan-int100 |
1001::1/64 |
Switch D |
Vlan-int400 |
4001::1/64 |
|
Vlan-int101 |
1002::1/64 |
|
Vlan-int106 |
1007::2/64 |
Switch B |
Vlan-int200 |
2001::1/64 |
Switch E |
Vlan-int500 |
5001::1/64 |
|
Vlan-int101 |
1002::2/64 |
|
Vlan-int102 |
1003::2/64 |
|
Vlan-int102 |
1003::1/64 |
|
Vlan-int105 |
1006::2/64 |
|
Vlan-int103 |
1004::1/64 |
Switch F |
Vlan-int600 |
6001::1/64 |
Switch C |
Vlan-int300 |
3001::1/64 |
|
Vlan-int103 |
1004::2/64 |
|
Vlan-int104 |
1005::1/64 |
|
Vlan-int104 |
1005::2/64 |
|
Vlan-int105 |
1006::1/64 |
Source 1 |
- |
2001::100/64 |
|
Vlan-int106 |
1007::1/64 |
Source 2 |
- |
3001::100/64 |
|
|
|
Source 3 |
- |
5001::100/64 |
(1) 根据管理域的空间规划,和需求中限定的管理域服务的组地址范围,将管理域中与其它域相连的接口配置为管理域边界,以限定管理域的空间范围和管理的组地址范围。
(2) 为了使管理域和Global域能够为需求中的IPv6组播组服务,需要为各管理域和Global域配置C-BSR和C-RP,其中管理域的C-BSR和C-RP所服务的组播组范围与本管理域边界限定的组地址范围保持一致,Global域的C-BSR和C-RP所服务的组播组范围为全球类型组地址范围,可为所有全球地址类型的组播组服务。
为建立和维护IPv6组播组成员关系,还需要在连接接收者的三层交换机上使能MLD功能。
(1) 配置IPv6地址和IPv6单播路由协议
请按照1.5.2 图3配置各接口的IPv6地址和前缀长度,具体配置过程略。
配置IPv6 PIM-SM域内的各交换机之间采用OSPFv3协议进行互连,确保IPv6 PIM-SM域内部在网络层互通,并且各交换机之间能够借助IPv6单播路由协议实现动态路由更新,具体配置过程略。
(2) 使能IPv6组播路由和IPv6管理域机制,并使能IPv6 PIM-SM和MLD
# 在所有三层交换机上使能IPv6组播路由,并在各接口上使能IPv6 PIM-SM,这里以Switch A为例。
<SwitchA> system-view
[SwitchA] ipv6 multicast routing-enable
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] ipv6 pim sm
[SwitchA-Vlan-interface100] quit
[SwitchA] interface vlan-interface 101
[SwitchA-Vlan-interface101] ipv6 pim sm
[SwitchA-Vlan-interface101] quit
Switch B、Switch C、Switch D、Switch E和Switch F的配置与Switch A相似,配置过程略。
# 在三层交换机的连接有接收者的接口上使能MLD。这里以配置Switch A的Vlan-interface100接口为例。
[SwitchA] interface vlan-interface 100
[SwitchA-Vlan-interface100] mld enable
[SwitchA-Vlan-interface101] quit
Switch D和Switch F的配置与Switch A相似,配置过程略。
(3) 配置IPv6管理域边界
# 在Switch B上将接口Vlan-interface102和Vlan-interface103配置为IPv6管理域1的边界。
[SwitchB] interface vlan-interface 102
[SwitchB-Vlan-interface102] ipv6 multicast boundary scope 4
[SwitchB-Vlan-interface102] quit
[SwitchB] interface vlan-interface 103
[SwitchB-Vlan-interface103] ipv6 multicast boundary scope 4
[SwitchB-Vlan-interface103] quit
# 在Switch C上将接口Vlan-interface104和Vlan-interface105配置为IPv6管理域2的边界。
<SwitchC> system-view
[SwitchC] interface vlan-interface 104
[SwitchC-Vlan-interface104] ipv6 multicast boundary scope 4
[SwitchC-Vlan-interface104] quit
[SwitchC] interface vlan-interface 105
[SwitchC-Vlan-interface105] ipv6 multicast boundary scope 4
[SwitchC-Vlan-interface105] quit
(4) 配置C-BSR和C-RP
# 在Switch B上配置RP通告的服务范围,并将接口Vlan-interface101配置为IPv6管理域1的C-BSR和C-RP。
[SwitchB] ipv6 pim
[SwitchB-pim6] c-bsr 1002::2 scope 4
[SwitchB-pim6] c-rp 1002::2 scope 4
[SwitchB-pim6] quit
# 在Switch C上配置RP通告的服务范围,并将接口Vlan-interface104配置为IPv6管理域2的C-BSR和C-RP。
[SwitchC] ipv6 pim
[SwitchC-pim6] c-bsr 1007::1 scope 4
[SwitchC-pim6] c-rp 1007::1 scope 4
[SwitchC-pim6] quit
# 在Switch E上将接口Vlan-interface102配置为IPv6 Global域的C-BSR和C-RP。
<SwitchE> system-view
[SwitchE] ipv6 pim
[SwitchE-pim6] c-bsr 1003::2 scope 14
[SwitchE-pim6] c-rp 1003::2 scope 14
[SwitchE-pim6] quit
配置完成后,查看交换机上BSR选举信息以及获取的RP信息。
(1) 通过使用display ipv6 pim bsr-info命令可以查看交换机上BSR选举的信息。例如:
# 查看Switch B上的BSR信息。
[SwitchB] display ipv6 pim bsr-info
Scope: non-scoped
State: Accept Any
Scope: 4
State: Elected
Bootstrap timer: 00:00:06
Elected BSR address: 1002::2
Priority: 64
Hash mask length: 126
Uptime: 00:04:54
Candidate BSR address: 1002::2
Priority: 64
Hash mask length: 126
Scope: 14
State: Accept Preferred
Bootstrap timer: 00:02:00
Elected BSR address: 1003::2
Priority: 64
Hash mask length: 126
Uptime: 00:02:08
# 查看Switch C上的BSR信息。
[SwitchC] display ipv6 pim bsr-info
Scope: non-scoped
State: Accept Any
Scope: 4
State: Elected
Bootstrap timer: 00:01:06
Elected BSR address: 1007::1
Priority: 64
Hash mask length: 126
Uptime: 00:04:51
Candidate BSR address: 1007::1
Priority: 64
Hash mask length: 126
Scope: 14
State: Accept Preferred
Bootstrap timer: 00:02:10
Elected BSR address: 1003::2
Priority: 64
Hash mask length: 126
Uptime: 00:01:08
# 查看Switch E上的BSR信息。
[SwitchE] display ipv6 pim bsr-info
Scope: non-scoped
State: Accept Any
Scope: 14
State: Elected
Bootstrap timer: 00:00:39
Elected BSR address: 1003::2
Priority: 64
Hash mask length: 126
Uptime: 00:01:31
Candidate BSR address: 1003::2
Priority: 64
Hash mask length: 126
(2) 通过使用display ipv6 pim rp-info命令查看交换机上获取的RP信息。例如:
# 查看Switch B上的RP信息。
[SwitchB] display ipv6 pim rp-info
BSR RP information:
Scope: 4
Group/MaskLen: FF04::/16
RP address Priority HoldTime Uptime Expires
1002::2 (local) 192 180 00:02:03 00:02:56
Group/MaskLen: FF14::/16
RP address Priority HoldTime Uptime Expires
1002::2 (local) 192 180 00:02:03 00:02:56
Group/MaskLen: FF24::/16
RP address Priority HoldTime Uptime Expires
1002::2 (local) 192 180 00:02:03 00:02:56
……
Scope: 14
Group/MaskLen: FF0E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
Group/MaskLen: FF1E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
Group/MaskLen: FF2E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
……
省略FF34::/16~FFF4::/16 和FF3E::/16~FFFE::/16的显示信息。
# 查看Switch C上的RP信息。
[SwitchC] display ipv6 pim rp-info
BSR RP information:
Scope: 4
Group/MaskLen: FF04::/16
RP address Priority HoldTime Uptime Expires
1007::1 (local) 192 180 00:02:03 00:02:56
Group/MaskLen: FF14::/16
RP address Priority HoldTime Uptime Expires
1007::1 (local) 192 180 00:02:03 00:02:56
Group/MaskLen: FF24::/16
RP address Priority HoldTime Uptime Expires
1007::1 (local) 192 180 00:02:03 00:02:56
……
Scope: 14
Group/MaskLen: FF0E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
Group/MaskLen: FF1E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
Group/MaskLen: FF2E::/16
RP address Priority HoldTime Uptime Expires
1001::1 192 180 00:08:36 00:02:00
……
省略FF34::/16~FFF4::/16 和FF3E::/16~FFFE::/16的显示信息。
# 查看Switch E上的RP信息。
[SwitchE] display ipv6 pim rp-info
BSR RP information:
Scope: 14
Group/MaskLen: FF0E::/16
RP address Priority HoldTime Uptime Expires
1003::2 (local) 192 180 00:07:23 00:02:40
Group/MaskLen: FF1E::/16
RP address Priority HoldTime Uptime Expires
1003::2 (local) 192 180 00:07:23 00:02:40
Group/MaskLen: FF2E::/16
RP address Priority HoldTime Uptime Expires
1003::2 (local) 192 180 00:07:23 00:02:40
……
省略FF3E::/16~FFFE::/16的显示信息。
# 查看Switch F上的RP信息。
[SwitchF] display ipv6 pim rp-info
BSR RP information:
Scope: 14
Group/MaskLen: FF0E::/16
RP address Priority HoldTime Uptime Expires
1003::2 192 180 00:07:23 00:02:40
Group/MaskLen: FF1E::/16
RP address Priority HoldTime Uptime Expires
1003::2 192 180 00:07:23 00:02:40
Group/MaskLen: FF2E::/16
RP address Priority HoldTime Uptime Expires
1003::2 192 180 00:07:23 00:02:40
……
省略FF3E::/16~FFFE::/16的显示信息。
由此可见,IPv6管理域1内的接收者若要点播本管理域内部的IPv6组播视频信息(FF04::/16~FFF4::/16IPv6范围内的IPv6组播组),将由IPv6管理域1内部的RP(Switch B)为其IPv6组播路由建立提供服务。IPv6管理域2内的接收者若要点播本管理域内部的IPv6组播视频信息(FF04::/16~FFF4::/16IPv6范围内的IPv6组播组),将由IPv6管理域2内部的RP(Switch C)为其IPv6组播路由建立提供服务。若IPv6管理域1、IPv6管理域2和IPv6 Global域内的接收者要点播公共的组播视频信息(FF0E::/16~FFFE::/16范围内的IPv6组播组),将由IPv6 Global域的RP(Switch E)为其IPv6组播路由建立提供服务。
(1) Switch A配置信息
#
ipv6 multicast routing-enable
#
vlan 100 to 101
#
interface Vlan-interface100
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1001::1/64
mld enable
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1002::1/64
#
ospfv3 1
router-id 1.1.1.1
area 0.0.0.0
#
(2) Switch B配置信息
#
ipv6 multicast routing-enable
#
vlan 101 to 103
#
vlan 200
#
interface Vlan-interface101
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1002::2/64
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 multicast boundary scope 4
ipv6 pim sm
ipv6 address 1003::1/64
#
interface Vlan-interface103
ospfv3 1 area 0.0.0.0
ipv6 multicast boundary scope 4
ipv6 pim sm
ipv6 address 1004::1/64
#
interface Vlan-interface200
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 2001::1/64
#
ospfv3 1
router-id 2.2.2.2
area 0.0.0.0
#
ipv6 pim
c-bsr 1002::2 scope 4
c-rp 1002::2 scope 4
#
(3) Switch C配置信息
#
ipv6 multicast routing-enable
#
vlan 104 to 106
#
vlan 300
#
interface Vlan-interface104
ospfv3 1 area 0.0.0.0
ipv6 multicast boundary scope 4
ipv6 pim sm
ipv6 address 1005::1/64
#
interface Vlan-interface105
ospfv3 1 area 0.0.0.0
ipv6 multicast boundary scope 4
ipv6 pim sm
ipv6 address 1006::1/64
#
interface Vlan-interface106
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1007::1/64
#
interface Vlan-interface300
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 3001::1/64
#
ospfv3 1
router-id 3.3.3.3
area 0.0.0.0
#
ipv6 pim
c-bsr 1007::1 scope 4
c-rp 1007::1 scope 4
#
(4) Switch D配置信息
#
ipv6 multicast routing-enable
#
vlan 106
#
vlan 400
#
interface Vlan-interface106
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1007::2/64
#
interface Vlan-interface400
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 4001::1/64
mld enable
#
ospfv3 1
router-id 4.4.4.4
area 0.0.0.0
#
(5) Switch E配置信息
#
ipv6 multicast routing-enable
#
vlan 102
#
vlan 105
#
vlan 500
#
interface Vlan-interface102
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1003::2/64
#
interface Vlan-interface105
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1006::2/64
#
interface Vlan-interface500
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 5001::1/64
#
ospfv3 1
router-id 5.5.5.5
area 0.0.0.0
#
ipv6 pim
c-bsr 1003::2 scope 14
c-rp 1003::2 scope 14
#
(6) Switch F配置信息
#
ipv6 multicast routing-enable
#
vlan 103 to 104
#
vlan 600
#
interface Vlan-interface103
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1004::2/64
#
interface Vlan-interface104
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 1005::2/64
#
interface Vlan-interface600
ospfv3 1 area 0.0.0.0
ipv6 pim sm
ipv6 address 6001::1/64
mld enable
#
ospfv3 1
router-id 6.6.6.6
area 0.0.0.0
不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!