CS计算机代考程序代写 2.Intro_Networks2

2.Intro_Networks2

1. Introduction: roadmap
1.1 what is the Internet?
1.2 network edge

§ end systems, access networks, links
1.3 network core

§ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history

1

Self study

2

Quiz: Circuit Switching
Consider a circuit-switched network with N=100 users where each
user is independently active with probability p=0.2 and when active,
sends data at a rate of R=1Mbps. How much capacity must the
network be provisioned with to guarantee service to all users?

A. 100 Mbps

B. 20 Mbps

C. 200 Mbps

D. 50 Mbps

E. 500 Mbps

Open a browser and type: www.zeetings.com/salil

Answer: A

3

Quiz: Statistical Multiplexing
Consider a packet-switched network with N=100 users where each
user is independently active with probability p=0.2 and when active,
sends data at a rate of R=1Mbps. What is the expected aggregate
traffic sent by all the users?

A. 100 Mbps

B. 20 Mbps

C. 200 Mbps

D. 50 Mbps

E. 500 Mbps

Open a browser and type: www.zeetings.com/salil

Answer: B

4

Quiz: Delays
Consider a network connecting hosts A and B through two routers
R1 and R2 like this: A——-R1———-R2———B. Does whether a
packet sent by A destined to B experiences queuing at R1 depend
on the length of the link R1-R2?

A. Yes, it does

B. No, it doesn’t

Open a browser and type: www.zeetings.com/salil

R2R1A B

Answer: B

Three (networking) design steps

v Break down the problem into tasks

v Organize these tasks

v Decide who does what

5

Tasks in Networking
v What does it take to send packets across?

v Prepare data (Application)
v Ensure that packets get to the dst process (Transport)
v Deliver packets across global network (Network)
v Delivery packets within local network to next hop

(Datalink)
v Bits / Packets on wire (Physical)

This is decomposition…
Now, how do we organize these tasks?
Let us have an example

6

Dear John,

Your days are numbered.

–Grace

Inspiration…
v CEO A writes letter to CEO B

§ Folds letter and gives it to Executive Assistant (EA)
» EA:

» Puts letter in envelope with CEO
B’s full name

» Takes to FedEx

v FedEx Office
§ Puts letter in larger envelope
§ Puts name and street address on FedEx envelope
§ Puts package on FedEx delivery truck

v FedEx delivers to other company

7

CEO

EA

FedEx

CEO

EA

FedEx
Location

Fedex Envelope (FE)

The Path of the Letter

Letter

Envelope

Semantic Content

Identity

“Peers” on each side understand the same things
No one else needs to (abstraction)

Lowest level has most packaging

8

The Path Through FedEx

Truck

Sorting
Office

Airport

FE

Sorting
Office

Airport

Truck

Sorting
Office

Airport

Crate Crate

FE

New
Crate

Crate

FE

Higher “Stack”
at Ends

Partial “Stack”
During Transit

Deepest Packaging (Envelope+FE+Crate)
at the Lowest Level of Transport 9

In the context of the Internet

Applications

…built on…

…built on…

…built on…

…built on…

Reliable (or unreliable) transport

Best-effort global packet delivery

Best-effort local packet delivery

Physical transfer of bits
10

Internet protocol stack
v application: supporting network

applications
§ FTP, SMTP, HTTP, Skype, ..

v transport: process-process data
transfer
§ TCP, UDP

v network: routing of datagrams
from source to destination
§ IP, routing protocols

v link: data transfer between
neighboring network elements
§ Ethernet, 802.111 (WiFi), PPP

v physical: bits “on the wire”
11

Three Observations
v Each layer:

§ Depends on layer below
§ Supports layer above
§ Independent of others

v Multiple versions in layer
§ Interfaces differ somewhat
§ Components pick which lower-level

protocol to use

v But only one IP layer
§ Unifying protocol

12

13

An Example: No Layering

v No layering: each new application has to be re-
implemented for every network technology !

ssh HTTP

WirelessEther-
net

Fiber
optic

Application

Transmission
Media

Skype

An Example: Benefit of Layering

v Introducing an intermediate layer provides a common
abstraction for various network technologies

Skypessh HTTP

WirelessEthernet Fiber
optic

Application

Transmission
Media

Transport
& Network

14

v Layer N may duplicate lower-level functionality
§ E.g., error recovery to retransmit lost data

v Information hiding may hurt performance
§ E.g., packet loss due to corruption vs. congestion

v Headers start to get large
§ E.g., typically, TCP + IP + Ethernet headers add up to

54 bytes
v Layer violations when the gains too great to resist

§ E.g., NAT
v Layer violations when network doesn’t trust ends

§ E.g., Firewalls

Is Layering Harmful?

15

Distributing Layers Across Network

v Layers are simple if only on a single machine
§ Just stack of modules interacting with those

above/below

v But we need to implement layers across machines
§ Hosts
§ Routers
§ Switches

v What gets implemented where?

16

What Gets Implemented on Host?

v Hosts have applications that generate
data/messages that are eventually put out on
wire

v At receiver host bits arrive on wire, must
make it up to application

v Therefore, all layers must exist at host!

17

What Gets Implemented on Router?

v Bits arrive on wire
§ Physical layer necessary

v Packets must be delivered to next-hop
§ datalink layer necessary

v Routers participate in global delivery
§ Network layer necessary

v Routers don’t support reliable delivery
§ Transport layer (and above) not supported

18

19

Internet Layered Architecture

HTTP

TCP

IP

Ethernet
interface

HTTP

TCP

IP

Ethernet
interface

IP IP

Ethernet
interface

Ethernet
interface

SONET
interface

SONET
interface

host host

router router

HTTP message

TCP segment

IP packet IP packetIP packet

19

Logical Communication

v Layers interacts with peer’s corresponding layer

Transport
Network
Datalink
Physical

Transport
Network
Datalink
Physical

Network
Datalink
Physical

Application Application

Host A Host BRouter
20

Physical Communication
v Communication goes down to physical network
v Then from network peer to peer
v Then up to relevant layer

Transport
Network
Datalink
Physical

Transport
Network
Datalink
Physical

Network
Datalink
Physical

Application Application

Host A Host BRouter
21

source
application
transport
network
link

physical

HtHn M

segment Ht
datagram

destination
application
transport
network
link

physical
HtHnHl M
HtHn M

Ht M

M

network
link

physical

link
physical

HtHnHl M

HtHn M

HtHn M

HtHnHl M

router

switch

Encapsulation
message M

Ht M

Hn
frame

22

source
application
transport
network
link

physical

HtHn M

segment Ht
datagram

destination
application
transport
network
link

physical
HtHnHl M

HtHn M

Ht M

M

network
link

physical

link
physical

HtHnHl M

HtHn M

HtHn M

HtHnHl M

router

switch

Encapsulation
message M

Ht M

Hn
frame

21

23

Quiz: Layering
What are two benefits of using a layered network model ? (Choose
two)

A. It makes it easy to introduce new protocols

B. It speeds up packet delivery

C. It allows us to have many different packet headers

D. It prevents technology in one layer from affecting other layers

E. It creates many acronyms

F. It reminds me of cake

Open a browser and type: www.zeetings.com/salil

Answer: A + D

1. Introduction: roadmap
1.1 what is the Internet?
1.2 network edge

§ end systems, access networks, links
1.3 network core

§ packet switching, circuit switching, network structure
1.4 delay, loss, throughput in networks
1.5 protocol layers, service models
1.6 networks under attack: security
1.7 history

24

Self study