ee 586 communication and switching networks (fall...
TRANSCRIPT
1-1
EE 586 Com
munication and
Switching Networks (Fall 2010)
Lecture 24
Octob
er 25, 2010
Announcem
ents
�Midterm
1:
�Mean = 92.2
�Stdev
= 8
�Still grad
ing your program
s (sorry about
the delay)
Network Layer
4-2
1-3
Router Architecture Overview
Two key router functions:
�run routing algorithms/protocol
�forw
arding datagramsfrom
incoming to outgoing link
Linksys Broadband
Wireless Router
$59.99
Cisco 12816
Terab
it Router
$210,000
1-4
Three types of switching fabrics
1-5
Switching Via M
emory
First generation routers:
�traditional com
puters with switching under direct
control of CPU
�packet copied to system
’s mem
ory
�speed limited
by mem
ory bandwidth (2 bus
crossings per datagram)
Input
Port
Output
Port
Mem
ory
System Bus
1-6
Switching Via a Bus
�datagram from input port mem
ory
to output port mem
ory via a shared
bus
�bus contention:
switching speed
limited
by bus bandwidth
�32 Gbps bus, Cisco 5600: sufficient
speed for access and enterprise
routers
1-7
Switching Via An
Interconnection Network
�overcome bus bandwidth limitations
�Cross-bar consisting of 2n buses connected
n input ports to n output ports
�ad
vanced
design: fragm
enting datagram
into fixed
length cells, switch cells through
the fabric.
�Cisco 12000: sw
itches 60 Gbps through the
interconnection netw
ork
1-8
Output Ports
�Buffering
required
when datagramsarrive from
fabric faster than the transm
ission rate
�Expensive–input rate = switching rate >> line rate
�Sched
uling disciplinechooses am
ong queued
datagramsfor transm
ission
�First-In First-O
ut
�Weigh
ted Q
ueuing based
on flow
label (more later)
1-9
Output port queueing
�buffering when arrival rate via sw
itch exceed
s output line speed
�queueing (de
lay) and
loss due to output port
buffer overflow!
1-10
Input Port Functions
Dece
ntra
lized switch
ing:
�given datagram dest., lookup output port
using forw
arding table in input port
mem
ory
�goal: complete input port processing at
‘line speed
’�
queuing: if datagrams arrive faster than
forw
arding rate into sw
itch fabric
Physical layer:
bit-level reception
Data link layer:
e.g., Ethernet
see chapter 5
1-11
Input Port Q
ueuing
�Fabric slow
er than input ports com
bined
-> queueing
may occur at input queues
�Head-of-the-Line (HOL) blocking:
queued
datagram
at front of queue prevents others in queue from
moving forw
ard -> loss of efficiency
�queueing
delay and loss due to input bu
ffer overflow!
Network Layer
4-12
The Internet Network layer
forw
arding
table
Host, router netw
ork layer functions:
Routing protocols
•path selection
•RIP, O
SPF
, BGP
IP protocol
•addressing conventions
•datagram format
•packet handling conventions
ICMP protocol
•error reporting
•router “signaling”
Transport layer: TCP, UDP
Link layer
physical layer
Network
layer
Network Layer
4-13
IPv4 datagram format
ver
length
32 bits
data
(variable length,
typically a TCP
or UDP segm
ent)
16-bit id
entifier
header
checksum
time to
live 32 bit source IP address
IP protocol version
number
header length
(bytes)
max num
ber
remaining hops
(decremented at
each router)
for
fragmentation/
reassembly
total datagram
length (bytes)
upper layer protocol
to deliver payload to
head.
len
type of
service
“type” of data
flgs
fragment
offset
upper
layer
32 bit destination IP address
Options (if any)
E.g. timestamp,
record route
taken, specify
list of routers
to visit.
how
much overhead
with TCP?
�20 bytes of TCP
�20 bytes of IP
�= 40 bytes + app
layer overhead
Network Layer
4-14
IP Fragm
entation & Reassem
bly
(IPv4 only)
�netw
ork links have MTU
(max.transfer size) -largest
possible link-level frame.
�different link types,
different M
TUs
�large IP datagram divided
(“fragmented”) within net
�one datagram becom
es
several d
atagrams
�“reassem
bled” only at final
destination
�IP header bits used
to
identify, order related
fragments
fragmentation:
in:one large datagram
out:3 smaller datagrams
reassembly
Network Layer
4-15
IP Fragm
entation and
Reassem
bly
ID =xoffset
=0fragflag
=0length
=4000
ID =xoffset
=0fragflag
=1length
=1500
ID =xoffset
=185
fragflag
=1length
=1500
ID =xoffset
=370
fragflag
=0length
=1040
One large datagram becom
esseveral smaller datagrams
Exam
ple
�4000 byte
datagram
�MTU = 1500 bytes
1480 bytes in
data field
offset =
1480/8
(always in 8-
byte chunk)
Network Layer
4-16
IP Addressing: introduction
�IP address:32-bit
identifier for host,
router interface
�interface:
connection
between host/router
and physical link
�router’s typically have
multiple interfaces
�host typically has one
interface
�IP addresses
associated
with each
interface
223.
1.1.
1
223.
1.1.
2
223.
1.1.
3223.
1.1.
422
3.1.
2.9
223.
1.2.
2
223.
1.2.
1
223.
1.3.
222
3.1.
3.1
223.
1.3.
27
223.
1.1.
1 =
110
1111
1 00
0000
01 0
0000
001
0000
0001
223
11
1
Network Layer
4-17
Sub
nets
�IP address:
�subnet part (high
order bits)
�host part (low order
bits)
�What’s a subn
et ?
�device interfaces with
same subnet part of IP
address
�can ph
ysically reach
each other without
intervening router
223.
1.1.
1
223.
1.1.
2
223.
1.1.
3223.
1.1.
422
3.1.
2.9
223.
1.2.
2
223.
1.2.
1
223.
1.3.
222
3.1.
3.1
223.
1.3.
27
netw
ork consisting of 3 sub
nets
subnet
Network Layer
4-18
Sub
nets
223.
1.1.
0/24
223.
1.2.
0/24
223.
1.3.
0/24
Recipe
�To determine the
subnets, d
etach each
interface from
its
host or router,
creating islands of
isolated
networks.
Each isolated network
is called a sub
net.
Sub
net mask: /24
Network Layer
4-19
Sub
nets
How
many?
223.
1.1.
1
223.
1.1.
3
223.
1.1.
4
223.
1.2.
222
3.1.
2.1
223.
1.2.
6
223.
1.3.
222
3.1.
3.1
223.
1.3.
27
223.
1.1.
2
223.
1.7.
0
223.
1.7.
122
3.1.
8.0
223.
1.8.
1
223.
1.9.
1
223.
1.9.
2
Network Layer
4-20
IP addressing: CID
R
CID
R:Classless InterDom
ain Routing
�subnet portion of address of arbitrary length
�address format: a.b.c.d/x, where x is # bits in
subnet portion of address
1100
1000
000
1011
100
0100
00 0
0000
000
subnet
part
host
part
200.23.16.0/2
3
Network Layer
4-21
IP addresses: how
to get one?
Q:How
does a ho
stget IP address?
�hard-cod
ed by system
admin in a file
�Window
s: control-panel->netw
ork->configuration->tcp/ip-
>properties
�UNIX
: /etc/rc.config
�DHCP:
Dynam
ic Host Configuration Protocol: dynam
ically get address
from
as server
�“plug-and-play”
Q:How
does an ISP get block of addresses?
A:IC
ANN: Internet Corporation for Assigned
Nam
es and
Num
bers
�allocates addresses
�manages DNS
�assigns dom
ain names, resolves disputes
Network Layer
4-22
DHCP: Dynam
ic Host Configuration Protocol
Goal:allow host to dynam
ically obtain its IP address
from
network server when it joins netw
ork
�Can renew
its lease on address in use
�Allows reuse of addresses (only hold address while
connected an “on”)
�Support for mob
ile users who want to join netw
ork (m
ore
shortly)
Beside an IP address, the client may also request:
•address of first-hop router for client
•name and IP address of DNS sever
•netw
ork mask (ind
icating netw
ork versus host
portion of address)
Network Layer
4-23
DHCP client-server scenario
223.
1.1.
1
223.
1.1.
2
223.
1.1.
3223.
1.1.
422
3.1.
2.9
223.
1.2.
2223.
1.2.
1
223.
1.3.
222
3.1.
3.1
223.
1.3.
27
A B
E
DH
CP
se
rver
arriv
ing
DH
CP
cl
ient
need
sad
dres
s in
this
netw
ork
Network Layer
4-24
DHCP: exam
ple
�connecting laptop needs its
IP address, addr of first-
hop router, addr of DNS
server: use DHCP
router
(runs DHCP)
DH
CP
UD
PIP Eth
Phy
DH
CP
DH
CP
DH
CP
DH
CP
DH
CP
DH
CP
UD
PIP Eth
Phy
DH
CP
DH
CP
DH
CP
DH
CP
DH
CP
�DHCP request encapsulated
in UDP, encapsulated in IP,
encapsulated
in 802.1
Ethernet
�Ethernet fram
e broadcast
(dest: FFFFFFFFFFFF) on LAN,
received
at router running
DHCP server
�Ethernet dem
ux’ed to IP
dem
ux’ed, UDP dem
ux’ed to
DHCP
168.
1.1.
1