Jade Dungeon

计算机网络

作业通过QQ群: 367 347 982

Introduction

单位

数量单位:

\begin{equation} \begin{split} 1 K &= 10^3 \\ 1 M &= 10^6 \\ \end{split} \end{equation}

\begin{equation} \begin{split} 1 k &= 2^{10}\\ 1 m &= 2^{20}\\ \end{split} \end{equation}

时间单位:

\begin{equation} \begin{split} 1 ms &= 10^{-3} s \\ 1 us &= 10^{-3} s \\ 1 ns &= 10^{-9} s \end{split} \end{equation}

网络参考模型

ISO/OSI参考模型 TCP/IP参考模型
应用层 应用层
表示层  
会话层  
传输层 传输层
网络层  
数据链层  
物理层 Host to Host

数据包

数据包(Packet)在不同抽象层次的叫法:

Application Data Message  
Transport Segment
Network Datagram
DataLink Frame

网络分层

Chap 2 Application Layer

应用结构:p2p,客户端-服务器结构

socket连接 应用层 和 传输层。

应用层定义:消息类型、消息的格式、字段中值的格式、请求与响应的处理方式

传输层为应用提供:数据的可靠性、时效性、throughput、安全性

TCP安全

增加TCP一个子层,这个子层是SSL(Secure Socket Layer)

DNS(Domain Name System)

DNS组成:

  • 分层的DNS Server实现分布式数据库。
  • 查询协议。服务器上一般53端口运行BIND(Berkeley Internet Name Domain)

对于www.someschool.edu/index.html解析地过程:

  1. 用户主机上有DNS Client。
  2. 从URL中取出主机www.someschool.edu交给DNS Client。
  3. DNS Client发请求给DNS Server
  4. DNS Server发回响应,里面包含IP地址。
  5. DNS Client把IP地址交给应用程序(如浏览器)

DNS层次结构:

  • 根DNS服务器
  • 顶级域(TLD)服务器
  • 权威DNS服务器

Chap 3 Transport Layer

应用程序 应用层协议 传输层协议
email SMTP TCP
远程登录 TELNET TCP
web HTTP TCP
文件传输 FTP TCP
远程文件服务器 NFS UDP
流媒体 专用协议 UDP or TCP
VOIP 专用协议 UDP or TCP
网络管理 SNMP UDP
路由选择 RIP UDP
NDS DNS UDP

UDP

UDP提供轻量级的传输层协议。不提供最小的其他服务外的其他服务:

  • 无连接:发送进程与接收进程之间没有握手过程。
  • 不可靠:只管发出的报文而不管接收进程是否收到,也不算接收顺序是否正确。
  • 无拥塞控制:发送端不控制向下层(网络层)写入数据的速度。

优点:

  • 更好地控制消息的收发时间:没有TCP的拥塞控制、确认等工作。
  • 无需建立连接:TCP要三次握手。
  • 无状态连接:TCP要维护连接状态,如:收发缓存、拥塞控制参数,序号等。
  • 分组头部开销小:UDP只要8字节头部,TCP要20字节。

段结构:

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
源端口号 目的端口号
长度 检验和
应用数据(报文)

可靠数据传输

rdt 3.0

rdt 3.0(Reliable data transfer,可靠数据传输3.0)

要点:

  • 校验和
  • 序号
  • 定时器
  • 肯定确认
  • 否定确认

流水线(pipelined)可靠数据传输协议

Delay = Transmission Delay + Propgation Dealy + Queueing Time

两台主机分别在美国东西海岸:

  • 光速往返一个来回的RTT(时间延迟)为\(30ms\)。
  • 网络速度为R。\(R = 1 Gbps = 10^9 bps\)。
  • 数据长度为\(L\)。\(L = 1000 byte = 8000 bit\)

这样发到对方的传输时间是:

\[ D_{trans} = \frac{L}{R} = \frac{8000 bits}{10^9 bits/sec} = 0.008 ms \]

RTT: Round Trip Time。发出数据包,然后再传回来一个来回的时间是30ms所以要加上:

\[ RTT + L/R = 0.008 ms + 30 ms = 30.008 ms \]

网络利用率:从带宽来说只要\(0.008 ms\),但加上光速在两端来回的时间就成了 \(30.008 ms\),算下来网络利用率:

\[ U_{sender} = \frac{L/R}{RTT+L/R} = \frac{0.008}{30.008} = 0.00027 \]

流水线(pipelining)

为了提高网络的利用率,不是发一个包等回应,而是一次发很多个,等多个 回应。如果一次发三个:

\[ U_{sender} = \frac{L/R}{RTT+L/R} = \frac{0.024}{30.008} = 0.00081 \]

在有发了多个包的情况下,处理多个回应的方式有:

  • Go-BAck-N
  • Selective repeat

GBN(Go-back-N)

发了1-6一共6个包,收到了1,2,3,6。1到3是连续的,那就丢弃不连续的。从4开始没有 连续收到的要重发。

累积确认(Cumulative acknoledgment):接收方只发连续收到的包的ACK确认。因为只有 1,2,3是连续的,所以只回ACK 3。

同样因为使用了累积确认,如果ACK 1,或是ACK 2没有被送到服务器也不用担心服务器 重传包1,2,3。因为只要ACK 3到了服务器,服务器就可以确认1,2,3是连续被客户端收到了 。

所以对发送方来说,收到一个回应就可以把窗口向后移,继续发。

  • 收到了ack1,就接着发pkg7
  • 收到了ack2,就接着发pkg8

因为接收方没有收到4,超过时间没有收到ack4。所以会从4开始重新发所有的数据。 包括pkg7和pkg8。

sample

  • 优点:接收方缓存简单。不用缓存顺序不对的分组的数据,因为发送方会再传。
  • 缺点:是如果窗口长度和带宽时延都很大时会有很多重复发的数据。

SR(Selective Repeat,选择回传)

只重发没有收到的包。对第个包加上计时器,对于超时还没有收到ACK的包,重传。 接收方对于重复收到的包要发加确认,不然发送方的窗口不能向前滑动。

sample

TCP协议

特点:

  • 面向连接(connection-oriented)
  • 全双工服务(full-duplex service)
  • 点对点(point-to-point),不能广播

注意区分:

  • MSS(maximum segment size,最大报文段长度):报文段里最大应用层数据的长度。
  • MTU(Maximum transmission unti,最大传输单元)

报文结构

0 1 2 3 4 5 6 7 8 9 10 11 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
源端口号 目的端口号
序号
确认号
首部长度 保留 URG ACK PSH RST SYN FIN 接收窗口
互联网检验和 紧急数据指针
选项
数据

序号(Sequence Number)

包的序列号,如果MMS大小是1460,那序列就是MSS包的开头:

  • 第一个包开头是0,那seq num就是0
  • 第二个包开头就是1460
  • 第三个包开头就是2920

确认号(Acknowledgment number)

seq num 加1,表示接收方下一个想收到的包号。

接收窗口(Received Window)

流量控制,表示接收方愿意接收多少字节。收到速度太快,上层应用程序处理不了,所以 让发送方发慢一点。

往返时延(RTT)的估计与超时

以前每次RTT的不同,差别很大。

\[ EstimatedRTT = (1 - \alpha) \times EstimatedRTT + \alpha \times SimpleRTT \]

一般用\(\alpha = 0.125\),所以:

\[ EstimatedRTT = 0.875 \times EstimatedRTT + 0.125 \times SimpleRTT \]

DevRTT:预计RTT和实现这次的RTT的偏差。

TCP 可靠传输

用管道方式一次发多个包,如果有没有收到的重传机制。

加倍超时间隔

这是一个简单的拥塞控制(congestion control)方法:如果有超时,就把下次的超时 间隔加倍。直到收到上层应用的数据或是ACK到达。

TCP快速重传(fast retransmit)

等超时的话太浪费时间了。 冗余确认技术(duplicate acknowledgments)可以在超时前 就确认已经丢包了。

发了从1到100个包,接收方的ACK返回永远是希望收到的。

比如收到了50和52,51没有收到,那么以后收到的包不是51,返回的ark永远是51。 表示希望收到51

对于发送方来说,timeout还没有到,就会收到多个(一般当收到重复3个ACK时)ack51, 那么说明接收方已经丢了51。所以在timeout时间还没有到的时候就已经可以知道要重发51 。所以叫快速重传

流量控制(flow control)

注意流量控制(Flow Control)不同于拥塞控制(Congestion Control)。

接收方ark包头部的rwnd(receive window)可以写上到上层应用的缓存有多少空的地方 ,让放送方不要发消息太快而用完了接收方的缓存,导致丢弃有用的数据。

\[ LastByteSent - LastByuteAcked \leq RcvWindow \]

网络的拥塞情况和接收方的可用缓存二者组合决定了发送方的发送窗口大小。

TCP连接管理

TCP状态机

TCP 三次握手

  1. client:SYN位为1,seq=client_isn
  2. server:SYN位为1,ACK位为1,seq=server_isn,ark=client_isn+1
  3. client:SYN位为0,ACK位为1,seq=client_isn+1,ack=Server_isn+1
  • SYN :特征:s = 1
  • SYN/ACK :特征:s=1 && A=1
  • ACK :特征:A = 1

TCP关闭连接

步骤:

  • 发方 FIN , 收方回ACK
  • 收方回FIN,发方回ACK

TCP拥塞控制(Congestion Control)

重传有两种情况:

  • time out
  • duplate ark 收到重复的ark包。

控制拥塞的变量:

  • cwnd:Congest Window(拥塞控制窗口),两端各有一个。
  • rwnd:流量控制里的窗口大小。

发送的窗口大小要小于cwnd和rwnd中较小的那一个:

\[ LastByteSent – LastByteAcked \leq min\{cwnd, rwnd\} \]

比如开始是5,如果收到一个ark表示发成功,那么窗口加1为6,如果发生了重传,那么把 窗口减半。如果再收到成功就把窗口加1。这样重复。

拥塞控制三个方法:

  • slow start()
  • congestion avoidence()
  • fast recovery(可选)

慢启动(Slow Start)

第一次cwnd的大小只有一个MSS,收到一个ACK确认大小就增加一个MSS。

由到第二次发的两个不是同时收到的,所以收到一个ack回应发两个,再收到一个ack再 发两个。所以第三次一共发了四个。

这样每过一个RTT,cwnd就加倍,下次发两个,再下次4个……指数增长。

避免拥塞(Congestion Avoidance)

加法式增加,乘法式减少(additive-increase, multiplicative-decrease)

如果有ACK到达表示成功,发送方把cwnd增加MSS/Cwnd:

当前窗口为3,所以发出去三个。以后每收到一个ack不会加一,而是加1/3,要收到三个 ack才会把窗口加1到4。

如果每发生一次丢包,就把cwnd减半,但最小不会小于1个MSS。

快速恢复(fast recovery)

如果有丢失,回到1重新开始。并把一个阈值(Threshold)设置为当前cwnd的一半。

一直到一个,以后是每次增加一个。比如当前窗口为3,所以发出去 三个。以后每收到一个ack不会加一,而是加1/3,要收到三个ack才会把窗口加1到4。

如果是TCP Reno版本,遇到丢失(收到3个冗余ACK)就减到原来的一半,然后每次加1。

sample

Chap 4 Network Layer

概述

路由和转发

R3.

What is the difference between forwarding and routing?

答: Forwarding is about moving a packet from a router’s input link to the appropriate output link. Routing is about determining the end‐to‐end routes between sources and destinations.

  • 转发(Forwarding):根据一定的规则将数据包从路由器的输入接口移动到合适的输出接口的过程。
  • 而路由(Routing):是在源主机与目的主机之间寻找供数据包(在网络层上)进行传输的端对端路径。

R12.

Do routers have IP addresses? If so, how many?

答:Yes. They have one address for each interface.

与连接到网络上的每台主机一样,路由器也是有 IP 地址的。通常情 况下,路由器的每个接口对应有一个 IP 地址。因而,有多少个接口, 就对应有多少个 IP 地址。不同接口所在子网属于不同网段。

网际协议(IP)

IP数据报格式

0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31
version header<br>length type of <br> service datagram length (bytes)
identifier Flags Fragmentation offset
time to live upper layer <br>protocol Header checksum
source ip
destination ip
Options (if any)
data
  • 版本号。ipv4还是ipv6
  • 头部长度:一般没有可选项就是20byte,
  • 服务类型:如FTP等
  • 数据报长度:
  • 寿命:TTL。路由跳了几跳。
  • 协议:16表示TCP,17表示UDP,等等

数据报分片

MTU:最大传输单元。以太网中为1500KB 到46KB(仅有头部)

IPv4

32 bit = 4 byte = 4 * 8 bit

子网记法:233.1.1.0/24。其中 /24 是子网掩码。

ICMP 互联网控制报文协议

主机与路由器交换网络层的信息。

组成: 「类型字段」 和 「编码字段」。

ping:

  1. 一方发一个类型8,编码0到对方
  2. 对方回一个类型0,编码0过来

ICMP报文还是源抑制报文,最初是作为拥塞控制。拥塞的路由器发一个ICCMP源抑制报文 给主机,强制该主机减小传输速率。

tracerute:发一个ICMP报文到目标机不可达的UDP端口。这样对方返回端口不可达ICMP 报文回应,就可以根据TTL值得到路由跳转,还有根据时间网络时延等信息。

IP安全

IPsec协议,在VPN(虚拟专用网)中广泛使用,与IPv6和IPv6向后兼容。提供加密与 数据完整性验证。

路由算法

主机通常与一台路由连接。这台就是默认路由(default router)也叫第一跳路由(first-hop router)。

  • 源路由器(source router):源主机的默认路由器。
  • 目的路由(destination router):目的主机的默认路由器。

分类

  • 全局还是局部。
  • 静态还是动态。
  • 敏感还是迟钝。

R21.

Compare and contrast link‐state and distance‐vector routing algorithms.

答:Link State Algorithm: Computes the least‐cost path between source and destination using complete, global knowledge about the network. Distance Vector Algorithm: The calculation of the least‐cost path is carried out in an iterative, distributed manner. A node only knows the neighbor to which it should forward a packet in order to reach given destination along the least‐cost path, and the cost of that path from itself to the destination.

LS(Link State)算法基于对整个网络的完整信息(包括网络拓扑、 链路及链路带宽等)来计算源端与目的端的最低成本路径。

一个链路改变要通知所有结点;收敛快;健壮性强,只计算自己的转发表;

而 DV (Distance Vector)算法则有所不同,其每个节点只掌握有限信息 (主要包括其到达所有相邻节点的成本以及每个相邻节点到达目的 端所需的最低成本),因而其只知道为达到沿着最低成本路径以最终 到达给定目的端需要将数据包转发给它的哪个相邻节点,但对整条最 低成本路径(即具体经过中间哪些节点并最终达到目的端)并不知晓。 其最低成本路径的计算有赖于相邻节点对其提供的路由信息,经过反 复的计算得到。

只有链路改变引起相邻节点最低费用改变时才传播链路费用;收敛慢,会遇到无穷计数问题 ;健壮性弱,一个节点的错误会传播到其他网络。

链路状态选路算法(Link-State,LS)

设目的节点为(v):

  • D(v):本次迭代中,从源到目的费用最低路径的费用。
  • p(v):从源到目的费用最低路径的前一节点(v的邻居)。
  • N':节点子集。如果已经知道最低费用路径,那v肯定在集合N'中。

每次迭代结束,选出D()最小的结点加入N'。再开始下一轮。

P26.

Consider the following network. With the indicated link costs, use Dijkstra’s shortest‐path algorithm to compute the shortest path from x to all network nodes. Show how the algorithm works by computing a table similar to Table 4.3.

sample

答:运行 LS 算法寻找从 x 出发到其他节点的最短路径的过程及结果 如表 1 所示

step N’ D(z),p(z) D(y),p(y) D(v),p(v) D(w),p(w) D(u),p(u) D(t),p(t)
0 x 8, x 6, x 3, x 6, x
1 xv 8, x 6, x   6, x 6, v 7, v
2 xvy 8, x     6, x 6, v 7, v
3 xvyw 8, x       6, v 7, v
4 xvywu 8, x         7, v
5 xvywut 8, x          
6 xvywutz            

因而,从 x 到网络其他所有节点的最短路径如下图所示:

sample

距离向量算法(Distance-Vector,DV)

分布式的,每个节点从一个多多个直接相连的邻居接收信息,再把计算结果发给邻居。 这个过程一直迭代,直到没有更多的信息要交换为止。

  • 从x到y的最短路径用\(d_x(y)\)表示。
  • \(min_v()\)表示取所有与x相连的节点。
\[ D_x(y) = min_v\{c(x,v) + d_v(y)\} \]

简单地说是遍历所有与x相邻的节点,找出它们之中与y最近的。如果它们不直接连y,那 让它们再找与它们直接相连的与y最近的。

层次路由

自治系统(Autonomous Syatem,AS)

R22.

Discuss how a hierarchical organization of the Internet has made it possible to scale to millions of users.

答:Routers are aggregated into autonomous systems (ASs). Within an AS, all routers run the same intra‐AS routing protocol. Special gateway routers in the various ASs run the inter‐autonomous system routing protocol that determines the routing paths among the ASs. The problem of scale is solved since an intra‐AS router need only know about routers within its AS and the gateway router(s) in its AS.

随着互联网的普及,网络规模日益扩大,因而给路由器的路由工作(为 实现正常路由功能,网络上的每个路由器需要存储其他所有路由器的 相关信息)带来了极大挑战。而分层路由思想(hierarchical routing) 的提出则可以很好地解决这个问题。

分层路由思想的解决思路为:将 路由器聚集起来划分为不同的自治系统,这样每个路由器就归属于某 一个自治系统(AS)。在一个自治系统内,所有的路由器都运行相同 的路由协议(intra‐AS routing protocol)。此外,每个自治系统都有一 个或多个位于自治系统边界的特殊路由器,称为网关路由器,其上运 行着自治系统间路由协议(inter‐AS routing protocol)用于确定自治系 统间的路由路径。由于每个自治系统内的路由器只需存储本自治系统 内的其他通用路由器及网关路由器的相关信息便可实现路由功能,因 而方便地解决了需要大规模存储路由信息的问题。

因特网路由

比较

R25.

Compare and contrast the advertisements used by RIP and OSPF.

答: With OSPF, a router periodically broadcasts routing information to all other routers in the AS, not just to its neighboring routers. This routing information sent by a router has one entry for each of the router’s neighbors; the entry gives the distance from the router to the neighbor. A RIP advertisement sent by a router contains information about all the networks in the AS, although this information is only sent to its neighboring routers.

首先明确一点,因 RIP 及 OSPF 均属于自治系统内路由协议(intra‐AS routing),故其信息交换(即 advertisement)只在自治系统内传送。

RIP 使用类 DV 算法,相邻路由器之间每隔 30 秒就相互交换距离向量 (DV)信息,其通过路由器发送 RIP advertisement 给自治系统内的相 邻路由器来实现,但该 RIP advertisement 包含整个自治系统网络的完 整信息。

若使用 OSPF(LS 协议,广播链路信息),则路由器周期性地 (或链路状态发生改变时)给自治系统内的所有路由器广播路由信息 (而不仅仅是相邻路由器),该路由信息提供了从该路由器到其所有 相邻路由器的距离向量。

路由信息协议(Routing Information Protocol, RIP)

属于DV协议。一条路径最大限制为15,即不能超过15跳。

30秒交换一次通告。如果超过180秒没有监听到领居,那就认为是不可达的。修改本地 路由表并通告其他仍然可达的路由器。

开放最短路径优先(Open Shortest path First, OSPF)

使用LS协议,有整个自治网络的完整拓扑图。广播给所有路由器。

区域边界路由器(area border router)、主干(backbone)、内部路由器()三层。

RTT

RTT: Round Trip Time。

RFC 3439

\[ \frac{RTT \times C}{\sqrt{N}} \]

Chap 5 Data Link Layer

应用在网卡与二层交换机。

碰撞检测通信。

  • 单工:每个端都只能收或发
  • 全双工:通信双方都可以同时收发内容。
  • 半双工:通信双方在同一时间只能收或发内容。

检测如果线路忙,就等。如果不忙,等随机时间,再发。

多路访问协议

随机接入协议

载波侦听多路访问(CSMA)

  • 说话之前先侦听
  • 如果与他人同时开始说话,停止说话。

CCSMA/CD

R6.

In CSMA/CD, after the fifth collision, what is the prob地bility that a node chooses K = 4? The result K = 4 corresponds to a delay of how many seconds on a 10 Mbps Ethernet?

答:因 CSMA/CD 采用二进制指数退避算法(the binary exponential backoff algorithm )。K=4说明已经碰撞了5次即n=5。取值是在\(0\)到\(2^5-1\)(即31)中取随机数。概率为\(1/32\) 故\(p\{K=4\}=1/32\)。

10Mbps网络的速度为512 bit/us,\(4 \times 512 \times 0.1 = 204.8us\)

对于 Ethernet,节点的等待时间为\(K 512 bit times\)(即传输 512 字节 到 Ethernet 所需的时间乘以 K)。对于 K=4 的情形,其在 10Mbps

链路层地址

MAC地址

R9.

How big is the MAC address space? The IPv4 address space? The IPv6 address space?

答:

  • \(2^{48}\) MAC addresses;
  • \(2^{32}\) IPv4 addresses;
  • \(2^{128}\) IPv6 addresses.

地址解析协议(Address Resolution Protocol,ARP)

DNS为因特网上所有的主机解析主机名,ARP只为同一子网上的IP解析MAC地址。

每个节点(主机和路由器)都有ARP表,格式:IP MAC TTL(过期时间)。表里没有发一个 ARP分组,使用广播的方式(MAC地址:FF-FF-FF-FF-FF-FF)

R10.

Suppose nodes A, B, and C each attach to the same broadcast LAN (through their adapters). If A sends thousands of IP datagrams to B with each encapsulating frame addressed to the MAC address of B, will C’s adapter process these frames? If so, will C’s adapter pass the IP datagrams in these frames to the network layer? How would your answers change if A sends frames with the MAC broadcast address?

答: C’s adapter will process the frames, but the adapter will not pass the datagrams up the protocol stack. If the LAN broadcast address is used, then C’s adapter will both process the frames and pass the datagrams up the protocol stack.

C 的适配器在接收到数据帧后会进行处理,当发现该帧的目的 MAC 地 址与自身 MAC 地址不同时(即确认该帧并不是要发给自己的)会立即 将该帧丢弃,所以 C 的适配器并不会将该帧向上层协议栈传送。

当使用广播地址时,C 的适配器不仅会接收、处理该数据帧,还会进一步向上层传递。

R11.

Why is an ARP query sent within a broadcast frame? Why is an ARP response sent within a frame with a specific destination MAC address?

答: An ARP query is sent in a broadcast frame because the querying host does not know which adapter address corresponds to the IP address in question. For the response, the sending node knows the adapter address to which the response should be sent, so there is no need to send a broadcast frame (which would have to be processed by all the other nodes on the LAN).

在广播帧中进行ARP查询,是因为查询主机不知道哪个适配器的地址对应于要查询的IP地址。

而 ARP 响应时,发送节点知道要给哪个适配器发送响应,所以不必发送广播帧。

R12.

For the network in Figure 5.19, the router has two ARP modules, each with its own ARP table. Is it possible that the same MAC address appears in both tables?

sample

答:No, it is not possible. Each LAN has its own distinct set of adapters attached to it, with each adapter having a unique MAC address.

不可能。路由器使用两个端口连接两个局域网,每个局域网有自适配器集合,而每个 适配器端口的 MAC 地址是唯一的。

P14.

Consider three LANs interconnected by two routers, as shown in Figure 5.33.

sample

a. Assign IP addresses to all of the interfaces. For Subnet 1 use addresses of the form 192.168.1.xxx; for Subnet 2 uses addresses of the form 192.168.2.xxx; and for Subnet 3 use addresses of the form 192.168.3.xxx.

b. Assign MAC addresses to all of the adapters.

sample

c. Consider sending an IP datagram from Host E to Host B. Suppose all of the ARP tables are up to date. Enumerate all the steps, as done for the single‐router example in Section 5.4.1.

从E发到B

  1. 目标IP为192.168.1.3,不在当前网段192.168.3。送到网关192.168.3.1,已知其MAC为 11:11:11:11:11:19。
  2. Router 2收到包,读取其目标IP为:192.168.1.3,不在它的网段192.168.3和192.168.2 中。所以送到默认网关192.168.2.1中,已知其MAC为:11:11:11:11:11:15
  3. Router 1收到包,读取其目标IP为:192.168.1.3,在它的网段192.168.3中,所以送到 目标机,已知其MAC为:11:11:11:11:11:13。成功送达。

d. Repeat (c), now assuming that the ARP table in the sending host is empty (and the other tables are up to date).

E要送到网关192.168.3.1,但是不知道MAC地址,所以要发ARP广播。目标机响应E,告之 其MAC地址为11:11:11:11:11:19。

TCP三次握手