Chapter 7 Administering the Switch

Managing the MAC Address Table

Beginning in privileged EXEC mode, follow these steps to add a static address:

 

Command

Purpose

Step 1

 

 

configure terminal

Enter global configuration mode.

Step 2

 

 

mac address-table static mac-addr

Add a static address to the MAC address table.

 

vlan vlan-id interface interface-id

For mac-addr, specify the destination MAC unicast address to add to

 

 

 

 

the address table. Packets with this destination address received in the

 

 

specified VLAN are forwarded to the specified interface.

 

 

For vlan-id, specify the VLAN for which the packet with the

 

 

specified MAC address is received. Valid VLAN IDs are 1 to 4094.

 

 

For interface-id, specify the interface to which the received packet is

 

 

forwarded. Valid interfaces include physical ports or port channels.

 

 

For static multicast addresses, you can enter multiple interface IDs.

 

 

For static unicast addresses, you can enter only one interface at a

 

 

time, but you can enter the command multiple times with the same

 

 

MAC address and VLAN ID.

Step 3

 

 

end

Return to privileged EXEC mode.

Step 4

 

 

show mac address-table static

Verify your entries.

Step 5

 

 

copy running-config startup-config

(Optional) Save your entries in the configuration file.

 

 

 

To remove static entries from the address table, use the no mac address-table static mac-addrvlan vlan-id[interface interface-id] global configuration command.

This example shows how to add the static address c2f3.220a.12f4 to the MAC address table. When a packet is received in VLAN 4 with this MAC address as its destination address, the packet is forwarded to the specified port:

Switch(config)# mac address-table static c2f3.220a.12f4 vlan 4 interface

gigabitethernet1/0/1

Configuring Unicast MAC Address Filtering

When unicast MAC address filtering is enabled, the switch drops packets with specific source or destination MAC addresses. This feature is disabled by default and only supports unicast static addresses.

Follow these guidelines when using this feature:

Multicast MAC addresses, broadcast MAC addresses, and router MAC addresses are not supported. If you specify one of these addresses when entering the mac address-table static mac-addrvlan vlan-iddrop global configuration command, one of these messages appears:

%Only unicast addresses can be configured to be dropped

%CPU destined address cannot be configured as drop address

Packets that are forwarded to the CPU are also not supported.

Catalyst 3750-E and 3560-E Switch Software Configuration Guide

 

OL-9775-02

7-25

 

 

 

Page 191
Image 191
Cisco Systems 3750E manual Configuring Unicast MAC Address Filtering, Mac address-table static mac-addr