概述
UDP,相比较之下,就非常简单了。Sending self-contained message。
- UDP与IP干的活非常类似,the unique feature is that it allows the layer to send
data to a specific appliacation. That’s also why it is called, the
User Demultiplexing Protocal
1. - 它自己(UDP peer层内)无法实现missing data
re-transmission,但可以通过上层的application判断实现。
DNS (Domain name) service用的就是UDP. It follows a simple request-response
mechanism.
ICMP
用于网络问题检测。
发生网络故障后,icmp的datagram将包含以上内容。最右侧的,即最外层的,仍旧是一个IP datagram,包含的header指定source为router,destination为host A。
ping, traceroute等application使用ICMP。calls ICMP directly.
Traceroute application 1) finds the routers passed along the path as well as 2) the Round-trip time to each of the routers.
End-to-End Principle
The end-to-end principle gives the
end host
theresponsibility
for reliable communications.
一个典型的MIT的例子:如果我把error detection布置在link中,保证每次transmission
都不出错,岂不是代表永远都不会出错? 但没想到,在经过中间的主机转发时,从接收到packet到存储到memory的过程中,D发生了错误。而因为error detection只发生在D to E之间的transmission上,E并没有发现传输的过程出了任何问题。因此,这个致命的错误被漏掉了。
此外,一个封闭的、功能再怎么齐全的系统,也经不住外界日积月累的爆炸性的需求增长(Refer this to Strong end-to-end principle。For simplicity and flexibility ). 人们发现,系统的设计原则之一就是“端对端”原则,也只有end-to-end,就像截图上说的,the only way to check.
Client在send file的时候,include some error detection information. When the receiver resembles the file, it performs an error check.
The network can help, but cannot be responsible for correctness
e.g. WiFi Ethernet (wireless link layer)因为传输成功率不高, 可以通过link layer acknowledgement 来判断data packet是否传输成功,如果没收到则会多次发送(retransmission)。虽然TCP保证了传输的可靠性,但link layer上的帮助显然提高了TCP的性能和效率。
On the other hand, the Strong end-to-end principle suggests, that any further function on link layer will cause impediment to innovation and progress. There are other protocols which do not rely on reliability but rather low latency (延迟) such as UDP.
As layers start to add optimizations assuming what the layers above and below them do, it becomes harder and harder to re-design the layers.
比IP多的功能是它指定了which application to send to,相当于给user了多路化处理能力。 ↩︎
最后
以上就是清脆棒棒糖为你收集整理的Unit 2, UDP & ICMP & End-to-End Principle的全部内容,希望文章能够帮你解决Unit 2, UDP & ICMP & End-to-End Principle所遇到的程序开发问题。
如果觉得靠谱客网站的内容还不错,欢迎将靠谱客网站推荐给程序员好友。
发表评论 取消回复