华为MSTP、VRRP与DHCP综合项目详解

本实验重点考核你们对MSTP、VRRP、DHCP掌握状况,实验要求以下:

实验要求:
1.VLAN 10和vlan 20流量负载均衡;
2.SW1为vlan 10的主网关,vlan 20的备份网关;
3.SW2为vlan 20的主网关,vlan 10的备份网关;
4.DHCP服务器在vlan 66,网关在SW2上面;
5.PC一、PC2自动获取ip地址且能够互相ping通。服务器

实验拓扑以下:

华为MSTP、VRRP与DHCP综合项目详解

第一步,MSTP配置以下:

SW1
sysname SW1
vlan batch 10 20 66
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan all
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan all
stp region-configuration
region-name ntd
instance 10 vlan 10
instance 20 vlan 20
active region-configuration
quit
stp instance 10 priority 4096
stp instance 20 priority 8192
SW2
sysname SW2
vlan batch 10 20 66
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan all
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan all
stp region-configuration
interface GigabitEthernet0/0/10
port link-type access
port default vlan 66
quit
region-name ntd
instance 10 vlan 10
instance 20 vlan 20
active region-configuration
quit
stp instance 10 priority 4096
stp instance 20 priority 8192
SW3
sysname SW3
vlan batch 10 20 66
interface Ethernet0/0/1
port link-type trunk
port trunk allow-pass vlan all
interface Ethernet0/0/2
port link-type trunk
port trunk allow-pass vlan all
interface Ethernet0/0/11
port link-type access
port default vlan 10
interface Ethernet0/0/12
port link-type access
port default vlan 20
quit
stp region-configuration
region-name ntd
instance 10 vlan 10
instance 20 vlan 20
active region-configuration
quit
stp instance 10 priority 4096
stp instance 20 priority 8192负载均衡

第二步,VRRP配置以下:

SW1
interface Vlanif10
ip address 192.168.10.251 255.255.255.0
vrrp vrid 10 virtual-ip 192.168.10.250
vrrp vrid 10 priority 200
interface Vlanif20
ip address 192.168.20.251 255.255.255.0
vrrp vrid 10 virtual-ip 192.168.20.250
interface Vlanif66
ip address 192.168.66.251 255.255.255.0
SW2
interface Vlanif10
ip address 192.168.10.252 255.255.255.0
vrrp vrid 10 virtual-ip 192.168.10.250
interface Vlanif20
ip address 192.168.20.252 255.255.255.0
vrrp vrid 20 virtual-ip 192.168.20.250
vrrp vrid 10 priority 200
interface Vlanif66
ip address 192.168.66.252 255.255.255.0ide

第三步,DHCP配置如:

SW1
dhcp enable
interface Vlanif 10
dhcp select relay
dhcp relay server-ip 192.168.66.250
interface Vlanif 20
dhcp select relay
dhcp relay server-ip 192.168.66.250
SW2
dhcp enable
interface Vlanif 10
dhcp select relay
dhcp relay server-ip 192.168.66.250
interface Vlanif 20
dhcp select relay
dhcp relay server-ip 192.168.66.250
DHCP
sysname DHCP
interface g0/0/0
ip address 192.168.66.250 24
dhcp select global
quit
ip pool p1
gateway-list 192.168.10.250
network 192.168.10.0 mask 255.255.255.0
excluded-ip-address 192.168.10.251 192.168.10.252
lease day 7 hour 0 minute 0
dns-list 8.8.8.8
ip pool p2
gateway-list 192.168.20.250
network 192.168.20.0 mask 255.255.255.0
excluded-ip-address 192.168.20.251 192.168.20.252
lease day 7 hour 0 minute 0
dns-list 8.8.8.8
ip route-static 192.168.10.0 24 192.168.66.251
ip route-static 192.168.20.0 24 192.168.66.252
最后进行验证测试:测试

分别在SW1和SW2上查看STP:
华为MSTP、VRRP与DHCP综合项目详解
华为MSTP、VRRP与DHCP综合项目详解
分别在在SW1和SW2上查看VRRP:
华为MSTP、VRRP与DHCP综合项目详解
华为MSTP、VRRP与DHCP综合项目详解
查看PC机IP地址获取状况以下:
华为MSTP、VRRP与DHCP综合项目详解ui

均知足实验要求,配置完成!!!
相关文章
相关标签/搜索