Download as pptx, pdf, or txt
Download as pptx, pdf, or txt
You are on page 1of 32

Alternative core: circuit switching

end-end resources allocated to,


reserved for “call” between
source & dest:
• in diagram, each link has four circuits.
• call gets 2nd circuit in top link and
1st circuit in right link.
• dedicated resources: no sharing
• circuit-like (guaranteed)
performance
• circuit segment idle if not used by call
(no sharing)
• commonly used in traditional In above scenario, each link between adjacent switches has a
telephone networks transmission rate of 1 Mbps, then each end-to-end circuit-switch
connection gets 250 kbps of dedicated transmission rate.
Circuit switching: FDM and TDM
Frequency Division Multiplexing
(FDM) 4 users

frequency
• optical, electromagnetic frequencies
divided into (narrow) frequency bands

 each call allocated its own band, can


time
transmit at max rate of that narrow
band
Time Division Multiplexing (TDM)

frequency
 time divided into slots
 each call allocated periodic slot(s),
can transmit at maximum rate of time
(wider) frequency band (only) during
its time slot(s)
For FDM, the frequency domain is segmented For TDM, the time domain is segmented into frames, with four
into four bands, each of bandwidth 4 kHz. time slots in each frame; each circuit is assigned the same
dedicated slot in the revolving TDM frames

For TDM, the transmission rate of a circuit is equal to the


frame rate multiplied by the number of bits in a slot.

For example, if the link transmits 8,000 frames per


second and each slot consists of 8 bits, then the
transmission rate of each circuit is 64 kbps.
Send a file of 640,000 bits from Host A to Host B over a circuit-switched network.

All links in the network use TDM with 24 slots and have a bit rate of 1.536 Mbps.

The time required to establish an end-to-end circuit before Host A can begin to transmit the file is 500 msec.

How long does it take to send the file?


Each circuit has a transmission rate of (1.536 Mbps)/24=64 kbps,
so it takes (640,000 bits)/(64 kbps)=10 seconds to transmit the file.

To this 10 seconds we add the circuit establishment time, giving 10.5 seconds to send
the file.

Note that the transmission time is independent of the number of links: The transmission time
would be 10 seconds if the end-to-end circuit passed through one link or a hundred links.
How do packet delay and loss occur?
• packets queue in router buffers, waiting for turn for transmission
 queue length grows when arrival rate to link (temporarily) exceeds output link
capacity
 packet loss occurs when memory to hold queued packets fills up
packet being transmitted (transmission delay)

B
packets in buffers (queueing delay)
free (available) buffers: arriving packets
dropped (loss) if no free buffers
The time required to examine the packet’s header and
Packet delay: four sources determine where to direct the packet is part of the
processing delay
transmission
A propagation

B
nodal
processing queueing

dnodal = dproc + dqueue + dtrans + dprop

dproc: nodal processing dqueue: queueing delay


 check bit errors  time waiting at output link for
 determine output link transmission
 typically < microsecs  depends on congestion level of
router
The transmission delay is L/R.
Packet delay: four sources This is the amount of time required to push (that is,
transmit) all of the packet’s bits into the link
transmission
A propagation

B
nodal
processing queueing

dnodal = dproc + dqueue + dtrans + dprop


dtrans: transmission delay: dprop: propagation delay:
 L: packet length (bits)  d: length of physical link
 R: link transmission rate (bps)  s: propagation speed (~2x108 m/sec)
 dtrans = L/R  dprop = d/s
dtrans and dprop
very different
Caravan analogy
100 km 100 km

ten-car caravan toll booth toll booth toll booth


(aka 10-bit packet) (aka link)

 car ~ bit; caravan ~ packet; toll  time to “push” entire caravan


service ~ link transmission through toll booth onto
 toll booth takes 12 sec to service highway = 12*10 = 120 sec
car (bit transmission time)  time for last car to propagate
 “propagate” at 100 km/hr from 1st to 2nd toll both:
100km/(100km/hr) = 1 hr
 Q: How long until caravan is lined
up before 2nd toll booth?  A: 62 minutes
Caravan analogy
100 km 100 km

ten-car caravan toll booth toll booth


(aka 10-bit packet) (aka router)

 suppose cars now “propagate” at 1000 km/hr


 and suppose toll booth now takes one min to service a car
 Q: Will cars arrive to 2nd booth before all cars serviced at first booth?
A: Yes! after 7 min, first car arrives at second booth; three cars still at
first booth
Packet queueing delay (revisited)
 a: average packet arrival rate

average queueing delay


 L: packet length (bits)
 R: link bandwidth (bit transmission rate)

L .a arrival rate of bits “traffic


:
R service rate of bits intensity” traffic intensity = La/R 1

 La/R ~ 0: avg. queueing delay small La/R ~ 0

 La/R -> 1: avg. queueing delay large


 La/R > 1: more “work” arriving is
more than can be serviced - average
delay infinite!
La/R -> 1
Packet loss
 queue (aka buffer) preceding link in buffer has finite capacity
 packet arriving to full queue dropped (aka lost)
 lost packet may be retransmitted by previous node, by source end
system, or not at all
buffer
(waiting area) packet being transmitted
A

B
packet arriving to
full buffer is lost
Throughput
 throughput: rate (bits/time unit) at which bits are being sent from
sender to receiver
• instantaneous: rate at given point in time
• average: rate over longer period of time

link capacity
pipe that can carry linkthat
pipe capacity
can carry
serverserver,
sends with
bits Rsfluid at rate
bits/sec Rfluid
c
at rate
bits/sec
(fluid)
fileinto
of Fpipe
bits (Rs bits/sec) (Rc bits/sec)
to send to client
Throughput
Rs < Rc What is average end-end throughput?

Rs bits/sec Rc bits/sec

Rs > Rc What is average end-end throughput?

Rs bits/sec Rc bits/sec

bottleneck link
link on end-end path that constrains end-end throughput
Throughput: network scenario
 per-connection end-end
Rs throughput:
Rs Rs min(Rc,Rs,R/10)
 in practice: Rc or Rs is
R
often bottleneck
Rc Rc
Rc

10 connections (fairly) share


backbone bottleneck link R bits/sec
Protocol “layers”
Networks are complex,
with many “pieces”:
 hosts Question:
 routers is there any hope of organizing
 links of various structure of network?
media
 applications …. or at least our discussion of
 protocols networks?
 hardware,
software
Organization of air travel

ticket (purchase) ticket (complain)

baggage (check) baggage (claim)

gates (load) gates (unload)

runway takeoff runway landing

airplane routing airplane routing


airplane routing

• a series of steps
Layering of airline functionality

ticket (purchase) ticket (complain) ticket

baggage (check) baggage (claim baggage

gates (load) gates (unload) gate

runway (takeoff) runway (land) takeoff/landing

airplane routing airplane routing airplane routing airplane routing airplane routing

departure intermediate air-traffic arrival


airport control centers airport

layers: each layer implements a service


 via its own internal-layer actions
 relying on services provided by layer below
Why layering?
dealing with complex systems:
• explicit structure allows identification, relationship
of complex system’s pieces
• layered reference model for discussion
• modularization eases maintenance, updating of
system
• change of implementation of layer’s service transparent
to rest of system
• e.g., change in gate procedure doesn’t affect rest of
system
• layering considered harmful?
Internet protocol stack
• application: supporting network
applications
• FTP, SMTP, HTTP application
• transport: process-process data
transfer transport
• TCP, UDP
• network: routing of datagrams from network
source to destination
• IP, routing protocols link
• link: data transfer between
neighboring network elements physical
• Ethernet, 802.111 (WiFi), PPP
• physical: bits “on the wire”
Services, Layering and Encapsulation
M
Application exchanges messages to implement some
application application service using services of transport layer application
Ht M
transport Transport-layer protocol transfers M (e.g., reliably) from transport
one process to another, using services of network layer

network  transport-layer protocol encapsulates network


application-layer message, M, with
transport layer-layer header Ht to create a link
link
transport-layer segment
• Ht used by transport layer protocol to
physical implement its service physical

source destination
Services, Layering and Encapsulation
M

application application
Ht M
transport Transport-layer protocol transfers M (e.g., reliably) from transport
one process to another, using services of network layer
Hn Ht M
network Network-layer protocol transfers transport-layer segment
network
[Ht | M] from one host to another, using link layer services
link  network-layer protocol encapsulates link
transport-layer segment [Ht | M] with
physical network layer-layer header Hn to create a physical
network-layer datagram
source • Hn used by network layer protocol to destination
implement its service
Introduction: 1-21
Services, Layering and Encapsulation
M

application application
Ht M
transport transport
Hn Ht M
network Network-layer protocol transfers transport-layer segment
network
[Ht | M] from one host to another, using link layer services
Hl Hn Ht
link M
link
Link-layer protocol transfers datagram [Hn| [Ht |M] from
host to neighboring host, using network-layer services
physical  link-layer protocol encapsulates network physical
datagram [Hn| [Ht |M], with link-layer header
source Hl to create a link-layer frame destination

Introduction: 1-22
Encapsulation
Matryoshka dolls (stacking dolls)

message segment datagram frame

Introduction: 1-23
Credit: https://dribbble.com/shots/7182188-Babushka-Boi
Services, Layering and Encapsulation

message M
application M application

segment Ht M
transport Ht M
transport
datagram Hn Ht M Hn Ht M
network network

frame Hl Hn Ht M Hl Hn Ht M
link link

physical physical

source destination

Introduction: 1-24
ISO/OSI reference model
• presentation: allow applications
to interpret meaning of data, application
e.g., encryption, compression,
presentation
machine-specific conventions
• session: synchronization, session
checkpointing, recovery of data transport
exchange network
• Internet stack “missing” these link
layers!
• these services, if needed, must be physical
implemented in application
• needed?
message M
source
application
Encapsulation: an
segment
datagram Hn Ht
Htt M
M
transport
network
end-end view
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
Introduction: 1-26
message M
source
application
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
Network security
• Field of network security:
• how bad guys can attack computer networks
• how we can defend networks against attacks
• how to design architectures that are immune to attacks
• Internet not originally designed with (much)
security in mind
• original vision: “a group of mutually trusting users
attached to a transparent network” 
• security considerations in all layers!
Bad guys: put malware into hosts via Internet
• malware can get in host from:
• virus: self-replicating infection by receiving/executing
object (e.g., e-mail attachment)
• worm: self-replicating infection by passively receiving
object that gets itself executed
• spyware malware can record keystrokes, web sites
visited, files deletion, upload info to collection site
• , installing spyware which collects private
information, such as passwords
• infected host can be enrolled in botnet, used for
spam. DDoS attacks
Bad guys: attack server, network infrastructure
Denial of Service (DoS): attackers make resources (server,
bandwidth) unavailable to legitimate traffic by
overwhelming resource with bogus traffic

1. select target
2. break into hosts around the
network (see botnet)
3. send packets to target from
compromised hosts
target
Bad guys can sniff packets
packet “sniffing”:
• broadcast media (shared ethernet, wireless)
• promiscuous network interface reads/records all packets (e.g.,
including passwords!) passing by

A C

src:B dest:A payload


B
 wireshark software used for end-of-chapter labs is a
(free) packet-sniffer
Bad guys can use fake addresses

IP spoofing: send packet with false source address


A C

src:B dest:A payload

… lots more on security (throughout, Chapter 8)


Introduction 1-32

You might also like