我是计算机网络的新手,不清楚以下问题。
为什么我们需要 Mac 地址来进行实际数据传输。为什么不能通过IP地址的逻辑地址传输数据包?
IP 从未打算直接封装到电线上。你必须有一个较低层的有线协议。有许多协议用于将数据包封装在电线上,例如 Packet over SONET (POS)、以太网、T1 等......
这些低层协议称为RFC 791 的“本地网络协议”第 2.1 节:互联网协议
2.1. Relation to Other Protocols
The following diagram illustrates the place of the internet protocol
in the protocol hierarchy:
+------+ +-----+ +-----+ +-----+
|Telnet| | FTP | | TFTP| ... | ... |
+------+ +-----+ +-----+ +-----+
| | | |
+-----+ +-----+ +-----+
| TCP | | UDP | ... | ... |
+-----+ +-----+ +-----+
| | |
+--------------------------+----+
| Internet Protocol & ICMP |
+--------------------------+----+
|
+---------------------------+
| Local Network Protocol | <--- Ethernet
+---------------------------+
Protocol Relationships
Figure 1.
Internet protocol interfaces on one side to the higher level
host-to-host protocols and on the other side to the local network
protocol.
An Ethernet NIC has its own address (i.e. the mac address), which allows it to discern whether the frame is intended for that specific NIC. IP has a partner protocol called ARP protocol, which allows you to map between IP addresses and the appropriate ethernet address.