免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
楼主: C.J
打印 上一主题 下一主题

TCP的许多不解 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2009-10-25 23:01 |显示全部楼层 |倒序浏览
实在是比较基础的问题,可还是不太明白,哪位明白人给说说吧 \r\n\r\n1. TCP的端口与UDP的端口有啥区别?\r\n以前一直以为是一样用途,用来标注服务。今天看书,UDP的端口可以这样理解,TCP的端口却是标注连接,对此不解!\r\n\r\n2. TCP的滑动窗口,假设窗口大小为3,发送方A,可以连续发送3个报文,但如果收到了ACK2和ACK3,但没收到ACK1,会怎么办?\r\n   a) 只重发第一个报文;\r\n   b) 全部重发;\r\n   c) 都不重发,收到ACK2代表第一个报文接收方也收到了(认为接收方按只按顺序接收,不按顺序的报文丢弃);\r\n   d) 其他是什么??

论坛徽章:
0
2 [报告]
发表于 2009-10-26 17:12 |显示全部楼层
RFC TCP\r\n\r\nReliability:\r\n    The TCP must recover from data that is damaged, lost, duplicated, or\r\n    delivered out of order by the internet communication system.  This\r\n    is achieved by assigning a sequence number to each octet\r\n    transmitted, and requiring a positive acknowledgment (ACK) from the\r\n    receiving TCP.  If the ACK is not received within a timeout\r\n    interval, the data is retransmitted.  At the receiver, the sequence\r\n    numbers are used to correctly order segments that may be received\r\n    out of order and to eliminate duplicates.  Damage is handled by\r\n    adding a checksum to each segment transmitted, checking it at the\r\n    receiver, and discarding damaged segments.\r\n\r\n是否有问题?
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP