R3721-F3210-F3171-HP High-End Firewalls Network Management Command Reference-6PW101

68
Description
Use mac-address to add or modify a MAC address entry.
Use undo mac-address to remove one or all MAC address entries.
A static or blackhole MAC address entry will not be overwritten by a dynamic MAC address entry. A
dynamic MAC address entry can be overwritten by a static or blackhole MAC address entry.
If you execute the undo mac-address command without specifying any parameters, this command
deletes all unicast MAC address entries and static multicast MAC address entries.
You can delete all the MAC address entries (including unicast MAC address entries and static multicast
MAC address entries) of a VLAN, or you can choose to delete a specific type (dynamic, static, or
blackhole) of MAC address entries only. You can single out certain ports and delete the corresponding
unicast MAC address entries, but not the corresponding static multicast MAC address entries.
The MAC address entries configuration cannot survive a reboot unless you save it. The dynamic MAC
address table entries, however, are lost at next reboot whether or not you save the configuration.
Related commands: display mac-address.
Examples
# Add a static entry for MAC address 000f-e201-0101. All frames destined to this MAC address are sent
out port GigabitEthernet 0/1 which belongs to VLAN 2.
<Sysname> system-view
[Sysname] mac-address static 000f-e201-0101 interface gigabitethernet 0/1 vlan 2
mac-address timer
Syntax
mac-address timer { aging seconds | no-aging }
undo mac-address timer aging
View
System view
Default level
2: System level
Parameters
aging seconds: Sets an aging timer for dynamic MAC address entries, ranging from 10 to 630 seconds.
no-aging: Sets dynamic MAC address entries not to age.
Description
Use mac-address timer to configure the aging timer for dynamic MAC address entries.
Use undo mac-address timer to restore the default.
By default, the aging timer for dynamic MAC address entries is 300 seconds.
Follow these guidelines to set the aging timer appropriately:
A long aging interval may cause the MAC address table to retain outdated entries and fail to
accommodate the latest network changes.
A short aging interval may result in removal of valid entries and unnecessary broadcasts that might
affect device performance.