首页 > 代码库 > 华为DHCP interface

华为DHCP interface

技术分享SW1关键配置如下:

dhcp enable


interface Vlanif10

 ip address 192.168.10.1 255.255.255.0

 dhcp select interface

#

interface Vlanif20

 ip address 192.168.20.1 255.255.255.0

 dhcp select interface

#

interface MEth0/0/1

#

interface GigabitEthernet0/0/1

 port link-type trunk

 port trunk allow-pass vlan 2 to 4094

#


SW2关键配置如下:

interface Ethernet0/0/1

 port link-type trunk

 port trunk allow-pass vlan 2 to 4094

#

interface Ethernet0/0/2

 port link-type access

 port default vlan 10

#

interface Ethernet0/0/3

 port link-type access

 port default vlan 20

#


结果验证:

技术分享


备注:如若获取DNS,则

interface vlanif 10

dhcp server dns-list 10.10.10.10

即可。

vlanif 20同理。

本文出自 “互联互通” 博客,请务必保留此出处http://jschinamobile.blog.51cto.com/11464420/1916964

华为DHCP interface