标签:info code ace mamicode 进入 图片 子网 5.0 inter
给主机配置IP地址,然后分别给两个交换机创建vlan 10 和vlan 20,接着进入接口模式(interface gi),把主机配置成vlan 10和vlan 20(access),接着两个交换机都用trunk模式
左边:主机1:IP地址192.168.10.1子网掩码255.255.255.0
主机2:IP地址192.168.10.2子网掩码255.255.255.0
主机3:IP地址192.168.20.1子网掩码255.255.255.0
主机4:IP地址192.168.20.2子网掩码255.255.255.0
右边:主机1:IP地址192.168.10.3子网掩码255.255.255.0
主机2:IP地址192.168.20.3子网掩码255.255.255.0
左边交换机:
sys
vlan 10
vlan 20
interface gi 1/0/1
port link-type access
port access vlan 10
interface gi 1/0/2
port link-type access
port access vlan 10
interface gi 1/0/3
port link-type access
port access vlan 20
interface gi 1/0/4
port link-type access
port access vlan 20
qu
interface gi 1/0/48
port link-type trunk
port trunk permit vlan 10 20
右边交换机:
sys
vlan 10
vlan 20
interface gi 1/0/1
port link-type access
port access vlan 10
interface gi 1/0/2
port link-type access
port access vlan 20
qu
interface gi 1/0/48
port link-type trunk
port trunk permit vlan 10 20
标签:info code ace mamicode 进入 图片 子网 5.0 inter
原文地址:https://www.cnblogs.com/danmin/p/10861425.html