Command Reference

Cisco "show mac address-table" Command Explained

show mac address-table — displays which MAC addresses the switch has learned on which ports — the map it uses to forward frames. Runs in privileged EXEC mode.

Syntax and common variants

VariantPurpose
show mac address-tableAll learned MACs
show mac address-table interface gi0/5What's learned on one port
show mac address-table vlan 10Per-VLAN view
show mac address-table address aaaa.bbbb.ccccFind one device

Reading the output

Output fieldMeaning
VlanVLAN the MAC was learned in
Mac AddressThe device's hardware address
TypeDYNAMIC (learned) or STATIC (configured)
PortsWhere frames to this MAC are sent

When to use it

The physical-locator: given a MAC (from ARP on the router), this tells you the exact switch port a device hangs off — follow it switch-to-switch to trace any host. Also the tool that exposes loops: one MAC flapping between two ports. Browse more in the command reference or practise in the free labs.

Frequently asked questions

How do I find which port a device is on?

Get its MAC (from the device or the router's ARP table), then show mac address-table address — the Ports column is your answer.

Why does one MAC keep moving between ports?

MAC flapping — usually a Layer 2 loop, or two links to the same host without aggregation. Investigate STP immediately.

How long do dynamic entries last?

300 seconds of inactivity by default, then they age out and get re-learned.

VS
Vipul Sir — Lead Instructor, Attila Technologies20+ years in Cisco networking. Teaching CCNA, CCNP, CCIE & CyberOps in Ahmedabad since 2004.

Want hands-on training?

Learn this on real Cisco lab devices with placement support at Attila Technologies, Ahmedabad.

Start your networking career with Attila Technologies

Hands-on Cisco training, real lab devices and placement support in Ahmedabad.