I understand that for a switch to learn a MAC address, if host A wanted to send data to Host B the switch learns host A MAC and places it in the MAC table. If it doesn't know where the MAC (for Host B) is then it will flood the ports. Host B then creates a frame and sends it to Host, allowing the switch to learn the MAC of Host B.

My understanding of ARP is that if Host A wants to send data to Host D (separate network) then Host A will need to learn the default gateway MAC, so Host A sends a ARP request for the gateway, the switch then receive the frame, the switch learn the MAC of Host A, etc.

The problem I seem to have is that I seem to be getting confused between MAC table and ARP. Is ARP always used? In the first example there was no mention of ARP, so I've gotten confused between the terms and when they are used.

1 Answer 1


A MAC address table is used by a layer-2 switch to relate the layer-2 address to the switch interface. A layer-2 switch does not know or care what layer-3 protocol is used inside the layer-2 frames.

ARP is used by a layer-3 device (host, router, etc.) to relate a layer-3 (IPv4) address to a layer-2 (MAC) address.

Traffic on a layer-2 LAN is delivered by the layer-2 address directly from host to host. When a host has the layer-3 (IPv4) destination address, it must relate that to the layer-2 (MAC) address in order to build a layer-2 frame for the layer-3 packet. The layer-3 device will use ARP (Address Resolution Protocol) to do the layer-3 to layer-2 resolution. ARP will check its local table for an entry with the layer-3 address (the entries probably time out). If it finds no entry, it will broadcast an ARP request to identify the owner of the layer-3 address, which replies with its layer-2 address.

ARP uses broadcast, and IPv6 has eliminated broadcast, so it has a different protocol called NDP (Neighbor Discovery Protocol) that performs the same function (among other functions) for IPv6 as ARP does for IPv4.

  • Comments are not for extended discussion; this conversation has been moved to chat.
    – Ron Maupin
    Feb 18, 2019 at 17:20

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.