VLAN 实验

 

 SW1


[Huawei]vlan batch 2 to 6

[Huawei]int g0/0/1

[Huawei-GigabitEthernet0/0/1]port link-type access 

[Huawei-GigabitEthernet0/0/1]port default vlan 2

[Huawei-GigabitEthernet0/0/1]int g0/0/2

[Huawei-GigabitEthernet0/0/2]port link-type  hybrid 

[Huawei-GigabitEthernet0/0/2]port hybrid pvid vlan 3

[Huawei-port-group-hybrid]port hybrid untagged  vlan  2 to 6
[Huawei-port-group-hybrid]q
[Huawei]int g0/0/3
[Huawei-GigabitEthernet0/0/3]port link-type  trunk 
[Huawei-port-group-trunk]port trunk allow-pass vlan 2 to 6
[Huawei]int g0/0/4
[Huawei-GigabitEthernet0/0/4]port hybrid  tagged vlan 2
[Huawei-GigabitEthernet0/0/4]port hybrid untagged vlan 3 to 6

SW2 


[Huawei]vlan batch 2 to 6

[Huawei]int g0/0/1
[Huawei-GigabitEthernet0/0/1]p    

[Huawei-GigabitEthernet0/0/1]port link-type a

[Huawei-GigabitEthernet0/0/1]port default vlan 2

[Huawei-GigabitEthernet0/0/2]port link-type  hybrid 

[Huawei-GigabitEthernet0/0/2]port hybrid  pvid  vlan 4
[Huawei-GigabitEthernet0/0/2]


[Huawei-GigabitEthernet0/0/2]port hybrid  untagged vlan 2 3 4 6
[Huawei-GigabitEthernet0/0/2]


[Huawei-GigabitEthernet0/0/3]port link-type trunk 

[Huawei-GigabitEthernet0/0/3]port trunk allow-pass vlan 2 to 6
[Huawei-GigabitEthernet0/0/3]

[Huawei-GigabitEthernet0/0/3]int g0/0/4

[Huawei-GigabitEthernet0/0/4]port link-type trunk 

[Huawei-GigabitEthernet0/0/4]port trunk allow-pass  vlan 2 to 6

 SW3


[Huawei]vlan batch 2 to 6

[SW3]int g0/0/3

[SW3-GigabitEthernet0/0/3]port trunk allow-pass vlan 2 to 6
[SW3-GigabitEthernet0/0/3]int g0/0/2

[SW3-GigabitEthernet0/0/2]port link-type hybrid 

[SW3-GigabitEthernet0/0/2]port hybrid  pvid vlan 5

[SW3-GigabitEthernet0/0/2]port hybrid  untagged  vlan 2 3 5

 R1


[R1]int g0/0/0
[R1-GigabitEthernet0/0/0]ip address 192.168.2.254 255.255.255.0
[R1-GigabitEthernet0/0/0]dhcp select interface 
[R1-GigabitEthernet0/0/0]dhcp server  lease day 1 hour 0 m 0
[R1-GigabitEthernet0/0/0]dhcp server dns-list  114.114.114.114


[R1-GigabitEthernet0/0/0]int g0/0/0.1
[R1-GigabitEthernet0/0/0.1]dot1q  termination  vid 2
[R1-GigabitEthernet0/0/0.1]dhcp  select interface 
[R1-GigabitEthernet0/0/0.1]dhcp server lease  day 1 hour 0 m 0
[R1-GigabitEthernet0/0/0.1]dhcp server dns-list 114.114.114.114

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值