What is the difference between a physical address and MAC address in networking?

43.4k Views Asked by At

Somewhere I have read that both physical address and MAC address are the same,which is exactly the same attached with the NIC of a machine. And also in some other place I have read that a router is forwarding data packets based on the information such as Physical and Logical addresses available from a data packet. I have the knowledge that a MAC address will never go beyond the LAN's gateway. Then how come the other routers collect the information regarding my MAC address from a data packet send by me?

Am I supposed to believe that physical address is different from MAC address when comes into networking?

3

There are 3 best solutions below

3
On BEST ANSWER

Physical address and MAC address are indeed the same. They are used to communicate between devices on Ethernet networks. When you send a request to a remote host's IP address (access a website for instance) your computer sends that request to your LAN's gateway (your router) and it uses its physical (MAC) address as the destination of the message but the logical (IP) address of the host for its final destination. The router then forwards that message onward and knows who to return the reply to.

2
On

Physical and MAC addresses are the same, just different naming conventions. Each device should have a unique MAC address assigned by its vendor. The logical addressing is the IP address assigned to interfaces.

Physical addressing/MAC addresses work on Layer 2 and Logical addressing works on Layer 3. Let's use an example to demonstrate.

PC_A  -  R1  -  R2  -  PC_B

Let's say PC_A wants to send something to PC_B. PC_A will create an IP packet with Source IP of PC_A and Destination IP of PC_B. That IP packet will be encapsulated in an Ethernet frame with Source MAC of PC_A and Destination MAC of R1.

PC_A sends the frame to R1 and R1 deencapsulates the frame. R1 checks the destination IP and matches it to its routing table and sees that R2 is the way to go. So R1 creates a new frame with Source MAC of R1 and Destination MAC of R2. R2 performs the same steps and eventually sends the frame to PC_B.

During this entire proces the Frame changes, whilst the IP packet remains untouched.

0
On

You might have confused with Hw add and physical address. Basically, if you consider a router/switch with multiple ports. The device will have a Hw address then each of the interfaces will have a physical address. look at the output below. You generally see this in the devices supports L3 switching.

rtr1#sh int xe3/1
Interface xe3/1
  Scope: both
  Flexport: Breakout Control Port (Active): Break Out disabled
  Hardware is ETH  Current HW addr: ecf4.bb64.9aa0
  Physical:ecf4.bb64.9aa6  Logical:(not set)

The application to having different address is out of scope here.