需求:
- 利用hybrid实现不同VLAN之间的互访(同一个网段)
- 配置不同VLAN之间的互访(tagged、untagged、pvid、trunk)
vlan batch 2 to 3 100
#
interface Ethernet0/0/1
port link-type access
port default vlan 2
#
interface Ethernet0/0/2
port link-type access
port default vlan 3
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
vlan batch 2 to 3 100interface Ethernet0/0/1
port link-type access
port default vlan 2interface Ethernet0/0/2
port link-type access
port default vlan 3interface Ethernet0/0/3
port link-type access
port default vlan 100interface Ethernet0/0/4
port link-type access
port default vlan 100interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
推荐一篇关于hybird的教程 包含实验 下方链接直达
https://www.cnblogs.com/pangsong/p/11901857.html
vlan batch 2 to 3 100clear configuration interface Ethernet 0/0/1
interface Ethernet0/0/1
port hybrid tagged vlan 2
port hybrid untagged vlan 2 100
undo shutdownclear configuration interface Ethernet 0/0/2
interface Ethernet0/0/2
port hybrid tagged vlan 3
port hybrid untagged vlan 3 100
undo shutdownclear configuration interface GigabitEthernet0/0/1
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
undo shutdowndisplay vlan
vlan batch 2 to 3 100clear configuration interface Ethernet 0/0/1
interface Ethernet0/0/1
port hybrid pvid vlan 2
port hybrid untagged vlan 2 100
undo shutdownclear configuration interface Ethernet 0/0/2
interface Ethernet0/0/2
port hybrid pvid vlan 3
port hybrid untagged vlan 3 100
undo shutdownclear configuration interface Ethernet 0/0/3
interface Ethernet0/0/3
port hybrid untagged vlan 2 100
undo shutdownclear configuration interface Ethernet 0/0/4
interface Ethernet0/0/4
port hybrid untagged vlan 3 100undo shutdown
clear configuration interface GigabitEthernet0/0/1
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
undo shutdown
display vlan