Chapter 36: VLAN Commands
Configuring MAC Based VLANs
show mac-vlan
D
S
EFAULT
ETTING
None
C
M
OMMAND
ODE
Global Configuration
C
U
OMMAND
SAGE
The MAC-to-VLAN mapping applies to all ports on the switch.
•
Source MAC addresses can be mapped to only one VLAN ID.
•
•
Configured MAC addresses cannot be broadcast or multicast addresses.
When MAC-based, IP subnet-based, and protocol-based VLANs are
•
supported concurrently, priority is applied in this sequence, and then
port-based VLANs last.
The binary equivalent mask matching the characters in the front of the
•
first non-zero character must all be 1s (e.g., 111, i.e., it cannot be 101
or 001...). A mask for the MAC address: 00-50-6e-00-5f-b1 translated
into binary:
MAC: 00000000-01010000-01101110-00000000-01011111-10110001
could be: 11111111-11xxxxxx-xxxxxxxx-xxxxxxxx-xxxxxxxx-xxxxxxxx
So the mask in hexadecimal for this example could be:
ff-fx-xx-xx-xx-xx/ff-c0-00-00-00-00/ff-e0-00-00-00-00
E
XAMPLE
The following example assigns traffic from source MAC address 00-00-00-
11-22-33 to VLAN 10.
Console(config)#mac-vlan mac-address 00-00-00-11-22-33 vlan 10
Console(config)#
This command displays MAC address-to-VLAN assignments.
C
M
OMMAND
ODE
Privileged Exec
C
U
OMMAND
SAGE
Use this command to display MAC address-to-VLAN mappings.
E
XAMPLE
The following example displays all configured MAC address-based VLANs.
Console#show mac-vlan
MAC Address
VLAN ID
– 1113 –
Priority