H3C Technologies H3C S10500 Series Switches User Manual
Page 138

127
To do...
Use the command...
Remarks
Enter system view
system-view
—
Associate a specific MAC
address with a VLAN
mac-vlan mac-address
mac-address [ mask
mac-mask ] vlan vlan-id
[ priority priority ]
Required
Enter Ethernet
interface view
interface interface-type
interface-number
Enter
interface
view or port
group view
Enter port group
view
port-group manual
port-group-name
Use either command.
•
The configuration made in Ethernet
interface view applies only to the port.
•
The configuration made in port group
view applies to all ports in the port
group.
Configure the link type of the
ports as hybrid
port link-type hybrid
Required
By default, all ports are access ports.
Configure the hybrid ports to
permit packets from specific
MAC-based VLANs to pass
through
port hybrid vlan vlan-id-list
{ tagged | untagged }
Required
By default, a hybrid port only permits the
packets from VLAN 1 to pass through.
Enable the MAC-based VLAN
feature
mac-vlan enable
Required
Disabled by default.
Configure VLAN matching
precedence
vlan precedence { mac-vlan |
ip-subnet-vlan }
Optional
By default, VLANs are preferentially
matched based on MAC addresses.
Follow these steps to configure dynamic MAC-based VLAN assignment:
To do...
Use the command...
Remarks
Enter system view
system-view
—
Associate MAC addresses
with a VLAN
mac-vlan mac-address mac-address
[ mask mac-mask ] vlan vlan-id
[ priority priority ]
Required
Enter Ethernet interface view
interface interface-type
interface-number
—
Configure the link type of the
port as hybrid
port link-type hybrid
Required
By default, all ports are access ports.
Enable the MAC-based VLAN
feature
mac-vlan enable
Required
Disabled by default.
Enable dynamic MAC-based
VLAN assignment
mac-vlan trigger enable
Required
By default, dynamic MAC-based
VLAN assignment is disabled.
Configure VLAN matching
precedence
vlan precedence mac-vlan
Optional
By default, VLANs are preferentially
matched based on MAC addresses.