Before we dive into VLANs, routers, IP addresses and all that stuff, we have to understand how a network works, and which language a switch speaks.
A MAC address (Media Access Control address) is a hardware address tied to that specific network interface card and it’s unique. Windows calls it physical address but it’s the same thing.
A MAC address is not just a random number. The first six hexadecimal characters identifies the vendor (like Intel or Ubiqui and so on). The last six hexadecimal characters is unique to that specific device from that vendor.
And here comes our OSI model back in play. Because a switch is speaking with MAC addresses and does not care about ip addresses in the first place, we live at layer 2. Even the naming here is a bit confusing physical layer (layer 1) is NOT the physical address. On layer 1 we are talking about the actual movement of bits. Electricity on copper cable. Light on fiber, etc.
When your computer sends data that moves down the OSI model this is called encapsulation. Basically meaning each layer adds its own information. At the time the data reaches layer 2 the device adds a destination MAC address and a source MAC address to it. The source MAC address is the sender’s local hardware address. The destination MAC is usually the next device in the local network, often the default gateway. Then layer 2 adds one more thing at the end, the FCS (frame check sequence). It’s a mathematical value used so the receiving device can verify the rfame wasn’t corrupted during transmission.
So the big takeways from this lesson are:
- A MAC address is the local hardware identity of a network interface.
- The first half is the vendor OUI, and the second half is unique to the device.
- Switches live at Layer 2 and forward traffic based on MAC addresses.
- A frame is the Layer 2 wrapper around data, including source MAC, destination MAC, and FCS.