Topic02 Architecture
Topic02 Architecture
• Abstraction
• Layering
• Layers and Communications
• Entities and Peers
• What is a protocol?
• Protocol Standardization
• The architects process
– How to break system into modules
– Where modules are implemented
– Where is state stored
• Internet Philosophy and Tensions 2
Abstraction Concept
A mechanism for breaking down a problem
4
Computer System Modularity (cnt’d)
5
Network System
Modularity
Like software modularity, but:
• Implementation is distributed across many
machines (routers and hosts)
• Must decide:
– How to break system into modules
• Layering
– Where modules are implemented
• End-to-End Principle
– Where state is stored
• Fate-sharing
6
Layering Concept
• A restricted form of abstraction: system functions
are divided into layers, one built upon another
• Often called a stack; but not a data structure!
7
Layers and Communications
• Interaction only between adjacent layers
• layer n uses services provided by layer n-1
• layer n provides service to layer n+1
• Bottom layer is physical media
• Top layer is application
8
Entities and Peers
Entity – a thing (an independent existence)
Entities interact with the layers above and below
Entities communicate with peer entities
– same level but different place (eg different person, different
box, different host)
Communications between peers is supported by
entities at the lower layers
9
Entities and Peers
Entities usually do something useful
– Encryption – Error correction – Reliable Delivery
– Nothing at all is also reasonable
Not all communications is end-to-end
Examples for things in the middle
– IP Router – Mobile Phone Cell Tower
– Person translating French to English
10
Layering and Embedding
In Computer Networks we often see higher-layer information embedded within lower-layer
information
• Such embedding can be considered a form of layering
• Higher layer information is generated by stripping off headers and trailers of the current layer
• eg an IP entity only looks at the IP headers
BUT embedding is not the only form of layering
11
source Example Embedding
message M application (also called Encapsulation)
segment Ht M transport
datagram Hn Ht M network
frame Hl Hn Ht M link
physical
link
physical
switch
destination Hn Ht M network
M application
Hl Hn Ht M link Hn Ht M
Ht M transport physical
Hn Ht M network
Hl Hn Ht M link router
physical
12
Internet protocol stack versus
OSI Reference Model
13
ISO/OSI reference model
• presentation: allow applications to
interpret meaning of data, e.g., application
encryption, compression, machine-
presentation
specific conventions
• session: synchronization, checkpointing, session
recovery of data exchange transport
• Internet stack “missing” these layers!
network
– these services, if needed, must
link
be implemented in application
physical
14
What is a protocol?
human protocols: network protocols:
• “what’s the time?” • machines rather than
• “I have a question” humans
• introductions • all communication activity
in Internet governed by
… specific msgs sent protocols
… specific actions taken
when msgs received, or
protocols define format, order of msgs sent
other events and received among network entities,
and actions taken on msg transmission,
receipt
15
What is a protocol?
a human protocol and a computer network protocol:
Hi
TCP connection
request
Hi
TCP connection
Got the response
time? GET http://www.cl.cam.ac.uk/index.html
2:00
<file>
time
17
So many Standards Problem
• Many different packet-switching networks
• Each with its own Protocol
• Only nodes on the same network could communicate
18
INTERnet Solution
Gateways
19
Internet Design Goals (Clark ‘88)
• Reuse
25
Drawbacks of Layering
27
Basic Observation
• Some application requirements can only be correctly
implemented end-to-end
– reliability, security, etc.
• Hosts
– Can satisfy the requirement without network’s help
– Will/must do so, since they can’t rely on the network
28
Example: Reliable File
Transfer
Host A Host B
Appl. Appl.
OS OK OS
• Solution 2 is complete
– Full functionality can be entirely implemented at application layer
with no need for reliability from lower layers
30
Summary of End-to-End
Principle
• Implementing functionality (e.g., reliability) in the network
– Doesn’t reduce host implementation complexity
– Does increase network complexity
– Probably increases delay and overhead on all applications even
if they don’t need the functionality (e.g. VoIP)
31
“Only-if-Sufficient”
Interpretation
32
“Only-if-Necessary”
Interpretation
33
“Only-if-Useful”
Interpretation
34
We have some tools:
• Abstraction
• Layering
• Layers and Communications
• Entities and Peers
• Protocol as motivation
• Examples of the architects process
• Internet Philosophy and Tensions
35
Distributing Layers Across Network
• Layers are simple if only on a single machine
– Just stack of modules interacting with those
above/below
source / destination
M application
Ht M transport
Hn Ht M network
Hl Hn Ht M link
physical
37
What Gets Implemented on a Router?
Hn Ht M network
• Bits arrive on wire Hl Hn Ht M link Hn Ht M
router
• Packets must be delivered to next-hop
– Datalink layer necessary
Waist IP
IP
Data Link
Ethernet SONET 802.11 Physical
• Open-source projects
– Which has had more impact, Linux or POSIX?
41
A Multitude of Apps
Problem
Application Skype SSH NFS HTTP
42
Solution: Intermediate
Layers
• Introduce intermediate layers that provide set of abstractions
for various network functionality and technologies
– A new app/media implemented only once
– Variation on “add another level of indirection”
Intermediate
layers
43