华为DHCP全局、端口、中继配置
华为交换机配置DHCP代理

多VLAN 链路聚合 DHCP RELAY
配置要求:
1、划分多个vlan 2、每个vlan通过DHCP获取相对应的ip地址 3、交换机采用链路聚合LA
配置步骤:
• 1、配置DHCP服务器(2种方法) • 2、测试划分4个VLAN,vlan100、vlan101、vlan102、vlan103 • 3、IP地址规划为192.168.0.0 • 4、配置三层交换机链路聚合LA • 5、配置SW-VLAN100-01交换机 • 6、配置SW-VLAN101-01交换机
• #批量添加DHCP作用域选项
• Add-DhcpServerV4Scope -Name "vlan100" -StartRange 192.168.0.20 -EndRange 192.168.0.240 -SubnetMask 255.255.255.0 -Type Both -State Active -Description vlan100
//链路聚合LA配置
• Port link-type trunk
• Port trunk allow-pass vlan all
• Mode lacp
• Trunkport g 0/0/23 to 0/0/24
• Port-group vlan100
//批量将端口划入VLAN100
• Group-member g0/0/1 to g0/0/22
• Interface eth-trunk11 • Port link-type trunk • Port trunk allow-pass vlan all • Mode lacp • Trunkport g 0/0/3 to 0/0/4
华为交换机DHCPsnooping配置教程

华为交换机DHCP snooping配置教程DHCP Snooping是一种DHCP平安特性,在配置DHCP Snooping各平安功能之前需首先使能DHCP Snooping功能。
使能DHCP Snooping功能的顺序是先使能全局下的DHCP Snooping功能,再使能接口或VLAN下的DHCP Snooping功能。
图1配置DHCP Snooping根本功能组网图如上图1所示,Switch_1是二层接入设备,将用户PC的DHCP请求转发给DHCP 效劳器。
以Switch_1为例,在使能DHCP Snooping功能时需要注意:使能DHCP Snooping功能之前,必须已使用命令dhcp enable使能了设备的DHCP功能。
全局使能DHCP Snooping功能后,还需要在连接用户的接口〔如图中的接口if1、if2和if3〕或其所属VLAN〔如图中的VLAN 10〕使能DHCP Snooping功能。
当存在多个用户PC属于同一个VLAN时,为了简化配置,可以在这个VLAN 使能DHCP Snooping功能。
请在二层网络中的接入设备或第一个DHCP Relay上执行以下步骤。
1、使能DHCP Snooping功能[Huawei]dhcp snooping enable ?ipv4DHCPv4 Snoopingipv6DHCPv6 Snoopingvlan Virtual LAN<cr>或[Huawei]dhcp snooping over-vpls enable#使能设备在VPLS网络中的DHCP Snooping功能或[Huawei-vlan2]dhcp snooping enable[Huawei-GigabitEthernet0/0/3]dhcp snooping enable2、配置接口信任状态[Huawei-GigabitEthernet0/0/2]dhcp snooping trusted或[Huawei-vlan3]dhcp snooping trusted interface GigabitEthernet 0/0/63、去使能DHCP Snooping用户位置迁移功能在移动应用场景中,假设某一用户由接口A上线后,切换到接口B重新上线,用户将发送DHCP Discover报文申请IP地址。
华为路由交换配置DHCP及DHCP中继

DHCP协ቤተ መጻሕፍቲ ባይዱ系统组成
DHCP Client
DHCP Client通过DHCP协议来获得网络配置参数 通常是一台主机或网络设备
DHCP Server
DHCP Server提供网络设置参数给DHCP Client 通常是一台服务器或网络设备
DHCP Relay
在DHCP Client和DHCP Server之间跨网段转发DHCP消息 通常是网络设备
由DHCP Client向DHCP Server提出配置申请,DHCP Server根据策略返回相应配置信息。
DHCP报文采用UDP进行封装,识别采用端口号
DHCP Client使用68,DHCP Server使用67。
DHCP协议特点
整个配置过程自动实现,DHCP Client端无需配置 所有配置信息由DHCP Server统一管理 通过IP地址租期管理,提高IP地址的使用效率 采用广播实现报文交互,报文一般不能跨网段,如 果需跨网段,需要使用DHCP Relay技术实现
Manual Allocation
网络管理员为某些少数特定的主机绑定固定IP地址,且 地址不会过期
DHCP协议分配地址的优先级
DHCP Server数据库中与该DHCP Client的MAC地址静 态绑定的IP地址 该DHCP Client曾经使用过的地址 顺序查找DHCP地址池中可供分配的IP地址,最先找到的 可用IP地址,优先级高 如果未找到可用的IP地址,则依次查询超过租期、发生冲 突的IP地址 找不到则报告错误
Unicast或 Broadcast Unicast或 Broadcast
DHCP Client
DHCPDISCOVER DHCPOFFER DHCPREQUEST DHCPACK/NAK DHCPDECLINE
华为交换机5700&2700的VLAN、DHCP、ACL配置

拓扑说明:比较简单的三层环境,防火墙进来后接三层交换机s5700,然后接的几台二层交换机s2700,本文只对几个主要的应用配置做个描述1.vlan、gvrp相关配置举例:三层交换机:[5700]vlan 11 创建VLAN11[5700-vlan11]description xxx 加入描述信息xxx[5700-vlan11]quit[5700]gvrp 要用gvrp的话,全局模式下必须开启gvrp [5700]interface g0/0/23 进入与2层交换机连接的端口准备配置中继[5700-GigabitEthernet0/0/23]gvrp 中继端口下开启gvrp[5700-GigabitEthernet0/0/23]port link-type trunk 端口类型设置为trunk[5700-GigabitEthernet0/0/23]port trunk allow-pass vlan all 设置允许通过的vlan为所有,也可设为指定的vlan[5700-GigabitEthernet0/0/23]quit二层交换机:发现华为上不能批量进入端口,只有通过先创建端口组,再把响应端口加入组的方式来实现批量管理,比如我们要在2700上把千兆口都设为trunk口:[2700]port-group trunk 创建名为turnk的端口组,也可取其他名字。
如果已有此名,则会直接进入此端口组[2700-1-port-group-trunk]group-member g0/0/1 to g0/0/4 宣告组成员为G0/0/1到G0/0/4[2700-1-port-group-trunk]port link-type trunk 此组设为中继,即G0/0/1到G0/0/4都为中继[2700-1-port-group-trunk]port trunk allow-pass vlan all 这几步都和三层的配置一样,不同的是我们这里是进行的批量配置[2700-1-port-group-trunk]gvrp[2700-1-port-group-trunk]quit下面把相应端口加入vlan,这里我觉得端口组以vlan命名较为合适[2700]port group vlan11[2700-1-port-group- vlan11]group-member e0/0/1 to e0/0/4 [2700-1-port-group- vlan11]port link-type access 端口设置为access口[2700-1-port-group- vlan11]port default vlan 11 把E0/0/1-4口加入vlan11[2700-1-port-group- vlan11]quit以上VLAN的配置基本完成。
华为技术命令(三)dhcp中继配置命令

华为技术命令(三)dhcp中继配置命令DHCP 中继配置命令【命令】debugging ip relay protocol【视图】所有视图【参数】无【描述】debugging ip relay protocol 命令用来打开DHCP 中继和透传调试信息开关。
【命令】display ip relay protocol【视图】所有视图【参数】无【描述】display ip relay protocol 命令用来显示当前透传转发协议的运行情况。
命令】display ip relay-address【视图】所有视图【参数】无【描述】display ip relay-address 命令用来显示各接口的辅助地址的配置情况。
【举例】无【命令】ip relay protocol udp portundo ip relay protocol udp [ port ]【视图】系统视图【参数】port:转发UDP 报文的端口号。
【描述】ip relay protocol udp 命令用来配置透传转发协议及其使用的端口号,undoip relay protocol udp 命令用来取消透传转发协议及其端口号。
对于DHCP 中继来说,IP 辅助地址指定的是DHCP 服务器的地址。
配置辅助IP 地址后,从该接口上收到的广播报文,会发送到该服务器上去。
能够配置IP 辅助地址的接口应当支持广播方式。
每个接口最多可配置20 个辅助地址。
命令】ip relay-address ip-addressundo ip relay-address [ ip-address ]视图】以太网接口视图【参数】ip-address:为地址池起始IP 地址.【描述】ip relay-address 命令用来配置以太网口进行透传转发的辅助地址,undo ipITrelay-address 命令用来取消已配置的辅助地址。
缺省情况下,以太网口未配置辅助IP 地址。
华为DHCP全局、端口、中继配置

华为DHCP全局、端⼝、中继配置LSW1全局配置DHCPundo terminal monitorInfo: Current terminal monitor is off.system-viewEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 10 11Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]ip pool 110(创建地址池) Info:It's successful to create an IP address pool.[Huawei-ip-pool-110]network 192.168.0.0 mask 24[Huawei-ip-pool-110]gateway-list 192.168.0.1[Huawei-ip-pool-110]dns-list 8.8.8.8[Huawei-ip-pool-110]lease day 0 hour 2[Huawei-ip-pool-110]excluded-ip-address 192.168.0.250 192.168.0.254 [Huawei-ip-pool-110]qui [Huawei]int e0/0/3[Huawei-Ethernet0/0/3]qui[Huawei]vlan batch 2 3Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]vlan 10[Huawei-vlan10]aggregate-vlan[Huawei-vlan10]access-vlan 2 3[Huawei]int vlanif 10[Huawei-Vlanif10]ip address 192.168.0.1 24[Huawei-Vlanif10]dhcp select global[Huawei-Vlanif10]qui[Huawei]int vlanif 11[Huawei-Vlanif11]ip add 10.0.0.1 30[Huawei-Vlanif11]qui[Huawei]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 2 3[Huawei-Ethernet0/0/3]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 11[Huawei-Ethernet0/0/1]qui[Huawei]ip route-static 192.168.1.0 24 10.0.0.2[Huawei]ip route-static 192.168.2.0 24 10.0.0.2[Huawei]ip route-static 10.0.0.4 30 10.0.0.2[Huawei]ip route-static 10.0.0.8 30 10.0.0.2[Huawei]LSW2undo terminal monitorInfo: Current terminal monitor is off.system-viewEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 2 3Info: This operation may take a few seconds. Please wait for a moment...done. [Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 2[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 3[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3] User interface con0 is availableLSW3端⼝配置DHCPundo terminal monitorInfo: Current terminal monitor is off.sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 11 20 21 5 6Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]int vlanif 11[Huawei-Vlanif11]ip add 10.0.0.2 30[Huawei-Vlanif11]int vlanif 21[Huawei-Vlanif21]ip add 10.0.0.5 30[Huawei-Vlanif21]qui[Huawei]vlan 20[Huawei-vlan20]aggregate-vlan[Huawei-vlan20]access-vlan 5 6[Huawei-vlan20]qui[Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]int vlanif 20 [Huawei-Vlanif20]ip add 192.168.1.1 24[Huawei-Vlanif20]dhcp select interface[Huawei-Vlanif20]dhcp server dns-list 8.8.8.8[Huawei-Vlanif20]dhcp server lease day 0 hour 3[Huawei-Vlanif20]dhcp server excluded-ip-address 192.168.1.250192.168.1.254[Huawei-Vlanif20]qui[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 11[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 21[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]qui[Huawei]ip route-static 192.168.1.0 24 10.0.0.1[Huawei]undo ip route-static 192.168.1.0 24 10.0.0.1[Huawei]ip route-static 192.168.0.0 24 10.0.0.1[Huawei]ip route-static 192.168.2.0 24 10.0.0.6[Huawei]ip route-static 10.0.0.8 24 10.0.0.6Info: The destination address and mask of the configured static route mismatched , and the static route 10.0.0.0/24 was generated.[Huawei]ip route-static 10.0.0.8 30 10.0.0.6[Huawei] User interface con0 is availableLSW4Huawei>undo terminal monitorInfo: Current terminal monitor is off.sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 5 6Info: This operation may take a few seconds. Please wait for a moment...done. [Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 5[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 6[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 5 6[Huawei-Ethernet0/0/3] User interface con0 is availableLSW5中继配置DHCPundo ter mInfo: Current terminal monitor is off.sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 21 30[Huawei][Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]int vlanif 21[Huawei-Vlanif21]ip add 10.0.0.6 30[Huawei-Vlanif21]int vlanif 30[Huawei-Vlanif30]ip add 10.0.0.9 30[Huawei-Vlanif30]qui[Huawei]int vlanif 30[Huawei-Vlanif30][Huawei-Vlanif30] dhcp select global[Huawei-Vlanif30]qui[Huawei]ip pool 300Info:It's successful to create an IP address pool. [Huawei-ip-pool-300]network 192.168.2.0 mask 24 [Huawei-ip-pool-300]gateway-list 192.168.2.1[Huawei-ip-pool-300]dns-list 8.8.8.8[Huawei-ip-pool-300]lease day 0 hour 2[Huawei-ip-pool-300]qui[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port defaul vlan 30[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port defaul vlan 21[Huawei-Ethernet0/0/2] User interface con0 is available [Huawei]ip route-static 192.168.0.0 24 10.0.0.5 [Huawei]ip route-static 192.168.1.0 24 10.0.0.5 [Huawei]ip route-static 10.0.0.0 30 10.0.0.5[Huawei]ip route-static 192.168.2.0 24 10.0.0.10LSW6undo terminal monitorInfo: Current terminal monitor is off.langu chineseChange language mode, confirm? [Y/N] y提⽰:改变语⾔模式成功。
华为交换机配置DHCP中继

华为交换机配置DHCP中继
很多情况下我们需要在三层交换机上配置一下DHCP中继服务;
用以为下面的客户机提供DHCP中继服务;
就是说三层交换机上可以为DHCP端口转发数据到指定的DHCP服务器上;而不会因为是跨VLAN就导致客户机获取不到DHCP分配的IP地址;
方法/步骤
请先确保你的电脑和华为交换机连接成功
进入管理视图
<Quidway> system-view
接着dhcp enable 开启交换机的DHCP服务
接着进入虚拟vlan 视图
[Quidway]interface Vlanif 100
配置一个IP地址
[Quidway-Vlanif100] ip address 192.168.104.253 255.255.255.0
然后开始dhcp中继功能
[Quidway-Vlanif100]dhcp select relay
配置DHCP服务器IP地址
[Quidway-Vlanif100]ip relay address 10.10.100.171
到此华为交换机的DHCP中继功能就配置完成了
记得要save保存配置。
华为dhcp命令详解和配置案例整理

华为dhcp命令详解和配置案例整理必选配置system-view进入系统视图dhcp enable开启DHCP服务interface vlanif 1VLANIF 1 接口视图ip address 192.168.1.1VLANIF接口的IP地址dhcp select global能接口的DHCP服务功能,指定DHCP服务器从全局地址池分配地址。
(可以加在接口或VLAN下)quit离开当前视图ip pool bg进入全局地址池bgnetwork mask 255.255.250.0配置地址池下的IP地址范围gateway-list 192.168.1.1DHCP的网关可选配置domain-name XXX配置分配给DHCP客户端的DNS域名后缀(可选中的可选)dns-list 202.106.0.20 8.8.4.4配置DNS主和备lease day 1 hour 1 minute 1配置IP地址租期,此配置为一天一小时一分钟,默认为一天,unlimited为无限excluded-ip-address 192.168.1.100 192.168.1.254excluded-ip-address 192.168.1.1配置地址池中不参与自动分配的IP地址,多次执行该命令,可以配置多个不参与自动分配的IP地址段。
static-bind ip-address 172.16.35.253 mac-address 28d2-4469-5a55当一个用户需要固定的IP地址时,可以将地址池中没有在使用的IP地址与用户的MAC地址绑定。
DHCP中继当客户端与DHCP服务器不在同一网段时,通过在DHCP中继设备转发客户端到DHCP服务器的请求。
dhcp enable开启DHCP功能interface vlanif 1VLANIF 1 接口视图ip address 192.168.1.1VLANIF接口的IP地址dhcp select relay启动VLANIF接口的DHCP中继功能。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
LSW1全局配置DHCP<Huawei><Huawei>undo terminal monitorInfo: Current terminal monitor is off.<Huawei>system-viewEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 10 11Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]ip pool 110(创建地址池)Info:It's successful to create an IP address pool.[Huawei-ip-pool-110]network 192.168.0.0 mask 24[Huawei-ip-pool-110]gateway-list 192.168.0.1[Huawei-ip-pool-110]dns-list 8.8.8.8[Huawei-ip-pool-110]lease day 0 hour 2[Huawei-ip-pool-110]excluded-ip-address 192.168.0.250 192.168.0.254 [Huawei-ip-pool-110]qui[Huawei]int e0/0/3[Huawei-Ethernet0/0/3]qui[Huawei]vlan batch 2 3Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]vlan 10[Huawei-vlan10]aggregate-vlan[Huawei-vlan10]access-vlan 2 3[Huawei-vlan10]qui[Huawei]int vlanif 10[Huawei-Vlanif10]ip address 192.168.0.1 24[Huawei-Vlanif10]dhcp select global[Huawei-Vlanif10]qui[Huawei]int vlanif 11[Huawei-Vlanif11]ip add 10.0.0.1 30[Huawei-Vlanif11]qui[Huawei]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 2 3[Huawei-Ethernet0/0/3]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 11[Huawei-Ethernet0/0/1]qui[Huawei]ip route-static 192.168.1.0 24 10.0.0.2[Huawei]ip route-static 192.168.2.0 24 10.0.0.2[Huawei]ip route-static 10.0.0.4 30 10.0.0.2[Huawei]ip route-static 10.0.0.8 30 10.0.0.2[Huawei]LSW2<Huawei><Huawei>undo terminal monitorInfo: Current terminal monitor is off.<Huawei>system-viewEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 2 3Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 2[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 3[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 2 3[Huawei-Ethernet0/0/3] User interface con0 is availableLSW3端口配置DHCP<Huawei>undo terminal monitorInfo: Current terminal monitor is off.<Huawei>sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 11 20 21 5 6Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]int vlanif 11[Huawei-Vlanif11]ip add 10.0.0.2 30[Huawei-Vlanif11]int vlanif 21[Huawei-Vlanif21]ip add 10.0.0.5 30[Huawei-Vlanif21]qui[Huawei]vlan 20[Huawei-vlan20]aggregate-vlan[Huawei-vlan20]access-vlan 5 6[Huawei-vlan20]qui[Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]int vlanif 20[Huawei-Vlanif20]ip add 192.168.1.1 24[Huawei-Vlanif20]dhcp select interface[Huawei-Vlanif20]dhcp server dns-list 8.8.8.8[Huawei-Vlanif20]dhcp server lease day 0 hour 3[Huawei-Vlanif20]dhcp server excluded-ip-address 192.168.1.250192.168.1.254[Huawei-Vlanif20]qui[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 11[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 21[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 5 6[Huawei-Ethernet0/0/3]qui[Huawei]ip route-static 192.168.1.0 24 10.0.0.1[Huawei]undo ip route-static 192.168.1.0 24 10.0.0.1[Huawei]ip route-static 192.168.0.0 24 10.0.0.1[Huawei]ip route-static 192.168.2.0 24 10.0.0.6[Huawei]ip route-static 10.0.0.8 24 10.0.0.6Info: The destination address and mask of the configured static route mismatched, and the static route 10.0.0.0/24 was generated.[Huawei]ip route-static 10.0.0.8 30 10.0.0.6[Huawei] User interface con0 is availableLSW4Huawei>undo terminal monitorInfo: Current terminal monitor is off.<Huawei>sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 5 6Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port default vlan 5[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port default vlan 6[Huawei-Ethernet0/0/2]int e0/0/3[Huawei-Ethernet0/0/3]port link-type trunk[Huawei-Ethernet0/0/3]port trunk allow-pass vlan 5 6[Huawei-Ethernet0/0/3] User interface con0 is availableLSW5中继配置DHCP<Huawei>undo ter mInfo: Current terminal monitor is off.<Huawei>sysEnter system view, return user view with Ctrl+Z.[Huawei]vlan batch 21 30Info: This operation may take a few seconds. Please wait for a moment...done.[Huawei][Huawei]dhcp enableInfo: The operation may take a few seconds. Please wait for a moment.done. [Huawei]int vlanif 21[Huawei-Vlanif21]ip add 10.0.0.6 30[Huawei-Vlanif21]int vlanif 30[Huawei-Vlanif30]ip add 10.0.0.9 30[Huawei-Vlanif30]qui[Huawei]int vlanif 30[Huawei-Vlanif30][Huawei-Vlanif30] dhcp select global[Huawei-Vlanif30]qui[Huawei]ip pool 300Info:It's successful to create an IP address pool. [Huawei-ip-pool-300]network 192.168.2.0 mask 24 [Huawei-ip-pool-300]gateway-list 192.168.2.1[Huawei-ip-pool-300]dns-list 8.8.8.8[Huawei-ip-pool-300]lease day 0 hour 2[Huawei-ip-pool-300]qui[Huawei]int e0/0/1[Huawei-Ethernet0/0/1]port link-type access[Huawei-Ethernet0/0/1]port defaul vlan 30[Huawei-Ethernet0/0/1]int e0/0/2[Huawei-Ethernet0/0/2]port link-type access[Huawei-Ethernet0/0/2]port defaul vlan 21[Huawei-Ethernet0/0/2] User interface con0 is available [Huawei]ip route-static 192.168.0.0 24 10.0.0.5 [Huawei]ip route-static 192.168.1.0 24 10.0.0.5 [Huawei]ip route-static 10.0.0.0 30 10.0.0.5[Huawei]ip route-static 192.168.2.0 24 10.0.0.10LSW6<Huawei>undo terminal monitorInfo: Current terminal monitor is off.<Huawei>langu chineseChange language mode, confirm? [Y/N] y提示:改变语言模式成功。