如何用华为模拟器eNSP配置VLAN

1)创建VLAN 10、20、30

2)将端口加入VLAN

3)查看VLAN信息

使用eNSP搭建实验环境,如图-1所示。
如何用华为模拟器eNSP配置VLAN_第1张图片
图-1
1.3 步骤

实现此案例需要按照如下步骤进行。

1)创建VLAN 10、20、30

system-view 
[Huawei]vlan 10
[Huawei]vlan 20
[Huawei]vlan 30

2)将端口加入VLAN

[Huawei]interface Ethernet0/0/1
[Huawei-Ethernet0/0/1]port link-type access 
[Huawei-Ethernet0/0/1]port default vlan 10
[Huawei]interface Ethernet0/0/2
[Huawei-Ethernet0/0/2]port link-type access 
[Huawei-Ethernet0/0/2]port default vlan 10
[Huawei]interface Ethernet0/0/3
[Huawei-Ethernet0/0/3]port link-type access 
[Huawei-Ethernet0/0/3]port default vlan 20
[Huawei]interface Ethernet0/0/4
[Huawei-Ethernet0/0/4]port link-type access 
[Huawei-Ethernet0/0/4]port default vlan 20
[Huawei]interface Ethernet0/0/5
[Huawei-Ethernet0/0/5]port link-type access 
[Huawei-Ethernet0/0/5]port default vlan 20
[Huawei]interface Ethernet0/0/6
[Huawei-Ethernet0/0/6]port link-type access 
[Huawei-Ethernet0/0/6]port default vlan 30
[Huawei]interface Ethernet0/0/7
[Huawei-Ethernet0/0/7]port link-type access 
[Huawei-Ethernet0/0/7]port default vlan 30

3)查看VLAN信息

[Huawei]dis vlan
The total number of vlans is : 4
--------------------------------------------------------------------
U: Up;         D: Down;         TG: Tagged;         UT: Untagged;
MP: Vlan-mapping;               ST: Vlan-stacking;
#: ProtocolTransparent-vlan;    *: Management-vlan;
--------------------------------------------------------------------
VID  Type    Ports                                                          
--------------------------------------------------------------------------------
1    common  UT:Eth0/0/8(D)     Eth0/0/9(D)     Eth0/0/10(D)    Eth0/0/11(D)    
                Eth0/0/12(D)    Eth0/0/13(D)    Eth0/0/14(D)    Eth0/0/15(D)    
                Eth0/0/16(D)    Eth0/0/17(D)    Eth0/0/18(D)    Eth0/0/19(D)    
                Eth0/0/20(D)    Eth0/0/21(D)    Eth0/0/22(D)    GE0/0/1(D)      
                GE0/0/2(D)                                                      
10   common  UT:Eth0/0/1(D)     Eth0/0/2(D)                                     
20   common  UT:Eth0/0/3(D)     Eth0/0/4(D)     Eth0/0/5(D)                     
30   common  UT:Eth0/0/6(D)     Eth0/0/7(D)                                     
VID  Status  Property      MAC-LRN Statistics Description      
--------------------------------------------------------------------
1    enable  default       enable  disable    VLAN 0001                         
10   enable  default       enable  disable    VLAN 0010                         
20   enable  default       enable  disable    VLAN 0020                         
30   enable  default       enable  disable    VLAN 0030   
[Huawei]dis port vlan
Port                    Link Type    PVID  Trunk VLAN List
--------------------------------------------------------------------
Ethernet0/0/1           access       10    -                                   
Ethernet0/0/2           access       10    -                                   
Ethernet0/0/3           access       20    -                                   
Ethernet0/0/4           access       20    -                                   
Ethernet0/0/5           access       20    -                                   
Ethernet0/0/6           access       30    -                                   
Ethernet0/0/7           access       30    -                                   
Ethernet0/0/8           hybrid       1     -                                   
Ethernet0/0/9           hybrid       1     -                                   
Ethernet0/0/10          hybrid       1     -                                   
Ethernet0/0/11          hybrid       1     -                                   
Ethernet0/0/12          hybrid       1     -                                   
Ethernet0/0/13          hybrid       1     -                                   
Ethernet0/0/14          hybrid       1     -                                   
Ethernet0/0/15          hybrid       1     -                                   
Ethernet0/0/16          hybrid       1     -                                   
Ethernet0/0/17          hybrid       1     -                                   
Ethernet0/0/18          hybrid       1     -                                   
Ethernet0/0/19          hybrid       1     -                                   
Ethernet0/0/20          hybrid       1     -                                   
Ethernet0/0/21          hybrid       1     -                                   
Ethernet0/0/22          hybrid       1     -                                   
GigabitEthernet0/0/1    hybrid       1     -                                   
GigabitEthernet0/0/2    hybrid       1     -   

你可能感兴趣的:(华为网络杂谈)