四、 实验步骤与配置参考 —— IT 咖啡总公司
四.1 交换部分 VLAN
SW1、SW2、SW3、SW4 上创建 VLAN10、VLAN20,交换机互联配置 TRUNK 只允许 VLAN 10、VLAN20 通过,
连接 PC 的接口配置 ACCESS,划分到对应 VLAN。
LSW1:
system-view
sysname Core-01
vlan 10
quit
vlan 20
quit
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 10 20
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 10 20
interface GigabitEthernet0/0/23
port link-type trunk
port trunk allow-pass vlan 10 20
LSW2:
system-view
sysname Core-02
vlan 10
quit
vlan 20
quit
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 10 20
interface GigabitEthernet0/0/2
port link-type trunk
port trunk allow-pass vlan 10 20
interface GigabitEthernet0/0/23
port link-type trunk
port trunk allow-pass vlan 10 20
LSW3:
system-view
sysname Access-01
vlan 10
quit
vlan 20
quit
interface Ethernet0/0/1
port link-type trunk
port trunk allow-pass vlan 10 20
interface Ethernet0/0/2
port link-type trunk
port trunk allow-pass vlan 10 20
interface Ethernet0/0/3
port link-type access
port default vlan 10
interface Ethernet0/0/4
port link-type access
port default vlan 20
LSW4:
system-view
sysname Access-02
vlan 10
quit
vlan 20
quit
interface Ethernet0/0/1
port link-type trunk
port trunk allow-pass vlan 10 20
interface Ethernet0/0/2
port link-type trunk
port trunk allow-pass vlan 10 20
interface Ethernet0/0/3
port link-type access
port default vlan 10
interface Ethernet0/0/4
port link-type access
port default vlan 20
4 / 17