Broadcast, Unicast, and Multicast
Initially, a switch will not know which port is connected to which MAC
address. It learns from the Ethernet frames it receives.
It takes note of the source MAC and the source port of each Ethernet frame in
the so-called forwarding table or forwarding information base (FIB).
If the destination MAC of an Ethernet frame is not known, the switch will
broadcast the frame to all ports.
Once it has learned which port reaches a MAC address, it will send frames
addressed to this MAC directly to the target port. This is called unicast.
Beside unicast and broadcast, there is also multicast, which means an
Ethernet frame is sent to multiple MACs at the same time.