58
MAC address table commands
The MAC address table contains only Layer 2 Ethernet interfaces and Layer 2 aggregate interfaces.
This document covers only the configuration of unicast MAC address entries, including static, dynamic,
and destination blackhole MAC address entries.
display mac-address
Use
display mac
-
address
to display MAC address entries.
Syntax
display mac-address
[
mac
-
address
[
vlan
vlan-id
] | [ [
dynamic
|
static
] [
interface
interface-type
interface-number
] |
blackhole
] [
vlan
vlan-id
] [
count
] ] [
|
{
begin
|
exclude
|
include
}
regular-expression
]
Views
Any view
Default command level
1: Monitor level
Parameters
blackhole
: Displays destination blackhole MAC address entries. These entries do not age, but you can
add or remove them. The packets whose destination MAC addresses match destination blackhole MAC
address entries are dropped.
vlan
vlan
-
id
: Specifies a VLAN in the range of 1 to 4094.
count
: Displays the number of MAC address entries that match all entry attributes you specify in the
command. When this keyword is used, the command displays only the number of specified MAC
address entries, rather than related information about these MAC address entries.
mac
-
address
: Specifies a MAC address in the format of H-H-H.
dynamic
: Displays dynamic MAC address entries, which can be aged.
static
: Displays static MAC address entries, which do not age.
interface
interface
-
type interface
-
number
: Specifies an interface by its type and number.
|
: Filters command output by specifying a regular expression. For more information about regular
expressions, see
Fundamentals Configuration Guide
.
begin
: Displays the first line that matches the specified regular expression and all lines that follow.
exclude
: Displays all lines that do not match the specified regular expression.
include
: Displays all lines that match the specified regular expression.
regular-expression
: Specifies a regular expression, a case-sensitive string of 1 to 256 characters.
Usage guidelines
If you execute this command without specifying any parameters, it displays all MAC address entries on
the device.