What is MAC address and CAM table?
What is Mac address and why switch requires Mac address? A switch makes its forwarding decision for frame based on the destination Mac address. And the Mac address is 48 bit (6 bytes) address. We have a grouping of 3 bytes in beginning and 3 bytes in the end.The Organizational Unique Identifier (OUI) or Vendor code is always pick up first 3 bytes or 24 bits of MAC address. So if you would begin a business that manufactures network interface card (NIC) and you would put a Mac address embedded in each of these network interface cards. You would need a vendor code that would assign to just your company. And once you had that you could start all of your Mac addresses with those 3 bytes. The next 3 bytes would be numbers that you came up with and the grand total we now have 48 bits Mac address.
Again the first half of the Mac address that is assigned to the vendor. And that vendor they begin their Mac addresses with that Mac code. They make up the last 24 bits and make sure that they are unique among all of the network interface card they create. By the way, it’s common that vendor has more than one vendor code. Sometimes companies are merged or large enough that they need more than one vendor code. It’s not a problem at all company have more than one vendor code.
Mac address Format:
However, if you want to know which vendor code is assigned to which company you may search on the internet. Search Mac address vendor code and you will get a comprehensive list of vendor codes and you will know which Mac address corresponds to which company.This is the simplest answer to the Question What is mac address and what is its format? The way we write out these 48 bits is using hexadecimal notation because in ‘1’ and ‘0’ it becomes difficult to read. So the hexadecimal notation is used to represent the Mac address. There are different ways to write Mac address.
Mac address example:
Now you know the format of Mac address and you also have an answer to What is Mac address? Different ways to represent this 48 bit Mac address.
A switch is going to use Content Addressable Memory (CAM) table to make its forwarding decision. This table is often referred as Mac address table. How cam table populated? There are two clients connected with a switch which is shown in the diagram. Port 1 connected to PC1 and port 2 connected to PC2. In below picture, you can easily see the MAC addresses of the PCs. Now we begin with cam table empty. We may have more than one Mac address on a single switch port. It is possible when the port is connected to the other switch and that switch has multiple Mac address. To keep this example simple we only have one Mac address on each port. The way we start populating the cam table is when we receive traffic.
Let’s say that PC1 sends out a frame into the network. Maybe it’s doing address resolution protocol request and when that frame goes into the switch. The switch integrates that frame and it looks at the source Mac address in that frame. And it says based on this frame that I just received from port number 1. I have reason to believe that this Mac address lives on a port 1 and the same thing for PC2. As the result our cam table populated. Once we have a populated cam table the switch can now make an intelligent forwarding decision. When a frame comes in and it is destined to the destination Mac address 58:55:CA:FA:15:51. The switch says that Mac address lives on port number 1 and it forwards this frame out of port number 1.
- Mac address a 48 bit addressed burned into a Network Interface Card (NIC).
- Media Access Address (Mac) written using Hexadecimal Notation.
- There are different ways to represent this 48 bit Mac address.
- A switch is going to use Content Addressable Memory (CAM) table to make its forwarding decision.
- The CAM table is used in multilayer switching for the purpose of quickly switching frames to their destination.
- It is used to record a stations Mac address and it’s corresponding switch port location.