What is the difference between a physical address and a MAC address on a network?

I read somewhere that both the physical address and the MAC address are the same, which exactly matches the network interface of the machine. And also I read elsewhere that a router forwards data packets based on information such as physical and logical addresses available from the data packet. I know the MAC address never goes outside the LAN gateway. Then, how do other routers gather my MAC address information from the data packet I send?

Should I assume that the physical address is different from the MAC address when logging into the network?

+3


source to share


3 answers


The physical address and MAC address are indeed the same. They are used for communication between devices on Ethernet networks. When you send a request to the IP address of a remote host (for example, to access a website), your computer sends this request to your local network gateway (your router), and it uses its physical (MAC) address as the message destination. but the logical (IP) host for the final destination. The router then forwards this message and knows who to return the response to.



+3


source


Physical and MAC addresses are the same, only different naming conventions. Each device must have a unique MAC address assigned by its vendor. Logical addressing is the IP address assigned to the interfaces.

Physical addressing / MAC addresses work at layer 2, and logical addressing works at layer 3. Let me use an example for demonstration.

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 the source IP of PC_A and the destination IP of PC_B. This IP packet will be encapsulated in an Ethernet frame with the source MAC address PC_A and the destination MAC address R1.

PC_A sends the frame to R1 and R1 decapsulates the frame. R1 checks the destination IP address and matches it against the routing table and sees that R2 is the path. Thus, R1 creates a new frame with R1's source MAC address and R2's destination MAC address. R2 does the same and eventually sends the frame to PC_B.

During this entire process, the frame changes while the IP packet remains intact.

+2


source


The physical address and MAC address are indeed the same. They are used for communication between devices on Ethernet networks. When you send a request to the IP address of a remote host (for example, to access a website), your computer sends this request to your LAN gateway (your router) and it uses its physical (MAC address) as the message destination but the logical (IP) hostname for the final destination. The router then forwards this message and knows who to return the response to.

-1


source







All Articles