ensp三层架构实验
需求:
拓扑图:
思路:
IP规划
172.16.2.0/24 vlan1
172.16.3.0/24 vlan2
172.16.0.0/24 骨干链路
(1)首先配置Eth-Trunk
SW1和SW2配置相同
#
interface Eth-Trunk1
#
interface GigabitEthernet0/0/4
eth-trunk 1
#
interface GigabitEthernet0/0/5
eth-trunk 1
(2)划分vlan,配置trunk
SW1,2,3,4上需要Trunk的地方都需要设置trunk或者hybrid
vlan batch 2
#
interface Eth-Trunk1
port link-type trunk
port trunk allow-pass vlan 2
#
interface GigabitEthernet0/0/2
port hybrid tagged vlan 2
#
interface GigabitEthernet0/0/3
port hybrid tagged vlan 2
#
(3)起mstp协议
#
stp region-configuration
region-name a
instance 1 vlan 1
instance 2 vlan 2
active region-configuration
#
将连接PC的接口设置为边缘接口,并且将接口划入对应VLAN
#
interface GigabitEthernet0