How did the Switch generate MAC for vlan interface ?

1

For S switch, before V1R6, all the vlan interface share one MAC address from system,after V1R6, the different vlan interface has different MAC, you can check through "display interface vlanif vlanid"
For E switch, the different vlan interface has different MAC.

Other related questions:
Can an interface on an S series switch learn the MAC address entries in a VLAN if the interface is not added to the VLAN
For S series switches (except the S1700), if an interface is not added to a VLAN, the interface does not learn the MAC address entries in the VLAN.

MAC-based VLAN assignment on S series switch
Example of configuring MAC address-based VLAN assignment for S series switches (except S1700 switches): 1. Configuration roadmap 1). Create a VLAN and determine the VLAN to which employees belong. 2). Configure the modes in which interfaces are added to the VLAN, so that the interfaces allow packets of the VLAN to pass through. 3). Associate the MAC address with the VLAN, so that the switch can determine the VLAN to which received packets belong according to the source MAC address in the packets. 2. Configuration procedure [HUAWEI] vlan batch 10 //Create a VLAN. [HUAWEI] interface gigabitethernet 0/0/1 [HUAWEI-GigabitEthernet0/0/1] port link-type hybrid [HUAWEI-GigabitEthernet0/0/1] port hybrid tagged vlan 10 //Add an uplink interface to the VLAN in tagged mode. [HUAWEI-GigabitEthernet0/0/1] quit [HUAWEI] interface gigabitethernet 0/0/2 [HUAWEI-GigabitEthernet0/0/2] port link-type hybrid [HUAWEI-GigabitEthernet0/0/2] port hybrid untagged vlan 10 //Add a downlink interface to the VLAN in untagged mode. [HUAWEI-GigabitEthernet0/0/2] quit [HUAWEI] vlan 10 [HUAWEI-vlan10] mac-vlan mac-address 22-22-22 //Associate the PC's MAC address with VLAN 10. [HUAWEI-vlan10] quit [HUAWEI] interface gigabitethernet 0/0/2 [HUAWEI-GigabitEthernet0/0/2] mac-vlan enable //Enable MAC address-based VLAN assignment on the downlink interface. [HUAWEI-GigabitEthernet0/0/2] quit

how did S switch isolate L2 traffic ?
S Switch can implement layer 2 isolation through traffic policy and port isolation.please refer http://support.huawei.com/ehedex/hdx.do?lib=DOC100000847031185721&docid=DOC1000008470&v=05&tocLib=DOC100000847031185721&tocV=05&id=dc_s_web_090157&tocURL=resources%252fs%252fdc%255fs%255fweb%255f090157%255fx7%252ehtml&p=t&fe=1&ui=3&keyword=isol&clientWidth=1325&browseTime=1490106452862

How to bind the IP address, MAC address, and interface
The Switch implements binding between an interface and a MAC address through the traffic policy and DHCP snooping. Then the interface allows only the packets with the bound MAC address and packets matching the DHCP snooping binding table to pass through. The Switch does support binding of IP address + MAC address + interface. For example, to configure Ethernet 0/0/1 to allow only the packets with the source MAC address being 0-02-02 apart from of the packets matching the DHCP snooping binding table, and discard other packets, do as follows: # Enable DHCP snooping globally. [HUAWEI] dhcp snooping enable# Create an ACL that permits only the packets with the source MAC address being 0-02-02. [HUAWEI] acl 4000 [HUAWEI-acl-L2-4000] rule permit source-mac 0-02-02 ffff-ffff-ffff [HUAWEI-acl-L2-4000] rule deny# Create a traffic classifier that matches ACL 4000. [HUAWEI] traffic classifier c1 [HUAWEI-classifier-c1] if-match acl 4000# Create a traffic behavior and a traffic policy. [HUAWEI] traffic behavior b1 [HUAWEI-behavior-b1] permit [HUAWEI] traffic policy p1 [HUAWEI-trafficpolicy-p1] classifier c1 behavior b1# Apply the traffic policy to Ethernet 0/0/1 so that the interface allows only the packets with the source MAC address 0-02-02 to pass through apart from of the packets matching the DHCP snooping binding table. In V100R005C00 and later versions, the configuration is as follows: [HUAWEI] interface Ethernet 0/0/1 [HUAWEI-Ethernet0/0/1] port default vlan 4094 [HUAWEI-Ethernet0/0/1] ip source check user-bind enable [HUAWEI-Ethernet0/0/1] traffic-policy p1 inbound

If you have more questions, you can seek help from following ways:
To iKnow To Live Chat
Scroll to top