目录
正在加载目录…
正在阅读专栏 分布式共识系统专栏 第 54 篇 · 共 59 篇 · 92%

论文:The Design Philosophy of the DARPA Internet Protocols

发布于 2026-09-21 10:09 · 最后编辑于 2026-09-21 18:15 · 版本 v2 · 字数 29,983 · 预计阅读 60 分钟 👁 18 次阅读

本篇整理 David D. Clark 的《The Design Philosophy of the DARPA Internet Protocols》。正文按 1988 年 SIGCOMM 版本逐页翻译;每一页保留原始 PDF 页面图,原文的章节编号、编号列表、脚注和 References 均按原位置保留。datagram、fate-sharing、gateway、realization、soft state、TCP/IP 等术语按网络领域惯例保留 English 或中英并列。

论文:The Design Philosophy of the DARPA Internet Protocols

相关文章:论文:A Protocol for Packet Network Intercommunication · 论文:Congestion Avoidance and Control · 论文:End-to-End Arguments in System Design

TL;DR

  • 核心问题:为什么 DARPA Internet 选择 datagram、IP/TCP 分层、gateway 和 endpoint-based reliability?论文试图从早期设计目标解释这些选择,而不只是描述协议“怎么工作”。
  • 最高层目标:有效地复用和互联已经存在、且彼此异构的 packet-switched networks。
  • 目标优先级:survivability、multiple types of service、variety of networks、distributed management、cost effectiveness、low-effort host attachment、accountability;这些目标有明确优先级,不是平级愿望清单。
  • 关键机制:用 fate-sharing 把连接状态放在 endpoint;让中间 gateway 成为尽量 stateless 的 datagram switch;在 datagram 之上用 TCP、UDP 或其他 transport 构造不同 service。
  • 重要边界:datagram 是 service building block,不是说所有应用都需要“不可靠 datagram”;architecture 允许多种 realization,实际性能仍取决于 host、gateway 和底层 network 的工程实现。
  • 历史展望:论文最后提出 flow 与 soft state,试图在 survivability、flexibility、resource management 和 accountability 之间取得更好的平衡。

名词解释

名词含义本文对应物
datagram无连接、独立转发的 packetInternet layer 的基本 building block
gateway连接不同 network 的 Internet packet switch执行 store-and-forward packet forwarding
fate-sharing状态与使用该状态的实体共享生死transport synchronization state 放在 endpoint host
survivability部分 network 或 gateway 失效后仍能继续提供通信Internet architecture 的最高优先级目标
realization一组实际连接起来的 networks、gateways 和 hosts某个具体 Internet 部署,而非抽象 architecture
virtual circuit具有连接语义的 network/transport service与 datagram building block 对比的固定 service
flow从 source 到 destination 的 packet sequence论文结尾提出的、可能替代 datagram 的 building block
soft stategateway 中可丢失、可由 endpoint 周期性恢复的状态flow state 不再是维持 service 的永久关键状态
accountability对 packet flow 和资源使用进行核算早期 Internet 中优先级最低、工具较少的目标

目录

章节内容
版本与来源SIGCOMM ’88 版本、作者和固定 PDF
原文页面与逐页翻译10 个 PDF 页面按原页保留并翻译
架构原则索引目标、机制与后续影响
设计判断与边界fate-sharing、datagram、layering 和 realization
本篇验收页数、图片和内容覆盖

版本与来源

  • 论文标题:The Design Philosophy of the DARPA Internet Protocols。
  • 作者:David D. Clark,Massachusetts Institute of Technology,Laboratory for Computer Science。
  • 版本:最初发表于 Proceedings of SIGCOMM ’88,Computer Communication Review Vol. 18, No. 4,August 1988,pp. 106–114。
  • 本地固定来源:Princeton COS 461 PDF mirror。ACM 书目信息见 SIGCOMM ’88 record,页面信息为 106–114。
  • 本地固定文件:source/the-design-philosophy-of-the-darpa-internet-protocols.pdf。
  • PDF 固定信息:10 页;SHA-256:0cf87f91a34e30497bc9fe4b908d52164bafbd8e1dc845d7810ac22b8ce36c8c。
  • 附件处理:每页按 PDF 页面矩形以 2× 渲染为 1224×1584 PNG,存放于 assets/53 The Design Philosophy of the DARPA Internet Protocols/,正文按 600 宽度嵌入。
  • 笔记类型:深度分析;理由是本文同时解释 Internet architecture 的历史目标、故障模型、transport layering、datagram、host/gateway 分工和后续 flow/soft-state 方向。

原文页面与逐页翻译

第 1 页:摘要、Introduction 与 Fundamental Goal 的开头

the design philosophy p01

The Design Philosophy of the DARPA Internet Protocols

作者:David D. Clark,Massachusetts Institute of Technology,Laboratory for Computer Science,Cambridge, MA 02139。

原始出版信息:最初发表于 Proc. SIGCOMM ’88, Computer Communication Review Vol. 18, No. 4, August 1988, pp. 106–114。

本工作部分由 Defense Advanced Research Projects Agency(DARPA)合同 N00014-83-K-0125 资助。

Abstract

Internet protocol suite,即 TCP/IP,最初提出于十五年前。它由 Defense Advanced Research Projects Agency(DARPA)开发,如今已广泛用于军事和商业系统。

虽然已经有许多论文和规范描述这些 protocols 是如何工作的,但人们有时很难从中推断:为什么 protocol 会被设计成现在这个样子。例如,Internet protocol 建立在 connectionless 或 datagram service 之上,而人们对这一选择背后的动机存在严重误解。

本文试图记录早期塑造 Internet protocols 的一些 reasoning。

1. Introduction

在过去 15 年中,美国国防部的 Advanced Research Projects Agency 一直在开发一套用于 packet-switched networking 的 protocols。这些 protocols 包括 Internet Protocol(IP)和 Transmission Control Protocol(TCP),如今已经成为美国国防部的 internetworking standards,并且在 commercial networking environment 中得到广泛使用。

这项工作中形成的 ideas 也影响了其他 protocol suites,最重要的例子是 ISO protocols 的 connectionless configuration。

虽然关于 DOD protocols 的具体信息已经相当普遍可得,但人们有时仍难以确定:是什么 motivation 和 reasoning 导致了这些设计。

事实上,从最初 proposal 到当前 standards,design philosophy 已经发生了相当大的演化。例如,datagram 或 connectionless service 在第一篇论文中并没有得到特别强调,但后来却成为该 protocol 的 defining characteristic。再如,把 architecture 分成 IP 和 TCP 两层看起来是设计的基本部分,但它同样不是 original proposal 的一部分。

Internet design 中的这些变化,来自 standards 确定之前反复进行 implementation 和 testing 的过程。Internet architecture 仍在演化。有时,一个新的 extension 会挑战某项 design principle;但无论如何,理解设计历史都能为当前的 design extensions 提供必要背景。

ISO protocols 的 connectionless configuration 也受 Internet suite 的历史影响,因此,理解 Internet design philosophy 对研究 ISO 的人可能同样有帮助。

本文列出一套关于 Internet architecture 原始目标的观点,并讨论这些目标与 protocols 重要特性之间的关系。

2. Fundamental Goal

DARPA Internet Architecture 的最高层目标,是开发一种有效技术,用来复用已经互联的 networks。

有必要进一步解释这句话的含义。Internet 的 components 是 networks;这些 networks 要被互联,从而提供某种更大的 service。最初的目标,是把原始 ARPANET 与 ARPA packet radio network 连接起来,使 packet radio network 上的用户可以访问 ARPANET 上的大型 service machines。

当时,人们已经假定还会有其他类型的 networks 需要互联,尽管 local area network 尚未出现。

与其互联现有 networks,另一种选择是设计一个统一系统,把各种 transmission media 纳入同一个 multi-media network。这样或许能够实现更高程度的 integration,从而取得更好的 performance;但项目认为,如果 Internet 要在实践中有用,就必须纳入当时已经存在的 network architectures。

此外,networks 代表 administrative boundaries of control;这个项目的一个 ambition,就是处理如何把多个分别管理的 entities 整合成一个 common utility。

这里选择的 multiplexing 技术是 packet switching。也可以考虑 circuit switching 等 alternatives,但 remote login 等 applications 天然适合 packet-switching paradigm;而项目要整合的 networks 本身也是 packet-switching networks。因此,packet switching 被接受为 Internet architecture 的 fundamental component。

最高层目标的最后一部分,是对互联技术作出特定假设。由于 store-and-forward packet switching 已经在此前的 DARPA project——ARPANET——中得到展示并且相当成熟,因此最高层假设是:networks 将通过一层 Internet packet switches 互联,这些 switches 被称为 gateways。

由此得到 Internet 的 fundamental structure:一个 packet-switched communications facility,其中许多可区分的 networks 通过称为 gateways 的 packet communications processors 连接起来,而 gateways 实现 store-and-forward packet forwarding algorithm。

第 2 页:第二层目标与 survivability 的开头

the design philosophy p02

3. Second Level Goals

上一节的最高层目标包含 “effective” 一词,却没有定义 effective interconnection 必须实现什么。下面的列表总结了 Internet architecture 所确立的一组更详细目标:

  1. Internet communication 必须在 networks 或 gateways 丢失后仍能继续。
  2. Internet 必须支持多种 communication service 类型。
  3. Internet architecture 必须容纳多种 networks。
  4. Internet architecture 必须允许对其 resources 进行 distributed management。
  5. Internet architecture 必须具有 cost effectiveness。
  6. Internet architecture 必须允许 host 以较低 effort 接入。
  7. Internet architecture 使用的 resources 必须可核算(accountable)。

这组目标看起来可能只是一份列举所有理想 network features 的 checklist。但必须理解,这些目标是有顺序的;如果改变顺序,将会得到完全不同的 network architecture。

例如,由于该 network 被设计在 military context 中运行,而这意味着可能处于 hostile environment,因此 survivability 被放在第一位,accountability 被放在最后一位。战时,人们不太关心对已使用 resources 进行详细 accounting,而更关心调集现有的一切 resources,并快速以 operational 方式部署它们。

Internet architects 并非没有考虑 accountability;只是这个问题在设计早期很少受到关注,直到现在才开始被认真考虑。主要为 commercial deployment 设计的 architecture,显然会把这些目标的顺序反过来。

同样,cost effectiveness 确实在列表中,但其优先级低于 distributed management 或 support for a wide variety of networks 等目标。其他 protocol suites——包括一些流行的 commercial architectures——针对某一种 network 进行了优化,例如由中速电话线路组成的 long-haul store-and-forward network;它们在这个场景中提供非常 cost-effective 的 solution,却要以对其他类型网络(例如 local area nets)支持较差为代价。

读者应当认真考虑上面的列表,并认识到这不是一份 “motherhood” list,而是一组会强烈影响 Internet architecture 内部 design decisions 的 priorities。下面几节将讨论这份列表与 Internet features 之间的关系。

4. Survivability in the Face of Failure

列表中最重要的目标,是即使 networks 和 gateways 正在失效,Internet 仍应继续提供 communication service。具体来说,这个目标意味着:如果两个 entities 正通过 Internet 通信,而某次 failure 导致 Internet 暂时中断并重新配置以恢复 service,那么通信双方应能够继续对话,而不必重新建立或 reset conversation 的 high-level state。

更具体地说,在 transport layer 的 service interface 上,这种 architecture 不提供任何机制来告知 transport service 的 client:sender 与 receiver 之间的 synchronization 可能已经丢失。

这种 architecture 的假设是:除非已经不存在任何可以实现哪怕一种通信的 physical path,否则 synchronization 永远不会丢失。换句话说,在 transport 的顶层只有一种 failure,那就是 total partition。Architecture 要完全 mask 掉 transient failure。

第 3 页:Fate-sharing 与多种 service

the design philosophy p03

为了实现这个目标,描述 ongoing conversation 的 state information 必须受到保护。具体的 state information 例子包括:已经传输的 packets 数量、已经 acknowledged 的 packets 数量,或者尚未完成的 flow-control permissions 数量。

如果 lower layers 丢失了这些 information,它们就无法判断 data 是否丢失,application layer 就必须处理 synchronization loss。该 architecture 坚持不能发生这种 disruption,这意味着 state information 必须免受丢失。

在一些 network architectures 中,这些 state 存储在 network 的 intermediate packet-switching nodes 中。为了保护这些 information 不丢失,就必须进行 replication。由于 replication 具有 distributed nature,确保 robust replication 的 algorithms 本身就很难构建;而且,很少有带 distributed state information 的 networks 能真正提供 failure protection。

本 architecture 选择了另一种方案:把这些 information 从 network 中取出,集中放到 net 的 endpoint,也就是使用 network service 的 entity 上。我把这种 reliability approach 称为 fate-sharing。

fate-sharing model 认为:如果与某个 entity 相关的 state information 丢失时,该 entity 本身也同时丢失,那么丢失这部分 state information 是可以接受的。具体而言,与 transport-level synchronization 有关的信息存放在连接到 net、并使用其 communication service 的 host 中。

与 replication 相比,fate-sharing 有两个重要优点。第一,fate-sharing 可以防护任意数量的 intermediate failures,而 replication 只能防护某个有限数量的 failures(少于 replicated copies 的数量)。第二,fate-sharing 比 replication 更容易 engineering。

fate-sharing approach 对 survivability 有两个后果。第一,intermediate packet-switching nodes,即 gateways,不能拥有关于 ongoing connections 的 essential state information。相反,它们必须是 stateless packet switches;这种 network design 有时称为 datagram network。

第二,与由 network 保证 data reliable delivery 的 architecture 相比,这种方式更信任 host machine。如果 host 中负责 data sequencing 和 acknowledgment 的 algorithms 失效,那么该机器上的 applications 就无法运行。

尽管 survivability 在目标列表中排第一,它仍然排在“互联现有 networks”这个最高层目标之后。例如,设计一个 single multi-media network 可能得到 survivability 更强的 technology。Internet 对 network 报告自身 failure 的能力只作了很弱的假设,因此 Internet 被迫使用 Internet-level mechanisms 检测 network failures,可能带来更慢、也不那么具体的 error detection。

5. Types of Service

Internet architecture 的第二个目标,是在 transport service level 支持多种 types of service。不同 service types 的区别,在于 speed、latency 和 reliability 等方面的 requirements 不同。

传统的 service type 是双向 reliable delivery of data。这种 service 有时称为 “virtual circuit” service,适用于 remote login 或 file transfer 等 applications。它是 Internet architecture 最早提供的 service,使用的是 Transmission Control Protocol(TCP)。

很早就有人认识到,即使这种 service 也有多个 variants:remote login 要求低 delivery delay,但对 bandwidth 的要求较低;file transfer 不太关心 delay,却非常关心 high throughput。TCP 试图同时提供这两种 service。

最初的 TCP concept 是让它足够 general,以支持任何需要的 service type。但随着所需 services 的完整范围逐渐清晰,把所有支持都放进一个 protocol 似乎太困难了。

第一个超出 TCP 范围的 service 例子,是对 XNET(cross-Internet debugger)的支持。XNET 不适合使用 TCP,原因有几个。首先,debugger protocol 不应当是 reliable 的。这个结论看起来可能很奇怪,但在 stress 或 failure 条件下(而这恰恰可能是最需要 debugger 的时候),要求 reliable communications 可能导致完全无法通信。

更好的做法,是构造一种能够处理“实际到达的任何内容”的 service,而不是坚持必须按顺序交付发送的每一个 byte。其次,如果 TCP 足够 general,可以处理广泛范围的 clients,那么它也必然相当 complex。同样,在 debugging environment 中要求支持这些 complexity 似乎不合理,因为该 environment 甚至可能缺少 operating system 中的基本 services,例如 timer support。于是,XNET 被设计为直接运行在 Internet 提供的 datagram service 之上。

第 4 页:多种 transport service 与 network varieties 的开头

the design philosophy p04

另一个不适合 TCP 的 service,是 digitized speech 的 real-time delivery;它用于支持 command-and-control applications 中的 teleconferencing。

在 real-time digital speech 中,首要要求不是 reliable service,而是尽量降低并平滑 packet delivery 的 delay。Application layer 把 analog speech 数字化,把产生的 bits packetize,然后以规则间隔发到 network 中。它们也必须以规则间隔到达 receiver,才能被重新转换为 analog signal。

如果 packets 没有按预期到达,就不可能实时重组 signal。关于 delay variation 的 control,有一个出人意料的观察:network 中最严重的 delay source,正是用来提供 reliable delivery 的 mechanism。

典型的 reliable transport protocol 遇到 missing packet 时,会请求 retransmission,并在丢失 packet 被重新传输之前延迟后续 packets 的 delivery。随后它按顺序交付这个 packet 和所有剩余 packets。这个过程中的 delay 可能是 network round-trip delivery time 的许多倍,并可能完全破坏 speech reassembly algorithm。

相比之下,处理偶尔丢失的 packet 非常容易。丢失的 speech 可以简单地用一小段 silence 替代;多数情况下,这不会损害听者对 speech 的理解。如果确实造成影响,还可以在 higher level 进行 error correction,让听者要求 speaker 重复受损的 phrase。

因此,在 Internet architecture 开发相当早期就决定:需要不止一种 transport service;architecture 至少必须能够同时容纳那些希望约束 reliability、delay 或 bandwidth 的不同 transports。

这个目标导致原本作为单一 protocol 存在的 TCP 和 IP 被拆成两层。TCP 提供一种特定 service,即 reliable sequenced data stream;IP 则试图提供一个 basic building block,用它可以构造多种 types of service。这个 building block 就是 datagram,而 datagram 同时也是为了支持 survivability 才被采用的。

由于 datagram delivery 的 reliability 并不保证,而只是 “best effort”,因此可以在 datagram 之上构造 reliable service(在更高层进行 acknowledgment 和 retransmission),也可以构造牺牲 reliability、换取底层 network substrate 原始 delay characteristics 的 service。

User Datagram Protocol(UDP)被创建出来,为 Internet 的 basic datagram service 提供 application-level interface。

Architecture 不希望假定底层 networks 自身支持多种 service types,因为这会违反使用现有 networks 的目标。相反,设计者希望利用 host 和 gateway 中的 algorithms,从 basic datagram building block 构造多种 types of service。

例如(虽然大多数当前 implementations 并未这样做),可以把属于 controlled-delay、但 unreliable service 的 datagrams 放到 transmission queues 的最前面,除非它们的 lifetime 已过期;过期时就丢弃它们。与此同时,属于 reliable streams 的 packets 可以放在 queues 后部,但无论它们在 network 中停留多久,都不丢弃。

在没有底层 networks 的显式支持时提供多种 service types,比最初希望的更加困难。最严重的问题是:按照某一种 service type 设计的 networks,往往没有足够 flexibility 支持其他 services。

最常见的是,某个 network 按照“应该提供 reliable service”的假设设计,因此会把 delay 作为提供 reliability 的一部分注入,即使调用者并不需要这种 reliability。比如,X.25 定义的 interface behavior 就意味着 reliable delivery,而且没有办法关闭这个 feature。

因此,尽管 Internet 可以成功运行在 X.25 networks 之上,但在这种 context 中无法提供期望的 service-type variability。具有内在 datagram service 的其他 networks,在允许的 service types 上灵活得多;但这类 networks,尤其在 long-haul context 中,要少得多。

6. Varieties of Networks

Internet architecture 要取得成功,必须能够纳入并利用广泛的 network technologies,包括 military 和 commercial facilities。这一目标已经完成得很成功:Internet 运行在各种 networks 之上,包括 long-haul nets(ARPANET 本身和各种 X.25 networks)、local area nets(Ethernet、ringnet 等)、broadcast satellite nets(工作在 64 kilobits per second 的 DARPA Atlantic Satellite Network,以及在美国境内工作于 3 megabits per second 的 DARPA Experimental Wideband Satellite Net)、packet radio networks(DARPA packet radio network、英国的实验性 packet radio net,以及 amateur radio operators 开发的 network),还有各种 serial links,速率从 1200 bits per second 的 asynchronous connections 到 T1 links 不等;此外还有多种 ad hoc facilities,包括 intercomputer busses,以及其他 network suites 的 higher layers 所提供的 transport service,例如 IBM 的 HASP。

第 5 页:Network assumptions 与较低优先级目标

the design philosophy p05

Internet architecture 通过对 network 必须提供的 function 作最小假设,实现了这种 flexibility。基本假设是:network 能够传输一个 packet 或 datagram。这个 packet 必须达到 reasonable size,例如 minimum 可能为 100 bytes;并且应以 reasonable、但不完美的 reliability 交付。如果它不只是 point-to-point link,network 还必须具有某种合适的 addressing 形式。

有一些 services 是 network 明确不需要提供的,包括:reliable 或 sequenced delivery、network-level broadcast 或 multicast、对 transmitted packet 的 priority ranking、支持多种 service types,以及对 failures、speeds 或 delays 的内部 knowledge。

如果这些 services 是必须的,那么要把某个 network 纳入 Internet,就必须让 network 直接支持它们,或者让 network interface software 在 endpoint 提供 enhancements 来模拟它们。设计者认为这不是理想方式,因为每个 network、以及每台 host 到每个 network 的 interface,都必须分别重新 engineering 和 reimplement 这些 services。

如果把这些 services 放在 transport 层实现,例如由 TCP 提供 reliable delivery,那么只需要完成一次 engineering;对每台 host 来说,也只需实现一次。之后,为新 network 编写 interface software 通常会非常简单。

7. Other Goals

到目前为止讨论的三个目标,对 architecture 设计产生了最深远影响。由于剩余目标优先级较低,它们可能实现得不那么有效,或者没有得到如此完整的 engineering。

Internet 的 distributed management 目标在某些方面确实实现了。例如,Internet 中并不是所有 gateways 都由同一个 agency 实现和管理。已部署的 Internet 中存在多个 management centers,每个 center 管理一部分 gateways;同时还有 two-tier routing algorithm,允许来自不同 administrations 的 gateways 交换 routing tables,即使它们并不完全相互信任。单一 administration 内的 gateways 之间,还会使用各种 private routing algorithms。

同样,管理 gateways 的 organizations,也不一定是管理其所连接 networks 的 organizations。

另一方面,今天 Internet 的一些最重要问题,正与 distributed management 工具不足有关,尤其是 routing 领域。在当前运行的大型 internet 中,routing decisions 需要受到 resource-usage policies 的约束。今天只能以非常有限的方式做到这一点,通常需要手工设置 tables;这种方式既容易出错,也不够 powerful。未来几年 Internet architecture 最重要的变化,可能就是在 multiple administrations 的 context 中开发新一代 resource-management tools。

显然,在某些情况下,与更定制化的 architecture 相比,Internet architecture 无法同样 cost-effectively 地利用昂贵的 communication resources。Internet packets 的 headers 相当长(典型 header 为 40 bytes),因此当发送 short packets 时,这种 overhead 很明显。

最糟糕的情况当然是 single-character remote login packets:它携带 1 byte data,却带有 40 bytes header。实际上,任何 protocol suite 都很难声称这种 interchanges 能以 reasonable efficiency 执行。

另一端是 file transfer 的 large packets:如果携带约 1,000 bytes data,header overhead 只有 4%。

另一个可能的 inefficiency source 是 lost packets 的 retransmission。由于 Internet 不要求在 network level recovery lost packets,所以可能必须从 Internet 的一端向另一端重新传输 lost packet。这意味着 retransmitted packet 可能再次穿越多个 intervening nets,而 network-level recovery 不会产生这类 repeated traffic。

这是前面讨论的 endpoint service decision 所带来的 tradeoff:network interface code 更简单,但 overall efficiency 可能更低。不过,如果 loss rate 足够低(例如 1%),incremental cost 是可以容忍的。对于纳入该 architecture 的 networks,一个大致 rule of thumb 是:每 100 个 packets 丢失 1 个是相当合理的;但每 10 个丢失 1 个,就说明如果需要该 service type,应当向 network 加入 reliability enhancements。

第 6 页:Host attachment、Architecture and Implementation 的开头

the design philosophy p06

把 host 接入 Internet 的成本,可能略高于其他 architectures,因为提供所需 service types 的全部 mechanisms(例如 acknowledgments 和 retransmission strategies)都必须在 host 中实现,而不是在 network 中实现。

最初,对于不熟悉 protocol implementation 的 programmers 来说,这项 effort 似乎相当 daunting。Implementors 曾尝试把 transport protocols 移到 front-end processor 中,希望 protocols 只需实现一次,而不必为每一种 host 再实现一遍。

但这样就必须发明一种 host-to-front-end protocol;有些人认为它的 implementation 复杂度几乎不亚于原始 transport protocol。随着人们对 protocols 的经验增加,在 host 中实现 protocol suite 所带来的 anxiety 似乎正在下降;现在,personal computers 和其他 computing resources 非常有限的 machines 也有了可用 implementations。

host-resident mechanisms 还带来一个相关问题:对该 mechanism 的 poor implementation,可能同时伤害 network 和 host。这个问题之所以被容忍,是因为最初 experiments 只涉及少数可控的 host implementations。

然而,随着 Internet 的使用扩大,这个问题偶尔会以严重方式暴露出来。在这个意义上,导致 fate-sharing、进而导致 host-resident algorithms 的 robustness goal,如果 host 行为异常,反而会造成 robustness 的损失。

最后一个目标是 accountability。事实上,Cerf 和 Kahn 的第一篇论文就把 accounting 作为 protocols 和 gateways 的重要 function。但在当前,Internet architecture 几乎没有用于核算 packet flows 的 tools。随着 architecture 扩展到 non-military consumers,这个问题现在才开始得到研究;这些 consumers 非常关心理解和监控 internet 内部 resources 的使用情况。

8. Architecture and Implementation

前面的讨论清楚表明,Internet architecture 的目标之一,是在所提供的 service 上保持广泛 flexibility。可以使用不同 transport protocols 提供不同 types of service,也可以纳入不同 networks。

换句话说,architecture 尽力不去限制 Internet 可以被 engineering 成提供的 service 范围。反过来,这意味着:如果要理解某个 Internet implementation 能提供什么 service,就不能只看 architecture,而必须看特定 hosts 和 gateways 中 software 的实际 engineering,以及被纳入的特定 networks。

我将一组在 Internet architecture context 中互联的 networks、gateways 和 hosts 称为一个 realization。不同 realizations 所提供的 service,可能相差几个数量级。

有些 realizations 建立在 1200 bits per second 的 phone lines 上,有些则只使用 speed 大于 1 megabit per second 的 networks。显然,人们对这些 realizations 的 throughput expectations 会相差几个数量级。

同样,有些 Internet realizations 的 delay 以 tens of milliseconds 计,另一些则以 seconds 计。某些 applications(例如 real-time speech)跨越这两种 realizations 时,工作方式会根本不同。

有些 Internets 在 gateways 和 paths 中 engineering 了大量 redundancy。这些 Internets 具有 survivability,因为 failure 发生后存在可以重新配置的 resources。另一些 Internet realizations 为降低成本,在整个 realization 中使用 single points of connectivity;这样某次 failure 可能把 Internet 分成两半。

Internet architecture 从设计上就容忍这种 realization variety。然而,它也让具体 realization 的 designer 承担了大量 engineering 工作。

这项 architecture development 面临的主要 struggle 之一,是理解如何为 realization designer 提供 guidance,把 realization 的 engineering 与最终产生的 types of service 联系起来。

例如,designer 必须回答这类问题:如果 overall service 要达到某个 throughput rate,底层 networks 需要什么样的 bandwidth?给定某种可能的 failure model,在这个 realization 中应当 engineering 什么样的 redundancy?

大多数已知的 network design aids,似乎都不能有效回答这类问题。例如,protocol verifiers 可以帮助确认 protocols 是否满足 specifications,但这些 tools 几乎从不处理 performance issues;而 performance 正是 type of service 概念的关键。

相反,它们处理的是 protocol 相对于 specification 的、范围更有限的 logical correctness。无论在 specification 阶段还是 implementation 阶段,用来验证 logical correctness 的 tools 都很有用;但它们无法帮助解决 performance 相关的严重问题。

典型的 implementation experience 是:即使已经证明 logical correctness,仍会发现 design faults,而这些 faults 可能造成一个数量级的 performance degradation。对这个问题的探索表明,困难通常不在 protocol 本身,而在 protocol 所运行的 operating system 上。

由于问题在 operating system 中,因此很难在 architectural specification 的 context 内处理它。但我们仍然强烈认为,必须为 implementor 提供 guidance。直到今天,我们还在继续与这个问题斗争。

第 7 页:Performance guidance、Datagrams 与 TCP 的开头

the design philosophy p07

另一类 design aid 是 simulator。它接收一个特定 realization,并在各种 loadings 下探索该 realization 能提供的 service。

目前还没有人尝试构造一种 simulator,把可能的 Internet realizations 中 gateway implementation、host implementation 和 network performance 的巨大 variability 都考虑进去。

因此,大多数 Internet realizations 的 analysis 仍然是在信封背面进行的。Internet architecture 的 goal structure 说明:只要进行分析的人足够 knowledgeable,back-of-the-envelope analysis 通常已经足够。

具体 realization 的 designer 往往不太关心是否把 line utilization 再提高最后 5%,而更关心:在当前可用的 resources 下,所需的 type of service 到底能不能实现。

Architecture 与 performance 的关系极具挑战。Internet architecture 的 designers 强烈认为,只关注 logical correctness 而忽视 performance 是严重错误;但他们很难在 architecture 内 formalize performance constraint。

困难一方面来自 architecture 的目标不是约束 performance,而是允许 variability;另一方面(也许更根本),当时似乎没有能够描述 performance 的有用 formal tools。

这个问题尤其令人困扰,因为 Internet project 的目标,是产生将成为 military standards 的 specification documents。Government contracting 中有一个众所周知的问题:不能期待 contractor 满足 procurement standard 中没有写出的任何 criteria。

因此,如果 Internet 关心 performance,就必须把 performance requirements 写入 procurement specification。比如,可以很容易发明约束 performance 的 specification,要求 implementation 每秒必须传递 1,000 个 packets。

然而,这种 constraint 不能成为 architecture 的一部分。因此,负责 procurement 的人必须意识到:这些 performance constraints 必须加入 specification;并且必须正确指定它们,才能得到提供所需 types of service 的 realization。

我们还没有找到一种好的方法,能够在 architecture 中为执行这项任务的人提供 guidance。

9. Datagrams

Internet 的 fundamental architectural feature,是把 datagrams 作为跨越底层 networks 传输的 entity。

正如本文已经指出的,datagrams 在 architecture 中重要,有几个原因。第一,它们消除了 intermediate switching nodes 中 connection state 的需要;这意味着 failure 之后可以重新构造 Internet,而不必担心这些 state。

第二,datagram 提供了一个 basic building block,可以用来实现多种 types of service。与通常意味着固定 type of service 的 virtual circuit 不同,datagram 提供的是更 elementary 的 service;endpoints 可以按照需要组合它,从而构造所需 type of service。

第三,datagram 代表了 minimum network service assumption,使各种 networks 能够被纳入不同的 Internet realizations。

采用 datagram 是一个极其成功的决定;它使 Internet 非常成功地实现了最重要的 goals。

但人们经常对 datagram 产生一种错误假设:认为选择 datagram 的动机,是支持一个本质上等同于 datagram 的 higher-level service。换句话说,有人认为之所以提供 datagram,是因为 application 所需的 transport service 就是 datagram service。

实际上,很少是这样。Internet 中确实有一些 applications——例如 date servers 或 name servers 的简单 queries——使用基于 unreliable datagram 的 access method;但 Internet 中的大多数 services,都希望使用比 simple datagram 更 sophisticated 的 transport model。

有些 services 希望增强 reliability,有些希望对 delay 进行 smoothing 和 buffering,但几乎所有 services 都期待比 datagram 更复杂的东西。

必须理解,datagram 在这里的作用是 building block,而不是它自身就是一种 service。

10. TCP

TCP 的开发中有许多有趣且具有争议的 design decisions;在成为相对稳定的 standard 之前,TCP 本身也经历了多个 major versions。

其中一些 design decisions,例如 window management 和 port-address structure 的性质,在作为 TCP protocol handbook 一部分发布的一系列 implementation notes 中有讨论。但同样,decision 背后的 motivation 有时并不清楚。

本节尝试记录 TCP 某些部分早期设计背后的 reasoning。本节必然是不完整的;如果要完整回顾 TCP 本身的历史,还需要另一篇同等长度的论文。

第 8 页:TCP 的 byte stream、flow control 与 EOL

the design philosophy p08

原始 ARPANET host-to-host protocol 同时基于 bytes 和 packets 提供 flow control。这似乎过于复杂,因此 TCP designers 认为只需要一种 regulation 形式即可。

最终选择 regulation delivery of bytes,而不是 packets。因此,TCP 中的 flow control 和 acknowledgment 基于 byte number,而不是 packet number。实际上,在 TCP 中,data 如何 packetize 并没有 significance。

这个决定由多个 considerations 驱动,其中一些后来变得不再 relevant,而另一些的重要性则超出了预期。

采用 byte acknowledgment 的一个原因,是允许把 control information 插入 byte 的 sequence space,从而使 control 和 data 都可以被 acknowledged。后来放弃了这种使用 sequence space 的方式,转而用 ad hoc techniques 处理每条 control message。原始 idea 虽然具有吸引人的 generality,但在实践中带来了 complexity。

选择 byte stream 的第二个原因,是在必要时允许把 TCP packet 拆成更小的 packets,以便通过 packet size 较小的 network。但当 IP 从 TCP 中拆出来后,这项 function 被移到了 IP layer;IP 也不得不发明一种不同的 fragmentation method。

第三个原因,是相较于按 packets acknowledgment,按 bytes acknowledgment 允许 sending host 在必须 retransmit data 时,把多个 small packets 聚集到一个 larger packet 中。这个 advantage 是否重要,当时并不清楚;后来事实证明它是 critical 的。

像 UNIX 这样的 systems,内部 communication model 经常以 single-character interactions 为基础,因此常会发送大量 packet,每个 packet 只含 1 byte data。(从 network 角度看,人们可能认为这种行为很 silly,但它是现实,也是 interactive remote login 的必要条件。)

人们经常观察到,这类 host 能产生大量只含一个 byte data 的 packets;这些 packets 到达的速度,比 slow host 能处理它们的速度快得多。结果就是 packet loss 和 retransmission。

如果 retransmission 仍然发送原始 packets,那么同样的问题会在每次 retransmission 中重复,performance impact 会严重到无法运行。但由于 bytes 会在 retransmission 时聚集到一个 packet 中,retransmission 就能以更 effective 的方式完成,从而支持 practical operation。

另一方面,也可以认为,按 bytes acknowledgment 恰恰造成了这个问题。如果 flow control 基于 packets 而不是 bytes,那么这种 flood 也许根本不会发生。

然而,packet-level control 会在发送 small packets 时严重限制 throughput。如果 receiving host 指定自己要接收的 packet 数量,却不知道每个 packet 中有多少 bytes,那么实际接收的数据量可能相差 1,000 倍:这取决于 sending host 是在每个 packet 中放 1 byte,还是放 1,000 bytes。

回头看,如果 TCP 要有效支持多种 services,正确的 design decision 可能是同时 regulation packets 和 bytes,就像原始 ARPANET protocols 那样。

与 byte stream 有关的另一个 design decision 是 End-Of-Letter flag,即 EOL。它后来从 protocol 中消失,被 Push flag,即 PSH,替代。

EOL 的原始 idea 是把 byte stream 切分为 records。实现方式是把不同 records 的 data 放进不同 packets,这与 retransmission 时合并 packets 的 idea 不兼容。

因此,EOL semantics 被改成更弱的形式:它只表示 stream 中截至此处的数据是一个或多个完整的 application-level elements,并应促使 TCP 或 network 中的内部 buffering flush。

使用 “one or more” 而不是 “exactly one”,就可以把多个 elements 合并在一起,同时保留在 reassembly 时压缩 data 的目标。但这种较弱的 semantics 意味着,各种 applications 必须在 data stream 之上自行发明 ad hoc mechanism 来分隔 records。

在 EOL semantics 的演化过程中,还有一种鲜为人知的 intermediate form,引发了大量争论。

取决于 host 的 buffering strategy,TCP 的 byte-stream model 在一种不太可能出现的场景中会造成严重问题。假设某个 host 把 incoming data 放入一系列 fixed-size buffers 中:buffer 满了,或者收到 EOL 时,就把 buffer 交给 user。

现在考虑这种情况:到达了一个 out-of-order packet,而且它 out of order 的程度很大,已经落在当前 buffer 之后。再考虑:收到这个 out-of-order packet 之后,一个带 EOL 的 packet 使当前 buffer 只填了一部分就交给 user。

这组 actions 会导致 next buffer 中的 out-of-order data 放在错误位置,因为交给 user 的 buffer 中存在 empty bytes。处理这种情况会在 host 中产生看起来不必要的 bookkeeping problems。

为解决这个问题,有人提议让 EOL “use up” sequence space,直到下一个值达到 buffer size 的整倍数为止。换句话说,建议把 EOL 作为一种把 byte stream 映射到 host buffer-management 的工具。

第 9 页:Rubber EOL、Conclusion 与历史回顾

the design philosophy p09

这个 idea 当时没有得到很好的接受,因为它显得过于 ad hoc,而且似乎只有一台 host 存在这个问题。回头看,把某种把 sequence space 与 host buffer-management algorithm 联系起来的机制纳入 TCP,也许才是正确的做法。

当时,designers 只是缺少足够 insight,不知道如何以足够 general 的方式完成这件事。

脚注:这种 EOL 的正式称呼是 “Rubber EOL”,但反对者很快把它戏称为 “rubber baby buffer bumpers”,借此嘲讽这个 idea,并让提出者连续十次快速说出这句话。应当把坚持这一 idea、顶住反对者嘲弄的人——Bill Plummer——视为该 idea 的 creator。

11. Conclusion

在其 priorities 所限定的 context 中,Internet architecture 非常成功。Protocols 在 commercial 和 military environments 中得到广泛使用,并催生了许多相似 architectures。

同时,它的成功也说明:在某些情况下,designers 的 priorities 与实际 users 的 needs 并不一致。accounting、resource management,以及在由不同 administrations 分别管理的 regions 中运行等问题,都需要得到更多关注。

datagram 很好地解决了 Internet 最重要的 goals,但在处理 priority list 中较靠后的 goals 时,它表现得不那么好。例如,在 datagram context 中实现 resource management 和 accountability 已被证明很困难。

正如上一节所述,大多数 datagrams 都是从 source 到 destination 的某个 packet sequence 的一部分,而不是 application level 的 isolated units。但 gateway 无法直接看到这个 sequence 的存在,因为它被迫单独处理每个 packet。因此,resource-management decisions 或 accounting 必须分别在每个 packet 上完成。

把 datagram model 强加在 Internet layer 上,使该 layer 失去了一个本可用来实现这些 goals 的重要 information source。

这说明,下一代 architecture 也许存在比 datagram 更好的 building block。这个 building block 的一般特征是:它能够识别从 source 到 destination 传输的 packet sequence,但不对该 sequence 的 service type 作任何特定假设。

我使用 flow 这个词来描述这个 building block。为了记住正在通过 gateways 的 flows 的性质,gateways 必须拥有 flow state;但这种 state 对于维持 flow 所关联的 desired type of service,不应是 critical 的。

相反,type of service 应由 endpoints 强制执行:endpoints 周期性地发送 messages,确保该 flow 仍关联着正确的 type of service。这样,即使 crash 导致与 flow 相关的 state information 丢失,也不会永久中断正在使用的 service features。

我把这个 concept 称为 soft state。它很可能让我们在实现 survivability 和 flexibility 这些 primary goals 的同时,更好地处理 resource management 和 accountability 问题。探索 alternative building blocks,是 DARPA Internet Program 当前的 research directions 之一。

12. Acknowledgments — A Historical Perspective

Internet project 的 contributors 太多,不可能全部致谢;在 15 年 development 中,实际参与者有数百人,包括 designers、implementors、writers 和 critics。

事实上,项目是如何被管理的,本身就是一个可能值得单独写一篇论文的重要 topic。参与者来自 universities、research laboratories 和 corporations;他们在一定程度上联合起来,实现了这个共同目标。

TCP 的 original vision 来自 Robert Kahn 和 Vinton Cerf。他们早在 1973 年就非常清楚地看到了:一个具有合适 features 的 protocol,可能成为把各种 emerging network technologies 黏合在一起的 glue。

他们在 DARPA 的位置上指导项目度过早期阶段,使 TCP 和 IP 最终成为 DoD standards。

作者在 1970 年代中期加入这个 project,并在 1981 年接管 TCP/IP 的 architectural responsibility。他感谢所有与自己一起工作的人,尤其感谢那些花时间重建本文中某些已经遗失的历史的人。

References [1]–[2]

  1. V. Cerf;R. Kahn,“A Protocol for Packet Network Intercommunication”,IEEE Transactions on Communications,Vol. 22,No. 5,May 1974,pp. 637–648。
  2. ISO,Transport Protocol Specification,Technical Report IS-8073,International Organization for Standardization,September 1984。

References

第 10 页:References [3]–[18]

the design philosophy p10

  1. ISO,Protocol for Providing the Connectionless-Mode Network Service,Technical Report DIS8473,International Organization for Standardization,1986。
  2. R. Callon,“Internetwork Protocol”,Proceedings of the IEEE,Vol. 71,No. 12,December 1983,pp. 1388–1392。
  3. Jonathan B. Postel,“Internetwork Protocol Approaches”,IEEE Transactions on Communications,Vol. COM-28,No. 4,April 1980,pp. 605–611。
  4. Jonathan B. Postel;Carl A. Sunshine;Danny Cohen,“The ARPA Internet Protocol”,Computer Networks 5,Vol. 5,No. 4,July 1981,pp. 261–271。
  5. Alan Sheltzer;Robert Hinden;Mike Brescia,“Connecting Different Types of Networks with Gateways”,Data Communications,August 1982。
  6. J. McQuillan;D. Walden,“The ARPA Network Design Decisions”,Computer Networks,Vol. 1,No. 5,August 1977,pp. 243–289。
  7. R. E. Kahn;S. A. Gronemeyer;J. Burdifiel;E. V. Hoversten,“Advances in Packet Radio Technology”,Proceedings of the IEEE,Vol. 66,No. 11,November 1978,pp. 1408–1496。
  8. B. M. Leiner;D. L. Nelson;F. A. Tobagi,“Issues in Packet Radio Design”,Proceedings of the IEEE,Vol. 75,No. 1,January 1987,pp. 6–20。
  9. —,“Transmission Control Protocol RFC-793”,DDN Protocol Handbook,Vol. 2,September 1981,pp. 2.179–2.198。
  10. Jack Haverty,“XNET Formats for Internet Protocol Version 4 IEN 158”,DDN Protocol Handbook,Vol. 2,October 1980,pp. 2-345–2-348。
  11. Jonathan Postel,“User Datagram Protocol NICRFC-768”,DDN Protocol Handbook,Vol. 2,August 1980,pp. 2.175–2.177。
  12. I. Jacobs;R. Binder;E. Hoversten,“General Purpose Packet Satellite Networks”,Proceedings of the IEEE,Vol. 66,No. 11,November 1978,pp. 1448–1467。
  13. C. Topolcic;J. Kaiser,“The SATNET Monitoring System”,Proceedings of the IEEE MILCOM,Boston, MA,October 1985,pp. 26.1.1–26.1.9。
  14. W. Edmond;S. Blumenthal;A. Echenique;S. Storch;T. Calderwood;T. Rees,“The Butterfly Satellite IMP for the Wideband Packet Satellite Network”,Proceedings of ACM SIGCOMM ’86,Stowe, VT,August 1986,pp. 194–203。
  15. David D. Clark,“Window and Acknowledgment Strategy in TCP NIC-RFC-813”,DDN Protocol Handbook,Vol. 3,July 1982,pp. 3-5–3-26。
  16. David D. Clark,“Name, Addresses, Ports, and Routes NIC-RFC-814”,DDN Protocol Handbook,Vol. 3,July 1982,pp. 3-27–3-40。

架构原则索引

原则/机制解决的问题主要代价或边界
existing-network interconnection把异构、分别管理的 networks 组成更大的 common utility不能为单一 network 做完全定制优化
survivabilitynetwork/gateway 暂时失效后保持 high-level conversation state对 failure detection 作弱假设,可能延迟或不精确
fate-sharing避免在 gateways 中复制大量 connection state更依赖 host;host-resident protocol 出错会伤害 network
stateless gatewayfailure/reconfiguration 时不必恢复 connection stategateway 看不到完整 flow,resource management 较困难
datagram以 minimum network assumptions 接纳多种 networks不直接提供 reliability、ordering 或复杂 service semantics
IP/TCP layering用 IP 提供 building block,用 TCP 提供一种可靠 stream service底层 network 不一定足够支持所有 service types
endpoint service construction在 host/transport 层一次性实现 reliability 等功能host attachment 更复杂,跨 Internet retransmission 可能浪费资源
realization保持 architecture 灵活,让不同部署拥有不同性能designer 必须自行完成大量 bandwidth、redundancy 和 performance engineering
flow/soft state让 gateway 观察 packet sequence,同时避免 flow state 成为永久关键状态需要 gateway state 和 endpoint refresh,本文仅提出研究方向

设计判断与边界

  1. 本文解释的是 design priorities,不是协议字段手册:理解 IP/TCP 的 motivation,需要先理解 survivability、异构 network 和分布式管理之间的排序。
  2. fate-sharing 把可靠性边界推向 endpoint:它避免了 intermediate replication 的复杂度,但把更多 responsibility 交给 host 和 transport implementation。
  3. datagram 的价值是组合性:它不是要求 application 直接使用 unreliable datagram,而是提供一个最低共同分母,让 endpoint 组合出 reliable、low-delay 或其他 service。
  4. architecture 不等于 performance guarantee:同一个 architecture 可以运行在 1200 bps phone line 或高速 network 上;真正的 service 由 realization 决定。
  5. 低优先级目标会留下结构性欠账:accountability、resource management 和 multi-administration routing 并不是 datagram architecture 最擅长的部分。
  6. flow/soft state 是后续方向,而不是本文所描述的既成标准:它试图补足 datagram 对 resource/accounting information 的缺失,同时保留 survivability。

本篇验收

  • [x] 已固定 SIGCOMM ’88 版本,共 10 页;SHA-256 为 0cf87f91a34e30497bc9fe4b908d52164bafbd8e1dc845d7810ac22b8ce36c8c。
  • [x] 已按 PDF 页序保留第 1–10 页页面图;10 张 PNG 均为 1224×1584,正文按 600 宽度嵌入。
  • [x] 已覆盖 Abstract、Introduction、Fundamental Goal、Second Level Goals、Survivability、Types of Service、Varieties of Networks、Other Goals、Architecture and Implementation、Datagrams、TCP、Conclusion、Acknowledgments 和 18 条 References。
  • [x] 已保留目标编号、fate-sharing 解释、datagram/IP/TCP layering、realization、flow、soft state 和 Rubber EOL 脚注。
  • [x] 已补充术语表、架构原则索引、设计判断和与前后篇目的导航链接。

参考资料

← 返回列表
← 上一篇 论文:Congestion Avoidance and Control 下一篇 → 论文:The Transaction Concept: Virtues and Limitations

评论 (0)

暂无评论,来留下第一条吧。
登录 或 注册 后才能发表评论