5.华为交换机知识【MAC地址vlan】

 任务:配置MAC地址划分vlan

说明:1.MAC地址vlan只能在hybrid类型接口上划分

          2.MAC地址划分vlan仅对untagged报文生效

          3.端口默认情况下没有开启MAC地址划分vlan功能

操作:1.进入系统视图                         system-view

          2.建立vlan                                 vlan 10

          3.配置mac地址与vlan关联          mac-vlan mac-address 000B-09CF-0932

          4.返回系统视图                         quit

          5.进入接口视图                         interface giga 0/0/1

          6.设置接口类型为hybrid接口       port link-type hybrid

          7.接口以untagged方式加入vlan    port hybrid untagged vlan 10

          8.开启接口MAC划分vlan功能      mac-vlan enable

          9.返回系统视图                         quit

          10.查看结果                              disp mac-vlan mac-address all

 

在eNSP模拟器上的命令如下

[Huawei]vlan 10
[Huawei-vlan10]mac-vlan mac-address 000B-09CF-0932
[Huawei-vlan10]quit
[Huawei]interface giga 0/0/1
[Huawei-GigabitEthernet0/0/1]port link-type hybrid
[Huawei-GigabitEthernet0/0/1]port hybrid untagged vlan 10
[Huawei-GigabitEthernet0/0/1]mac-vlan enable
Info: This operation may take a few seconds. Please wait for a moment...done.
[Huawei-GigabitEthernet0/0/1]return
<Huawei>save
The current configuration will be written to the device.
Are you sure to continue?[Y/N]y
Now saving the current configuration to the slot 0.
Save the configuration successfully.
<Huawei>system-view 
Enter system view, return user view with Ctrl+Z.
[Huawei]disp mac-vlan mac-address all
---------------------------------------------------
MAC Address     MASK            VLAN    Priority   
---------------------------------------------------
000b-09cf-0932  ffff-ffff-ffff  10      0         

Total MAC VLAN address count: 1

[Huawei] User interface con0 is available

你可能感兴趣的:(知识,华为交换机)