0% found this document useful (0 votes)
5 views

Chapter_6_The Data Link Layer_2

Chapter 5 discusses the Data Link Layer's purpose and services, including framing, error detection, and multiple access protocols. It covers MAC addressing, ARP operations, and how data is encapsulated for transmission between nodes. The chapter also explains various MAC protocols, including contention-based and controlled access technologies.

Uploaded by

ann karagwa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views

Chapter_6_The Data Link Layer_2

Chapter 5 discusses the Data Link Layer's purpose and services, including framing, error detection, and multiple access protocols. It covers MAC addressing, ARP operations, and how data is encapsulated for transmission between nodes. The chapter also explains various MAC protocols, including contention-based and controlled access technologies.

Uploaded by

ann karagwa
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 73

Chapter 5

DATA Link
Layer
Computer
Networking: A
Top Down
Approach
6th edition
Jim Kurose, Keith
Ross
Addison-Wesley
March 2012

Link Layer 5-1


Purpose of the Data Link Layer

Data Link Layer


Link layer services
❖ Framing, link access:
▪ link-layer protocol defines the format of the
packets exchanged between nodes at end of
the link
▪ encapsulates datagram into frame, adding
header, trailer
▪ defines how to access channel for shared
medium
▪ Defines the “MAC” addresses to identify
source, dest
• different from IP address!

Link Layer 5-3


Link layer services
Link layer services
MAC Sublayer (cont.)
Data encapsulation
❖ Frame assembly before transmission and
frame disassembly upon reception of a
frame.
❖ MAC layer adds a header and trailer to the
packet
❖ Provides three primary functions:
▪ Frame delimiting – Identifies a group of bits that
comprise a frame, synchronization
▪ Addressing –adds a physical address (MAC
address) that enables a frame to be delivered to
a destination node.
▪ Error detection –adds a trailer with a cyclic
redundancy check (CRC) of the frame contents.
Framing
Link layer services
❖ flow control:
▪ nodes on each side of a link have a limited amount of
packet buffering capacity
▪ pacing between adjacent sending and receiving nodes
❖ error detection:
▪ errors caused by signal attenuation, noise.
▪ receiver detects presence of errors:
• signals sender for retransmission or drops frame
❖ error correction:
▪ receiver identifies and corrects bit error(s) without
resorting to retransmission
❖ half-duplex and full-duplex
▪ with half duplex, nodes at both ends of link can
transmit, but not at same time

Link Layer 5-8


Types of Errors
An error occurs Single bit
Error
when a bit is
altered
between Burst Error – 2 or more bits
transmission changed
and reception
• Binary 1 is
transmitted and
binary 0 is
received
• Binary 0 is
transmitted and
binary 1 is
5-9
Error Detection Process

Data Link Layer 5-10


two-dimensional bit parity:
Example: Parity checking ❖ detect and correct single bit
errors

A parity bit is
added to every
data unit so that
the total number
of 1s is even (or
odd for odd-
parity).

single bit parity:


❖detect single bit
errors
Two-dimensional bit
TO Read, Internet Checksum and
CRC
parity
❖Detect up to 3 bit errors
❖101011
❖101010
❖110110
❖010111

Data Link Layer 5-12


Link layer, LANs: outline
5.1 introduction, 5.5 link virtualization:
services MPLS
5.2 error detection, 5.6 data center
correction networking
5.3 multiple access 5.7 a day in the life
protocols of a web request
5.4 LANs
▪ addressing, ARP
▪ Ethernet
▪ switches
▪ VLANS

Link Layer 5-13


Multiple access links,
protocols
two types of “links”:
❖ point-to-point
▪ PPP for dial-up access
▪ point-to-point link between Ethernet switch, host
❖ broadcast (shared wire or medium)
▪ Older Ethernet
▪ upstream Hybrid fiber-coaxial (HFC)
▪ 802.11 wireless LAN

shared wire (e.g., shared RF shared humans at a


cabled Ethernet) (e.g., 802.11 WiFi) RF cocktail party
(satellite) (shared air,
acoustical)
Link Layer 5-14
Multiple Access problem
Issues with broadcast (shared wire or
medium)
❖ two or more simultaneous transmissions by
nodes: interference
▪ collision if node receives two or more signals
at the same time

multiple access protocol


❖ distributed algorithm that determines how nodes
share channel, i.e., determine when node can
transmit

5-15
MAC Protocols

Round Reservation/ Contention


channel • All stations
robin partitioning contend for
time
• Each • Divide medium
• Good for
station into slots
bursty traffic
• Good for
given turn stream traffic • Simple to
to implement
• Tends to
transmit collapse under
data heavy load
Channel partitioning MAC protocols
TDMA: time division multiple access
❖ each station gets fixed length slot
❖ unused slots go idle

6-slot 6-slot
frame frame
1 3 4 1 3 4

FDMA: frequency time


division multiple
frequency bands
access
❖ channel spectrum
divided into frequency
bands
❖ each station assigned
fixed frequency band
Channel partitioning MAC
protocols
F/
TDMA
2G Cellular
Networks

CDMA: Code division multiple access


Transmissions are combined on the same channel at the
same time but are separated by codes

3G Cellular
Networks

Data Link Layer 5-18


Random Access Protocols

Characteristics Contention-Based Technologies


• Stations can transmit at • CSMA/CD for 802.3 Ethernet
any time networks
• Collision exist • CSMA/CA for 802.11 wireless
• How to detect collisions networks
• how to recover from collisions • ALOHA
(e.g., via delayed
retransmissions)
• There are mechanisms to
resolve contention for the
media
CSMA/CD
3.
2. 4.
If the If a collision
1. After
medium is is detected,
transmitting
If the busy, transmit a
the jamming
medium is continue brief
signal, wait
jamming
idle, to listen signal to
a random
transmit; until the amount of
assure that
time,
otherwise, channel is all stations
referred to
go to step idle, then know that
as the
2 transmit there has
backoff, then
been a
immediate collision and
attempt to
ly transmit
cease
again
transmission
“Taking turns” MAC
protocols

Characteristics Controlled Access Technologies

• Only one station can transmit at a


time
• Token Ring (IEEE
• Devices wanting to transmit must 802.5)
wait their turn
• No collisions
• FDDI
• May use a token passing method
“Taking turns” MAC
protocols
channel partitioning MAC protocols:
▪ share channel efficiently and fairly at
high load
▪ inefficient at low load: delay in channel
access, 1/N bandwidth allocated even if
only 1 active node!
random access MAC protocols
▪ efficient at low load: single node can
fully utilize channel
▪ high load: collision overhead
“taking turns” protocols
look for best of both worlds!
Link Layer 5-22
“Taking turns” MAC
protocols
polling:
❖ master node
“invites” slave data
nodes to transmit pol
in turn l

❖ typically used with maste


“dumb” slave data r
devices
❖ concerns:
▪ polling
overhead slave
s
▪ latency
▪ single point of
failure (master)
Link Layer 5-23
“Taking turns” MAC
protocols
token passing:
T
❖ control token
passed from one
node to next
sequentially.
(nothing
❖ token message to send)
❖ concerns: T
▪ token overhead
▪ latency
▪ single point of
failure (token)

data
Link Layer 5-24
Link layer, LANs: outline
5.1 introduction, 5.5 link virtualization:
services MPLS
5.2 error detection, 5.6 data center
correction networking
5.3 multiple access 5.7 a day in the life
protocols of a web request
5.4 LANs
▪ addressing, ARP
▪ Ethernet
▪ switches
▪ VLANS

Link Layer 5-25


MAC addresses and ARP
❖ MAC (or LAN or physical or Ethernet)
address:
▪ function: used ‘locally” to get frame from one
interface to another physically-connected
interface (same network, in IP-addressing
sense)
▪ 48 bit MAC address (for most LANs) burned in
NIC ROM, also sometimes software settable
▪ e.g.: 1A-2F-BB-76-09-AD
hexadecimal (base 16) notation
(each “number” represents 4 bits)

Link Layer 5-26


LAN addresses and ARP
each adapter on LAN has unique LAN
address
1A-2F-BB-76-09-
AD

LAN
(wired or adapter
wireless)
71-65-F7-2B-08-
53 58-23-D7-FA-20-B0

0C-C4-11-6F-E3-98

Link Layer 5-27


ARP: address resolution
protocol
Question: how to determine
interface’s MAC address,
knowing its IP address? ARP table: each IP node
(host, router) on LAN
has table
137.196.7.7
8 ▪ IP/MAC address
1A-2F-BB-76-09-
AD
mappings for some
137.196.7.2
3 137.196.7.1 LAN nodes:
4 < IP address; MAC
address; TTL>
LAN
71-65-F7-2B-08-
▪ TTL (Time To Live):
53 58-23-D7-FA-20-B0 time after which
address mapping
0C-C4-11-6F-E3-98 will be forgotten
137.196.7.8
8
(typically 20 min)
Link Layer 5-28
arp table – arp -a

Data Link Layer 5-29


ARP Operation
ARP Operation (cont.)
ARP Operation (cont.)
ARP Operation (cont.)
ARP Operation (cont.)
Addressing: routing to another
LAN
walkthrough: send datagram from A to B
via R
▪ focus on addressing – at IP (datagram) and MAC
layer (frame)
▪ assume A knows B’s IP address
▪ assume A knows IP address of first hop router, R
(how?)
▪ assume A knows R’s MAC address (how?)
A B
R
111.111.111.111
222.222.222.22
74-29-9C-E8-FF-
29-BD-D2-C7-56-
4
55
222.222.222.22 2A
1A-23-F9-CD-06-
0
9B
111.111.111.112 111.111.111.110 222.222.222.22
CC-49-DE-D0-AB- E6-E9-00-17-BB- 88-B2-2F-54-1A-
1
7D 4B 0F

Link Layer 5-35


Addressing: routing to another
LAN
❖A creates IP datagram with IP source A, destination B
❖ A creates link-layer frame with R's MAC address as dest,
frame contains A-to-B IP datagram
MAC src: 74-29-9C-E8-FF-55
MAC dest: E6-E9-00-17-BB-
4B IP src: 111.111.111.111
IP dest:
222.222.222.222
IP
Eth
Phy

A B
R
111.111.111.111
222.222.222.22
74-29-9C-E8-FF-
29-BD-D2-C7-56-
4
55
222.222.222.22 2A
1A-23-F9-CD-06-
0
9B
111.111.111.112 111.111.111.110 222.222.222.22
CC-49-DE-D0-AB- E6-E9-00-17-BB- 88-B2-2F-54-1A-
1
7D 4B 0F

Link Layer 5-36


Addressing: routing to another
LAN
❖frame sent from A to R
❖ frame received at R, datagram removed, passed up to
IP
MAC src: 74-29-9C-E8-FF-55
MAC dest: E6-E9-00-17-BB-
IP src: 111.111.111.111
4B IP dest:
IP src: 111.111.111.111
IP dest: 222.222.222.222
222.222.222.222
IP IP
Eth Eth
Phy Phy

A B
R
111.111.111.111
222.222.222.22
74-29-9C-E8-FF-
29-BD-D2-C7-56-
4
55
222.222.222.22 2A
1A-23-F9-CD-06-
0
9B
111.111.111.112 111.111.111.110 222.222.222.22
CC-49-DE-D0-AB- E6-E9-00-17-BB- 88-B2-2F-54-1A-
1
7D 4B 0F

Link Layer 5-37


Addressing: routing to another
LAN
❖R forwards datagram with IP source A, destination B
❖ R creates link-layer frame with B's MAC address as dest,
frame contains A-to-B IP datagram

MAC src: 1A-23-F9-CD-06-9B


MAC dest: 49-BD-D2-C7-56-
2A IP src: 111.111.111.111
IP dest:
222.222.222.222 IP
IP Eth
Eth Phy
Phy

A B
R
111.111.111.111
222.222.222.22
74-29-9C-E8-FF-
29-BD-D2-C7-56-
4
55
222.222.222.22 2A
1A-23-F9-CD-06-
0
9B
111.111.111.112 111.111.111.110 222.222.222.22
CC-49-DE-D0-AB- E6-E9-00-17-BB- 88-B2-2F-54-1A-
1
7D 4B 0F

Link Layer 5-38


Addressing: routing to another
LAN
❖R forwards datagram with IP source A, destination B
❖ R creates link-layer frame with B's MAC address as dest,
frame contains A-to-B IP datagram
MAC src: 1A-23-F9-CD-06-9B
MAC dest: 49-BD-D2-C7-56-
2A IP src: 111.111.111.111
IP dest:
222.222.222.222
IP
Eth
Phy

A B
R
111.111.111.111
222.222.222.22
74-29-9C-E8-FF-
29-BD-D2-C7-56-
4
55
222.222.222.22 2A
1A-23-F9-CD-06-
0
9B
111.111.111.112 111.111.111.110 222.222.222.22
CC-49-DE-D0-AB- E6-E9-00-17-BB- 88-B2-2F-54-1A-
1
7D 4B 0F

Link Layer 5-39


MAC and IP
MAC Address
❖ This address does not change
❖ Similar to the name of a person
❖ Known as physical address because
physically assigned to the host NIC
IP Address
❖ Similar to the address of a person
❖ Based on where the host is actually
located
❖ Known as a logical address because
assigned logically
❖ Assigned to each host by a network
End-to-End Connectivity,
MAC, and IP
IP Packet Encapsulated in an Ethernet
Frame
Link layer, LANs: outline
5.1 introduction, 5.7 a day in the life
services of a web request
5.2 error detection,
correction
5.3 multiple access
protocols
5.4 LANs
▪ addressing, ARP
▪ Ethernet
▪ switches
▪ VLANS

Link Layer 5-42


LLC and MAC Sublayers
Ethernet
▪ One of the most widely used LAN technologies
▪ Operates in the data link layer and the
physical layer
▪ Family of networking technologies defined in
the IEEE 802.2 and 802.3 standards
▪ Supports data bandwidths of 10, 100, 1000,
10,000, 40,000, and 100,000 Mb/s (100 Gb/s)
Ethernet Standards
▪ Define Layer 2 protocols and Layer 1
technologies
▪ Two separate sub layers of the data link layer
to operate – Logical Link Control (LLC) and the
MAC sublayers
LLC and MAC Sublayers (cont.)
Ethernet Frame

Preamble and Length/Type Data and Pad


Start Frame Field – Fields –
Delimiter Fields – Defines the exact Contains the
Used for length of the encapsulated
synchronization frame’s data field; data from a
between the describes which higher layer; an
sending and protocol is IPv4 packet.
receiving devices. implemented.
802.3 Ethernet standards: link & physical
layers
❖ many different Ethernet standards
▪ they have common MAC protocol and frame
format
▪ different speeds: 2 Mbps, 10 Mbps, 100
Mbps, 1Gbps, 10G bps
▪ different physical layer media: fiber, cable

MAC protocol
application and frame format
transport
network 100BASE-TX 100BASE-T2 100BASE-FX
link 100BASE-T4 100BASE-SX 100BASE-BX
physical

copper (twister fiber physical layer


pair) physical layer
Link Layer 5-46
Link layer, LANs: outline
5.1 introduction, 5.7 a day in the life
services of a web request
5.2 error detection,
correction
5.3 multiple access
protocols
5.4 LANs
▪ addressing, ARP
▪ Ethernet
▪ switches
▪ VLANS

Link Layer 5-47


Ethernet switch
❖ It’s a link-layer device: takes an active
role
▪ store, forward Ethernet frames
▪ Performs switching and filtering based
only on the MAC address
▪ Builds a MAC address table that it uses
to make forwarding decisions
▪ Depends on routers to pass data
between IP subnetworks
❖ transparent
▪ hosts are unaware of presence of
switches
❖ plug-and-play, self-learning
▪ switches do not need to be configuredLink Layer 5-48
Switch: multiple simultaneous
transmissions
❖ hosts have dedicated, A
direct connection to
switch C’ B
❖ switches buffer packets
6 1 2
❖ Ethernet protocol used on
each incoming link, but 5 4 3
no collisions; full duplex
▪ each link is its own B’ C
collision domain
❖ switching: A-to-A’ and B- A’
to-B’ can transmit switch with six interfaces
simultaneously, without (1,2,3,4,5,6)
collisions

Link Layer 5-49


Switch forwarding table
A
Q: how does switch know
A’ reachable via interface C’ B
4, B’ reachable via
❖ A: each switch has a 6 1 2
interface 5?
switch table, each 5 4 3
entry: B’ C
▪ (MAC address of host,
interface to reach host,
A’
time stamp)
Q:▪how are entries
looks like a routing table!
switch with six interfaces
created, maintained in (1,2,3,4,5,6)
switch table?
▪ something like a routing
protocol? Link Layer 5-50
Switch: self-learning Source: A
Dest: A’

A A A’
❖ switch learns which
hosts can be reached B
C’
through which
interfaces 1
6 2
▪ when frame
received, switch 5 4 3
“learns” location
of sender: B’ C
incoming LAN
segment
A’
▪ records
sender/locationMAC addr interface TTL
pair in switch table Switch table
A 1 60
(initially empty)

Link Layer 5-51


Switch: frame
filtering/forwarding
when frame received at switch:

1. record incoming link, MAC address of sending


host
2. index switch table using MAC destination
address
3. if entry found for destination
then {
if destination on segment from which frame
arrived
then drop frame
else forward frame on interface indicated
by entry
}
else flood /* forward on all interfaces except
Link Layer 5-52
Self-learning, forwarding: Source: A
example Dest: A’

A A A’
❖ frame destination,
B
A’, locaton flo C’

unknown:
❖ destination A od 6 1 2

locationselectively
known: A A’
5 4 3
send B’ C
on just one link A’ A

A’

MAC addr interface TTL


A 1 60 switch table
A’ 4 60 (initially empty)

Link Layer 5-53


Interconnecting switches
❖ switches can be connected together
S4

S1
S3
A S2
F
D I
B C
G H
E

Q: sending from A to G - how does S1 know


to forward frame destined to F via S4 and
S 3?
❖ A: self learning! (works exactly the same
as in single-switch case!) Link Layer 5-54
Self-learning multi-switch
example
Suppose C sends frame to I, I responds to C

S4

S1
S3
A S2
F
D I
B C
G H
E

❖ Q: show switch tables and packet forwarding in


S1, S 2 , S 3, S 4

Link Layer 5-55


Institutional network
mail server
to external
network
router web server

IP subnet

Link Layer 5-56


Switches vs.
routers application
transport
both are store-and-
datagram network
forward: frame link
▪ routers: network-layer physical frame
link
devices (examine physical
network-layer
headers) switch
▪ switches: link-layer
devices (examine link- network datagram
layer headers) link frame
physical
both have forwarding application
tables: transport
▪ routers: compute network
tables using routing link
algorithms, IP physical
addresses
▪ switches: learn Link Layer 5-57
VLANs: motivation
consider:
❖ CS user moves office
to EE, but wants
connect to CS switch?
❖ single broadcast
domain:
▪ all layer-2
Computer
broadcast traffic
Science Electrical
Computer
Engineering
(ARP, DHCP,
Engineering unknown location
of destination MAC
address) must
cross entire LAN
▪ security/privacy,
efficiency issues
Link Layer 5-58
port-based VLAN: switch ports
VLANs grouped (by switch
management software) so
that single physical switch
Virtual Local …… 1 7 9 15
Area Network 2 8 10 16

switch(es) supporting
VLAN capabilities can … …
be configured to Electrical Computer
define multiple virtual Engineering
(VLAN ports 1-8)
Science
(VLAN ports 9-15)
LANS over single … operates as multiple virtual
physical LAN switches
infrastructure. 1 7 9 15
2 8 10 16

… …

Electrical Computer
Engineering Science
(VLAN ports 1-8) (VLAN ports 9-16)
Link Layer 5-59
Port-based VLAN
router
❖ traffic isolation: frames
to/from ports 1-8 can
only reach ports 1-8
▪ can also define VLAN based
on MAC addresses of
endpoints, rather than 1 7 9 15

switch port 2 8 10 16

❖ dynamic membership:
ports can be … …
dynamically assigned Electrical Computer
among VLANs Engineering
(VLAN ports 1-8)
Science
(VLAN ports 9-15)
❖ forwarding between VLANS:
done via routing (just as with
separate switches)
▪ in practice vendors sell
combined switches plus routers

Link Layer 5-60


VLANS spanning multiple
switches
1 7 9 15 1 3 5 7

2 8 10 16 2 4 6 8

… …

Electrical Computer Ports 2,3,5 belong to EE VLAN


Engineering Science Ports 4,6,7,8 belong to CS
(VLAN ports 1-8) (VLAN ports 9-15) VLAN

❖ trunk port: carries frames between VLANS defined


over multiple physical switches
▪ frames forwarded within VLAN between switches can’t be
vanilla 802.1 frames (must carry VLAN ID info)
▪ 802.1q protocol adds/removed additional header fields
for frames forwarded between trunk ports

Link Layer 5-61


802.1Q VLAN frame format
type

preamble dest. source data (payload) CRC


address address 802.1 frame

type

dest. source
preamble
address address
data (payload) CRC 802.1Q frame

2-byte Tag Protocol Identifier Recomputed


(value: 81-00) CRC

Tag Control Information (12 bit VLAN ID field,


3 bit priority field like IP TOS)

Link Layer 5-62


Link layer, LANs: outline
5.1 introduction, 5.7 a day in the life
services of a web request
5.2 error detection,
correction
5.3 multiple access
protocols
5.4 LANs
▪ addressing, ARP
▪ Ethernet
▪ switches
▪ VLANS

Link Layer 5-63


Synthesis: a day in the life of a web
request
❖ journey down protocol stack complete!
▪ application, transport, network, link
❖ putting-it-all-together: synthesis!
▪ goal: identify, review, understand protocols
(at all layers) involved in seemingly simple
scenario: requesting www page
▪ scenario: student attaches laptop to campus
network, requests/receives www.google.com

Link Layer 5-64


A day in the life: scenario

browse DNS server


r
Comcast network
68.80.0.0/13

school network
68.80.2.0/24

web
page

web server Google’s network


64.233.169.105 64.233.160.0/19

Link Layer 5-65


A day in the life… connecting to the
Internet
DHCP DHC ❖ connecting laptop
P
DHCP
DHCP UDP
needs to get its own IP
DHCP IP address, addr of first-
Eth hop router, addr of
Phy
DHCP DNS server: use DHCP
❖ DHCP request
encapsulated in UDP,
DHC
DHCP
DHCP P
encapsulated in IP,
DHCP UDP encapsulated in 802.3
DHCP IP router Ethernet
Eth (runs DHCP) ❖ Ethernet frame
Phy broadcast (dest:
FFFFFFFFFFFF) on LAN,
received at router
running DHCP
❖ Ethernet server
demuxed to
IP demuxed, UDP
demuxed to DHCP
Link Layer 5-66
A day in the life… connecting to the
Internet
DHCP DHC ❖ DHCP server
DHCP P formulates DHCP ACK
DHCP UDP containing client’s IP
DHCP IP address, IP address of
Eth first-hop router for
Phy client, name & IP
address of DNS
❖ encapsulation atserver
DHCP DHC DHCP server, frame
DHCP P forwarded (switch
DHCP UDP learning) through
DHCP IP router LAN, demultiplexing
(runs DHCP)
DHCP
Eth at client
❖ DHCP client receives
Phy
DHCP ACK reply

Client now has IP address, knows name &


addr of DNS
server, IP address of its first-hop router
Link Layer 5-67
A day in the life… ARP (before DNS,
before HTTP)
DNS DNS ❖ before sending HTTP
DNS UDP request, need IP address of
DNS
ARP
IP www.google.com: DNS
ARP query Eth
Phy ❖ DNS query created,
encapsulated in UDP,
encapsulated in IP,
ARP
encapsulated in Eth. To
ARP reply Eth
Phy send frame to router, need
router ❖ MAC
ARP address of router
query broadcast,
(runs DHCP)
interface: ARP
received by router, which
replies with ARP reply
giving MAC address of
❖ router interface
client now knows MAC
address of first hop router,
so can now send frame
containing DNS query
Link Layer 5-68
A day in the life… using DNSDNS
DNS UDP DNS server
DNS IP
DNS DNS DNS Eth
DNS UDP DNS Phy
DNS IP
DNS Eth
Phy
DNS
Comcast network
68.80.0.0/13

router
❖ IP datagram forwarded
(runs DHCP) from campus network into
❖ IP datagram containing comcast network, routed
DNS query forwarded (tables created by RIP,
via LAN switch from OSPF, IS-IS and/or BGP
client to 1st hop router routing protocols)
❖ demux’ed to DNS to DNS
server
server
❖ DNS server replies to
client with IP address
Link Layer 5-69
of www.google.com
A day in the life…TCP connection
carrying HTTP
HTTP
HTTP
SYNACK
SYN TCP
SYNACK
SYN IP
SYNACK
SYN Eth
Phy

❖ to send HTTP request,


client first opens TCP
socket to web server
router ❖ TCP SYN segment (step 1
(runs DHCP)
SYNACK
SYN TCP in 3-way handshake)
SYNACK
SYN IP inter-domain routed to
SYNACK
SYN Eth web server
Phy ❖ web server responds
with TCP SYNACK (step 2
web server in 3-way handshake)
64.233.169.105 ❖ TCP connection
established!
Link Layer 5-70
A day in the life… HTTP
request/reply
HTTP
HTTP HTTP ❖ web page finally (!!!)
HTTP
HTTP TCP displayed
HTTP
HTTP IP
HTTP
HTTP Eth
Phy

❖ HTTP request sent into


TCP socket
router ❖ IP datagram containing
HTTP (runs DHCP)
HTTP
HTTP TCP
HTTP request routed to
HTTP IP www.google.com
HTTP Eth ❖ web server responds
Phy with HTTP reply
(containing web page)
web server
❖ IP datagram containing
64.233.169.105
HTTP reply routed back to
client
Link Layer 5-71
Chapter 5: Summary
❖ principles behind data link layer
services:
▪ error detection, correction
▪ sharing a broadcast channel: multiple access
▪ link layer addressing
❖ instantiation and implementation of
various link layer technologies
▪ Ethernet
▪ switched LANS, VLANs
▪ virtualized networks as a link layer: MPLS
❖ synthesis: a day in the life of a web
request

Link Layer 5-72


Chapter 5: let’s take a
breath
❖ journey down protocol stack complete
(except PHY)
❖ solid understanding of networking
principles, practice
❖ ….. could stop here …. but lots of
interesting topics!
▪ wireless
▪ multimedia
▪ security
▪ network management

Link Layer 5-73

You might also like