20-UDP Helper典型配置举例
本章节下载: 20-UDP Helper典型配置举例 (99.91 KB)
目 录
本章介绍了使用UDP Helper功能实现广播报文的跨网段转发的典型配置案例。
表1 配置适用的产品与软件版本关系
产品 |
软件版本 |
S5830V2&S5820V2系列以太网交换机 |
Release 2208P01,Release 2210 |
如图1所示,通过配置UDP Helper功能实现Host发送的目的UDP端口号为55,目的IP地址为10.110.255.255的定向广播UDP报文能被Server获得。
图1 UDP Helper典型配置组网图
缺省情况下,设备禁止接收所有的广播报文。因此,只有在接口视图下配置ip forward-broadcast命令后,UDP Helper功能才可用。
# 创建Vlan-interface1接口,并配置IP地址。
<Switch> system-view
[Switch] interface vlan-interface 1
[Switch-vlan-interface1] ip address 10.110.1.1 16
[Switch-vlan-interface1] quit
# 创建VLAN 2。
[Switch] vlan 2
[Switch-vlan2] quit
# 将接口Ten-GigabitEthernet1/0/2加入到VLAN 2中。
[Switch] interface ten-GigabitEthernet 1/0/2
[Switch-Ten-GigabitEthernet1/0/2] port access vlan 2
[Switch-Ten-GigabitEthernet1/0/2] quit
# 创建接口Vlan-interface2,并配置IP地址。
[Switch] interface vlan-interface 2
[Switch-vlan-interface2] ip address 10.2.1.2 16
[Switch-vlan-interface2] quit
# 使能UDP Helper功能。
[Switch] udp-helper enable
# 配置将目的UDP端口号为55的广播报文进行中继转发。
[Switch] udp-helper port 55
# 配置中继转发的目的服务器为10.2.1.1。
[Switch] interface vlan-interface 1
[Switch-Vlan-interface1] udp-helper server 10.2.1.1
# 配置允许接口接收定向广播报文。
[Switch-Vlan-interface1] ip forward-broadcast
# 显示VLAN接口1的UDP中继转发相关信息。
[Switch-Vlan-interface1] display udp-helper interface vlan-interface 1
Interface Server address Packets sent
Vlan-interface1 10.2.1.1 5
#
udp-helper enable
udp-helper port 55
#
vlan 1
#
vlan 2
#
interface Vlan-interface1
ip address 10.110.1.1 255.255.0.0
ip forward-broadcast
udp-helper server 10.2.1.1
#
interface Vlan-interface2
ip address 10.2.1.2 255.255.0.0
#
interface Ten-GigabitEthernet1/0/1
#
interface Ten-GigabitEthernet1/0/2
port access vlan 2
#
不同款型规格的资料略有差异, 详细信息请向具体销售和400咨询。H3C保留在没有任何通知或提示的情况下对资料内容进行修改的权利!