Transcript ppt
Computer Networks
Lecture 2: Protocols and the TCP/IP Suite
Prof. Younghee Lee
* Some part of this teaching materials are prepared referencing the
lecture note made by F. Kurose, Keith W. Ross(U. of Massachusetts) and Ion
Stoica(UC Berkely)
Prof. Younghee Lee
1
The need for a Protocol Architecture
Object concept with two constraints
– Layering
» A technique to organize a network system into a succession of logically distinct
entities, such that the service provided by one entity is solely based on the service
provided by the previous (lower level) entity: 1st constraint
» Use abstractions to hide complexity
» Abstraction naturally leads to layering
Different level of abstraction and services
» Can have alternative abstractions at each layer
» Advantages
Good design principle in general
Simple and easy to understand
Easy to modify and/or adapt to new situations/technologies
Allow for different solution for different situations
Vendor competition: => open system ( <=> close system)
Sharing, multiplexing, bypassing
Easy to test & analysis
» Disadvantages
– OSI Open System (7 layer)
» Only Peer to Peer layer communication for protocol entities: 2nd constraint
Prof. Younghee Lee
2
The need for a Protocol Architecture
Protocol
– Service – says what a layer does
– Interface – says how to access the service
– Protocol – says how is the service implemented
» a set of rules and formats that govern the communication between two peers
– Building blocks of a network architecture
– Each protocol object has two different interfaces
» service interface: defines operations on this protocol
» peer-to-peer interface: defines messages exchanged with peer
Key feature
- Syntax
- Semantics
- Timing
– Term Protocol is overloaded
» specification of peer-to-peer interface
» module that implements this interface
Prof. Younghee Lee
3
The OSI Protocol Architecture
Prof. Younghee Lee
4
The OSI Protocol Architecture
Prof. Younghee Lee
5
The TCP/IP Protocol Architecture
Internet Architecture
- Internet Engineering Task Force (IETF)
• Application layer
• Host-to-Host, or
Transport layer
• Internet layer
• Network access
layer
• Physical layer
– Application vs Application Protocol (FTP, HTTP)
– Features
» does not imply strict layering
» hourglass shape
» design and implementation go hand-in-hand
Prof. Younghee Lee
6
Protocol layering and data
Each layer takes data from above
adds header information to create new data unit
passes new data unit to layer below
source
M
Ht M
Hn Ht M
Hl Hn Ht M
application
transport
network
link
physical
destination
application
Ht
transport
Hn Ht
network
Hl Hn Ht
link
physical
Prof. Younghee Lee
M
message
M
segment
M
M
datagram
frame
7
Physical layer
T1/E1
ADSL
Cable Modem
Modem
TDM/FDM/CDM
SONET
WDM
(Optical Internet: Lambda switching, Optical burst
switching, Optical Packet switching)
Prof. Younghee Lee
8
Physical Media
physical link:
transmitted data bit
propagates across link
guided media:
– signals propagate in solid
media: copper, fiber
unguided media:
– signals propagate
freelye.g., radio
Twisted Pair (TP)
two insulated copper
wires
– Category 3: traditional
phone wires, 10 Mbps
ethernet
– Category 5 TP:
100Mbps ethernet
Prof. Younghee Lee
9
Physical Media: coax, fiber
Coaxial cable:
Fiber optic cable:
wire (signal carrier)
within a wire (shield)
– baseband: single
channel on cable
– broadband: multiple
channel on cable
bidirectional
common use in 10Mbs
Ethernet
glass fiber carrying light
pulses
high-speed operation:
– 100Mbps Ethernet
– high-speed point-to-point
transmission (e.g., 5 Gps)
low error rate
Prof. Younghee Lee
10
Physical media: radio
Radio link types:
signal carried in
electromagnetic
spectrum
no physical “wire”
microwave
– e.g. up to 45 Mbps channels
LAN (e.g., waveLAN)
– 2Mbps, 11Mbps
bidirectional
propagation
environment effects:
wide-area (e.g., cellular)
– e.g. CDPD, 10’s Kbps
– reflection
– obstruction by objects
– interference
satellite
– up to 50Mbps channel (or
multiple smaller channels)
– 270 Msec end-end delay
– geosynchronous versus
LEOS
Prof. Younghee Lee
11
Link layer
Point
to point
Multiple access / shared medium
Logical link control
Prof. Younghee Lee
12
Switching
Switch: moves bits between links
– Why do we need switching?
– Packet switching
» Interleave packets from different sources
» Efficient: resources used on demand
Statistical multiplexing
– rather than arbitrarily assigning a time slot to each signal, each
signal is assigned a slot according to priority and need.
– 1 Mbps link; users require 0.1 Mbps when transmitting; users active
only 10% of the time
– Circuit switching: can support 10 users
– Packet switching: with 35 users, probability that >=10 are
transmitting at the same time < 0.0017
» Multiple types of applications
» Accommodates bursty traffic
– Circuit switching
Prof. Younghee Lee
13
The Network Core
mesh of interconnected
routers
the fundamental question:
how is data transferred
through net?
– circuit switching:
dedicated circuit per
call: telephone net
– packet-switching: data
sent thru net in discrete
“chunks”
Prof. Younghee Lee
14
Network Core: Circuit Switching
End-end resources
reserved for “call”
link bandwidth, switch
capacity
dedicated resources:
no sharing
circuit-like (guaranteed)
performance
call setup required
Prof. Younghee Lee
15
Network Core: Circuit Switching
network resources
(e.g., bandwidth)
divided into “pieces”
pieces allocated to calls
resource piece idle if
not used by owning call
(no sharing)
dividing link bandwidth
into “pieces”
– frequency division
– time division
Prof. Younghee Lee
16
Network Core: Packet Switching
resource contention:
each end-end data stream
divided into packets
aggregate resource
demand can exceed
user A, B packets share
amount available
network resources
congestion: packets
each packet uses full link
queue, wait for link use
bandwidth
resources used as needed, store and forward:
packets move one hop
at a time
Bandwidth division into “pieces”
– transmit over link
Dedicated allocation
– wait turn at next link
Resource reservation
Prof. Younghee Lee
17
Network Core: Packet Switching
10 Mbs
Ethernet
A
B
statistical multiplexing
C
1.5 Mbs
queue of packets
waiting for output
link
45 Mbs
D
E
Packet-switching versus circuit switching: analogy
Train, cars on highway
Any other analogies?:
Prof. Younghee Lee
18
Packet-switched networks: routing
Goal: move packets among routers from source to
destination
– we’ll study several path selection algorithms
datagram network:
– destination address determines next hop
– routes may change during session
– analogy: driving, asking directions
virtual circuit network:
– each packet carries tag (virtual circuit ID), tag determines next
hop
– fixed path determined at call setup time, remains fixed thru call
– routers maintain per-call state
Advantages and Disadvantages?
Prof. Younghee Lee
19
Internetworking
Intranet
Subnetwork
End System(ES)
Intermediate System(IS)
Bridge
Router
–
–
–
–
Addressing schemes:
Max. packet size: fragmentation
Interfaces:
Reliability
Prof. Younghee Lee
20
Internetworking: challenges
Many
–
–
–
–
–
differences between networks
Address formats
Performance – bandwidth/latency
Packet size
Loss rate/pattern/handling
Routing
How
to translate between various network
technologies
Prof. Younghee Lee
21
Internetworking
Prof. Younghee Lee
22
Internet structure: network of networks
roughly hierarchical
national/international
backbone providers (NBPs)
– e.g. BBN/GTE, Sprint, AT&T,
IBM, UUNet
– interconnect (peer) with each
other privately, or at public
Network Access Point (NAPs)
regional ISPs
– connect into NBPs
local
ISP
regional ISP
NBP B
NAP
NAP
NBP A
regional ISP
local
ISP
local ISP, company
– connect into regional ISPs
Prof. Younghee Lee
23
Addresses vs. Names
How To Find Nodes?
Humans
use readable host names
–Globally unique (can correspond to multiple hosts)
Naming
system translates to physical address
–E.g. DNS translates name to IP Address (e.g.
128.2.11.43)
–Address reflects location in network
Prof. Younghee Lee
24
Addresses vs. Names
globally
unique
organization
length
location
dependence
Address
Name
Yes
Yes (ideally)
flat,
hierarchical
fixed size
(usually)
Yes
flat,
hierarchical
variable size
No
Prof. Younghee Lee
25
Packet delivery inside the network
Each
network technology has different local
delivery methods
Address resolution provides delivery information
within network
– E.g., ARP maps IP addresses to Ethernet addresses
– Local, works only on a particular network
Routing
protocol provides path through an
internetwork
Prof. Younghee Lee
26
Routing
Forwarding
tables at each router populated by
routing protocols.
Routing protocols update tables based on “cost”
– Exchange tables with neighbors or everyone
– Use neighbor leading to shortest path
Prof. Younghee Lee
27
Applications, end systems
Reliability
– Corruption
– Lost packets
Flow
and congestion control
– Flow control: end system overloaded
– Congestion control: network overloaded
Fragmentation
In-order
delivery
Etc…
Prof. Younghee Lee
28
The TCP/IP Protocol Architecture
Operation of TCP/IP
Prof. Younghee Lee
29
The TCP/IP Protocol Architecture
Internet Standards
– IAB(Internet Architecture Board):
» responsible for the development and publication of the standard. (from RFC)
» the coordinating committee for Internet design, engineering, and management.
– IAB has two principal subsidiary task forces
» IETF(Internet Engineering Task Force)
responsible for publishing the RFCs which are the working notes of the Internet
R&D community.
» IRTF(Internet Research Task Force)
– To be a standard
» Be stable and well-understood.
» Be technically competent.
» Have multiple, independent, and interoperable implementations with substantial
operational experience.
» Enjoy significant public support.
» Be recognizably useful in some or all parts of the Internet.
* Key difference with those of IS: the emphasis on operational experience
Internet draft -> Proposed standard(Min. 6M) -> Draft standard (Min. 4M)
-> Internet standard
Prof. Younghee Lee
30
Comparison of OSI and TCP/IP
OSI
TCP/IP
– Clean, thought out, explicit OO
– Dirty afterthought to
design
already developed
protocol
– Not biased towards any protocol
– Lower layers unspecified
– Good for discussion but bad for
implementation(too many layers,
– Sloppy but practical
options)
– unnecessarily complex
– mature and well tested at a time
when similar OSI protocols were
in the development stage
– Esperanto
– Pascal
– Mackintosh
– English
– C
– MSDOS
Prof. Younghee Lee
31
A closer look at network structure:
network edge:
applications and hosts
network core:
– routers
– network of networks
access networks,
physical media:
communication links
Prof. Younghee Lee
32
The network edge:
end systems (hosts):
– run application programs
– e.g., WWW, email
– at “edge of network”
client/server model
– client host requests, receives
service from server
– e.g., WWW client (browser)/
server; email client/server
peer-peer model:
– host interaction symmetric
– e.g.: teleconferencing
Prof. Younghee Lee
33
Network edge: connection-oriented service
Goal: data transfer between end
systems with control for certain
purpose such as reliable transfer
etc.,
handshaking: setup (prepare for)
data transfer ahead of time
– Hello, hello back human protocol
– set up “state” in two
communicating hosts
In case of Telecommunication
network service, network node has
connection management function
reliable, in-order bytestream data transfer
– loss: acknowledgements
and retransmissions
flow control:
– sender won’t overwhelm
receiver
TCP - Transmission Control
Protocol
– Internet’s connection-oriented
service
TCP service [RFC 793]
congestion control:
– senders “slow down
sending rate” when
network congested
– Why? Pros and Cons?
Prof. Younghee Lee
34
Network edge: connectionless service
Goal: data transfer
between end systems
– same as before!
App’s using TCP:
UDP - User Datagram
Protocol [RFC 768]:
Internet’s connectionless
service
– unreliable data transfer
– no flow control
– no congestion control
HTTP (WWW), FTP (file
transfer), Telnet
(remote login), SMTP
(email)
App’s using UDP:
streaming media,
teleconferencing,
Internet telephony
Prof. Younghee Lee
35
Access networks and physical media
Q: How to connection end
systems to edge router?
residential access nets
institutional access
networks (school,
company)
mobile access networks
Keep in mind:
bandwidth (bits per
second) of access
network?
shared or dedicated?
Prof. Younghee Lee
36
Residential access: point to point access
Dialup via modem
– up to 56Kbps direct access to
router (conceptually)
ISDN: intergrated services digital
network: 128Kbps all-digital connect
to router
ADSL: asymmetric digital subscriber
line
– up to 1 Mbps home-to-router
– up to 8 Mbps router-to-home
– ADSL deployment: UPDATE THIS
Prof. Younghee Lee
37
Residential access: cable modems
HFC: hybrid fiber coax
– asymmetric: up to 10Mbps
upstream, 1 Mbps
downstream
network of cable and fiber
attaches homes to ISP
router
– shared access to router
among home
– issues: congestion,
dimensioning
deployment: available via
cable companies, e.g.,
MediaOne
Prof. Younghee Lee
38
Institutional access: local area networks
company/univ local area
network (LAN) connects end
system to edge router
Ethernet:
– shared or dedicated
cable connects end
system and router
– 10 Mbs, 100Mbps,
Gigabit Ethernet
deployment: institutions,
home LANs soon
LANs: chapter 5
Prof. Younghee Lee
39
Wireless access networks
shared wireless access
network connects end
system to router
wireless LANs:
– radio spectrum replaces
wire
– e.g., Lucent Wavelan 10
Mbps
router
base
station
wider-area wireless
access
– CDPD: wireless access to
ISP router via cellular
network
Prof. Younghee Lee
mobile
hosts
40
Delay in packet-switched networks
packets experience delay
on end-to-end path
four sources of delay
at each hop
transmission
A
nodal processing:
– check bit errors
– determine output link
queueing
– time waiting at output
link for transmission
– depends on congestion
level of router
propagation
B
nodal
processing
queueing
Prof. Younghee Lee
41
Delay in packet-switched networks
Transmission delay:
R=link bandwidth (bps)
L=packet length (bits)
time to send bits into
link = L/R
Propagation delay:
d = length of physical
link
s = propagation speed in
medium (~2x108 m/sec)
propagation delay = d/s
Note: s and R are very different
quantitites!
transmission
A
propagation
B
nodal
processing
queueing
http://wps.aw.com/aw_kurose_network_
2/0,7240,227091-,00.html
Prof. Younghee Lee
42
Queueing delay
R=link bandwidth (bps)
L=packet length (bits)
a=average packet
arrival rate
traffic intensity = La/R
La/R ~ 0: average queueing delay small
La/R -> 1: delays become large
La/R > 1: more “work” arriving than can be
serviced, average delay infinite!
http://wps.aw.com/aw_kurose_network_2/0,724
0,227091-,00.html
Prof. Younghee Lee
43