Computer Networks Chapter 1 - Fundamentals CEN 5501C - Computer - - PowerPoint PPT Presentation

computer networks
SMART_READER_LITE
LIVE PREVIEW

Computer Networks Chapter 1 - Fundamentals CEN 5501C - Computer - - PowerPoint PPT Presentation

Computer Networks Chapter 1 - Fundamentals CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 1 Computer Networks Need to share Information Resources Communication vs. Storage Transmission across: Space


slide-1
SLIDE 1

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 1

Computer Networks

Chapter 1 - Fundamentals

slide-2
SLIDE 2

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 2

Computer Networks

  • Need to share

– Information – Resources

  • Communication vs. Storage

Transmission across: – Space (communication) – Time (storage)

slide-3
SLIDE 3

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 3

Virtuality

  • Architecture

– Layered – Hierarchical

  • Algorithms

– Information hiding, ADTs, objects

  • Protocols

– Distributed coordination algorithms

  • Programs

– Modularity

slide-4
SLIDE 4

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 4

Layered vs. Hierarchical

  • Both

– Peer-to-peer communication – Encapsulation – Protocol = common language/behaviors

  • Layered

– Layer i serves layer i+1 ONLY – Layer i gets service from layer i-1 ONLY

  • Hierarchical

– Lower layers serve higher layers

slide-5
SLIDE 5

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 5

Layered vs. Hierarchical

  • Issues

– Flexibility – Efficiency – Modularity – Maintainability – Scalability/manageability – Future adaptability

slide-6
SLIDE 6

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 6

Comparative Architectures

7 - Application 6 - Presentation 5 - Session 4 - Transport 3 - Network 2 – Data Link 1 - Physical User Application Data Link Control DDCMP Physical 1 - Physical Path Control Transmission Ctl Data Flow Control Transport Functional Management Data Services Network Services Protocol Network Application ISO - OSI IBM - SNA DEC - DECnet

slide-7
SLIDE 7

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 7

OSI Reference Architecture

  • Physical (L1 = PHY)
  • Data Link (L2 = MAC/Link)
  • Network (L3)
  • Transport (L4)
  • Session (L5)
  • Presentation (L6)
  • Application (L7)
slide-8
SLIDE 8

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 8

PHY Layer

  • Hardware
  • Physical manipulation of medium

(modulation)

  • Physical sensing of medium (detection)
  • Low level synchronization

(bits/symbols/frames)

  • Forward error correction/error detection
  • Mechanical/electrical interconnect and

medium

slide-9
SLIDE 9

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 9

Link Layer

  • Firmware
  • Framing
  • Addressing
  • Medium access control (MAC)
  • Backward error detection/correction
  • Reliable delivery of frames from one STA

to a directly connected STA

  • Pacing
  • Upward multiplexing
slide-10
SLIDE 10

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 10

Network Layer

  • Software/firmware
  • Packets/cells
  • Routing
  • Packet fragmentation/reassembly
  • Backward error correction
  • Delivery of frames from source to an

indirectly connected destination

  • Congestion control
slide-11
SLIDE 11

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 11

Transport Layer

  • Software on end host: End-to-end layer
  • Reliable communication stream

– Messages – Byte stream – Ordering – BEC

  • Upward Multiplexing
  • Delivery of messages/byte stream from

source process to destination process

  • Congestion control
slide-12
SLIDE 12

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 12

Session Layer

  • Software on end host: end-to-end layer
  • Stream management
  • Dialog control
  • Packet chaining (atomic delivery)
  • Downward Multiplexing
  • Authentication
  • Connection-oriented
slide-13
SLIDE 13

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 13

Presentation Layer

  • Software on end host
  • Common utilities

– Encryption – Compression – Uniform formatting (XML, ASN.1,…)

  • Standardized representations
  • Interfacing to local resources
slide-14
SLIDE 14

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 14

Application Layer

  • Software on end host
  • Specific application programs

– FTP – Remote terminal (rlogin, telnet, ssh,…) – Email – HTTP

  • May also be layered in distributed software

system

slide-15
SLIDE 15

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 15

Encapsulation

application transport network link physical application transport network link physical source destination

M M M M Ht Ht Hn Ht Hn Hl M M M M Ht Ht Hn Ht Hn Hl message segment datagram frame

(thanks – Kurose & Ross)

  • Receive SDU from higher layer
  • Hide uninterpreted SDU as payload of PDU
slide-16
SLIDE 16

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 16

End-to-end Data Transport

(thanks – Kurose & Ross)

slide-17
SLIDE 17

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 17

Service Models

  • Interface

– Connectionless – Connection-oriented

  • Reliability

– Best effort – Reliable

  • Combinations
slide-18
SLIDE 18

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 18

Service Interface

  • Interface

– Connectionless: memoryless

  • Send packet
  • Receive packet

– Connection-oriented: stateful

  • Initialize (set up connection)
  • Use (send/receive)
  • Close (release state)
slide-19
SLIDE 19

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 19

Service Reliability

  • Reliability

– Best effort

  • Lost packets
  • Duplicate packets
  • Delayed/reordered delivery
  • Damaged packets

– Reliable

  • Undamaged packets
  • All packets sent delivered in timely fashion
  • Delivered in order sent
slide-20
SLIDE 20

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 20

Message Conventions

1-REQ 2,3 2 - Tx 3 - Rx 4 - IND 5 - RSP 8 - CNF 6 - Tx 7 - Rx 6,7 Request/Confirm Indication/Response

slide-21
SLIDE 21

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 21

Combining Service Models

Best Effort Reliable Connectionless Connection-Oriented UDP, IP, IPX, CLNP, DECnet, Appletalk, CLNS,… ATM TCP, X.25, CONS ???

slide-22
SLIDE 22

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 22

Network Service vs. Implementation

Service Implementation Connectionless Connection-Oriented UDP, CLNS TCP, DNA ??? Connectionless Connection-Oriented X.25, ATM, CONS, SNA

slide-23
SLIDE 23

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 23

Network Properties

  • Scope
  • Scalability
  • Robustness
  • Autoconfigurability
  • Tweakability
  • Determinism
  • Migration
slide-24
SLIDE 24

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 24

Network Properties - Robustness

  • Types of Errors

– Link/node failure – Data errors (esp. undetected!) – S/W errors – H/W errors – Human Errors

  • Features
slide-25
SLIDE 25

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 25

Network Properties - Robustness

  • Types of Errors
  • Features

– Safety Barriers – Self-stabilization – Fault detection – Byzantine robustness

slide-26
SLIDE 26

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 26

Reliable Data Transfer

  • Models

– Errors – Receiver capacity

  • Requirements

– Duplexity – Timers – State

slide-27
SLIDE 27

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 27

Data Transfer Model

  • Events

– What can happen at node, channel

  • Frames

– What do they hold

  • Duplexity

– Simplex, half duplex, full duplex

  • Time costs

– What does it take to complete transfer

  • Metrics

– How do we measure the costs

slide-28
SLIDE 28

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 28

Data Transfer - Events

  • Node

– New frame to send from HLE – Frame/ACK arrival – good frame – Frame/ACK arrival – damaged frame – Timeout – Attempt to receive next frame by HLE

  • Channel

– Error – damage frame – Error – lose frame

slide-29
SLIDE 29

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 29

Data Transfer - Frames

  • Forward Control Info

– Type – Sequence number – Timestamp – Length – Addressing – Error Detection (FCS)

  • Reverse Control Info

– ACKs – Flow control/pacing – Piggybacking

  • Information

– payload

Dst Src Type SN TS Len … Payload FCS

slide-30
SLIDE 30

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 30

Channel Model - Duplexity

  • Simplex – only one way
  • Half duplex – one way at a time
  • Full duplex – simultaneously both ways

A B A B A B Simplex Half Duplex Full Duplex

slide-31
SLIDE 31

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 31

Data Transfer - Delays

  • Processing

– Source – Destination

  • Transmission

– Time to put bits on wire

  • Propagation

– Time for bit to traverse channel

Src Dest Src Proc Transmission Propagation Propagation Src Proc Dest Proc D a t a f r a m e ACK frame ACK Tx Tx REQ Rx REQ Rx CNF Tx CNF

slide-32
SLIDE 32

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 32

Data Transfer - Metrics

  • Utilization

– Time sending info/total time

  • Storage requirements

– At source – At destination

  • Channel type

– duplexity

  • Timers

– Retransmission – ACK transmission

slide-33
SLIDE 33

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 33

Reliable Data Xfer - Utopia

  • Infinitely fast receiver
  • Simplex channel
  • No errors
  • 100% utilization by

protocol

Src Dest

slide-34
SLIDE 34

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 34

Stop&Wait Data Xfer - Pacing

  • Finitely fast receiver
  • Half duplex channel
  • No errors
  • <100% utilization by

protocol

– UProtocol = TTx/Tcycle – TTx= L (bits)/R (bps) – Tcycle = TTx+Tprop+Tproc+ Tprop+Tproc

Src Dest OK OK Data time Cycle time

slide-35
SLIDE 35

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 35

Reliable Data Xfer – PAR (Positive ACK and Retransmit)

  • Finitely fast receiver
  • Full duplex channel
  • Channel errors
  • Utilization factor due to

errors

– Uerrors = Tgood/ Tgood+ Tbad

  • U = Uprotocol x Uerrors

Src Dest ACK

  • *

ACK

  • X
slide-36
SLIDE 36

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 36

Reliable Data Xfer – PAR need for sequence numbers

Src Dest ACK

  • *

ACK

  • X

Src Dest ACK

  • *

ACK

  • X

First Frame Second Frame Second Frame - duplicate Missing ACK Missing ACK ACK Frame 1 Frame 2 Frame 2 - duplicate Missing ACK

slide-37
SLIDE 37

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 37

Reliable Data Xfer – 1-bit ARQ

Src Dest ACK 1

  • *

ACK 0

  • X

Src Dest ACK 1

  • *

ACK 0

  • X

Frame 0 Frame 1 Frame 1 Missing ACK Missing ACK Frame 0 Frame 1 Frame 1 Missing ACK ACK 0 accept accept accept accept discard duplicate

slide-38
SLIDE 38

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 38

Protocol Utilization – 1-bit ARQ

  • Protocol util.

Uproto= T/(T+2τ) T = Tx time = D/R D = size (bits/frame) R = data rate (bps) τ = propagation delay

  • Uproto= 1/(1+2α)

α = τ /T = τ /(D/R)

τ

Src Dest ACK 1 Frame 0 T

τ

ACK 0 Frame 1 Cycle Time

slide-39
SLIDE 39

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 39

Protocol Utilization – 1-bit ARQ

1-bit ARQ Efficiency

0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.25 0.5 1 2 4 8 16 32 64 Normalized delay Efficiency

slide-40
SLIDE 40

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 40

Reliable Data Xfer – GBN ARQ

Src Dest

*

  • D 0

D 1 ACK 1 Missing D3 Accept D0 D 2 D 3 (resent) D 4 D 5 ACK 2 ACK 3 ACK 3 ACK 3 Discard D4 Discard D5 D 4 D 5 ACK 6 ACK 5 Accept D1 Accept D2 Accept D3 Accept D4 Accept D5 ACK 4

  • Multiple sequence #’s
  • Channel errors
  • Discard out of order

frames on Rx

  • Resend all frames

from missing on forward

  • Rx buffer size of 1
  • Tx buffer size of N
slide-41
SLIDE 41

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 41

Reliable Data Xfer – SR ARQ

Src Dest

*

  • Missing D3

D 0 D 1 ACK 1 Accept D0 D 2 D 3 (resent) D 4 D 5 ACK 2 ACK 3 ACK 3 ACK 3 Buffer D4 Buffer D5 D 6 D 7 ACK 8 ACK 7 Accept D1 Accept D2 Accept D3 Accept D6 Accept D7 ACK 6

  • Multiple sequence #’s
  • Channel errors
  • Buffer out of order

frames on Rx

  • Resend only missing

frame

  • Rx buffer size of N
  • Tx buffer size of k
slide-42
SLIDE 42

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 42

Protocol Utilization – ARQ

Src Dest kT data T cycle

  • Protocol util.

depends on k Uproto= kT/(T+2τ) T = Tx time = D/R τ = propagation delay

  • Uproto= min(1,k/(1+2α))

α = τ /T = τ /(D/R)

  • Utilization factor

due to errors different for GBN and SR

τ τ

T

slide-43
SLIDE 43

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 43

Protocol Utilization –ARQ

ARQ Protocol Efficiency

0.2 0.4 0.6 0.8 1 1.2 0.25 0.5 1 2 4 8 16 32 64 a = normalized delay efficiency k=1 k=2 k=3 k=5 k=9 k=17

slide-44
SLIDE 44

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 44

Error Utilization Factor

  • SR-ARQ

Only resend missing frames Uerr,SR= 1-p p = frame error prob

  • GBN-ARQ

Send all frames after missing frame Uerr,GBN=(1-p)/(1+2αp) when k>1+2α Uerr,GBN=(1-p)/(1-p+kp) when k<1+2α Depends on k

slide-45
SLIDE 45

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 45

Error Utilization Factor

Efficiency Loss due to Errors

0.2 0.4 0.6 0.8 1 1.2 0.1 0.2 0.3 0.4 0.5 0.6 0.7 0.8 0.9 1 Frame Error Rate p Efficiency GBN k=1 GBN k=2 GBN k=4 GBN k=8 GBN k=16 GBN k=32

(large a)

slide-46
SLIDE 46

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 46

Overall ARQ Utilization

  • SR-ARQ

USR= min{(1-p),k(1-p)/(1+2α)}

  • GBN-ARQ

UGBN= (1-p)/(1+2αp) when k>1+2α UGBN= k(1-p)/(1+2α)(1-p+kp) when k<1+2α

slide-47
SLIDE 47

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 47

Overall Utilization

ARQ Efficiency, p=0.001

0.2 0.4 0.6 0.8 1 1.2 . 2 5 . 5 1 2 4 8 1 6 3 2 6 4 1 2 8 2 5 6 5 1 2 1 2 4 Normalized delay (a) Efficiency both k=1 GBN k=9 GBN k=65 GBN k=129 SR k=9 SR k=65 SR k=129

slide-48
SLIDE 48

CEN 5501C - Computer Networks - Spring 2007 - UF/CISE - Newman 48

Sequence Numbers

  • Sequence numbers are finite (usually)

Assume n bits

  • Hence, they wrap around

i.e., 0 follows 2n-1

  • Need to use circular “<“ relation

i.e., 0 > 2n-1

  • Need to limit range usable by sender and

acceptable to receiver (SW and RW)

|SW| + |RW| <= 2n

1 2 2n-1 2n-1-1 2n-1 2n-1+1