Service time evaluation for network protocols and routers Computer - - PowerPoint PPT Presentation

service time evaluation for network protocols and routers
SMART_READER_LITE
LIVE PREVIEW

Service time evaluation for network protocols and routers Computer - - PowerPoint PPT Presentation

Service time evaluation for network protocols and routers Computer Networking Communication relies on a protocol stack with n layers. Layer k of an host: - communicates with layer k of remote hosts - exploits the service provided by layer k-1 -


slide-1
SLIDE 1

Service time evaluation for network protocols and routers

slide-2
SLIDE 2

Computer Networking

Communication relies on a protocol stack with n layers. Layer k of an host:

  • communicates with layer k of remote hosts
  • exploits the service provided by layer k-1
  • provides a service to layer k+1.

Layer k Layer k -1 Layer k+1 Layer k Layer k -1 Layer k+1

slide-3
SLIDE 3

A Protocol Data Unit (PDU) refers to information that is delivered as a single unit among layers.

  • Layer k-1 of sender host adds an header to data received from the layer k
  • A PDU of Layer k-1 becomes the payload for Layer k
  • Layer k of the receiver host removes the header from data received from Layer k-1

Layer k-1 data area (payload) Layer k-1 header

Protocol Data Units (PDUs)

Layer k data area (payload) Layer k header

Layer k-1 PDU Layer k PDU

slide-4
SLIDE 4

TCP/IP Protocol Stratification

IP UDP TELNET HTTP FTP TCP

NFS

DNS SNMP

data link layer network layer transport layer RPC

slide-5
SLIDE 5

Datagram IP Forwarding

The router holds a routing table used to find the next destination (router or host) to which the datagram is forwarded Host A Host B

TCP IP Data link layer TCP IP Data link layer IP Data link layer

Router

slide-6
SLIDE 6

NETWORK PROTOCOLS

Protocol PDU name Max size Header Max data area TCP

Segment 65535 20 65515

UDP

Datagram 65535 8 65527

IPv4

Datagram 65535 20 65515

IPv6

Datagram 65535 40 65495

ATM

Cell 53 5 48

Ethernet

Frame 1518 18 1500

Ieee 802.3

Frame 1518 21 1497

Ieee 802.5 TR

Frame 4472 28 4444

FDDI

Frame 4500 28 4472

slide-7
SLIDE 7

TCP

  • TCP provides a service: connection
  • riented, reliable, end-to-end, with

flow control. It delivers data in the same sending order, without losses.

  • TCP implements a connection

reliable mechanism called three- way handshake

  • 3 segments are required to establish

a connection

  • 4 segments are required to end it in

both directions Host A Host B

syn syn ack data data fin ack data fin ack

slide-8
SLIDE 8

IP

IP defines the format of the packets sent in Internet Service is unreliable, datagrams can be lost

slide-9
SLIDE 9

Fragmentation

  • PDUs have a maximum size for the data area (Maximum

Transmission Unit – MTU)

  • Since the length MTUs chenges for different protocols, a

router has to be able to fragment datagrams, that will be reassembled at the IP layer by the destination host.

slide-10
SLIDE 10

Fragmentation disadvantages

  • The router has to be able to divide PDU
  • Fragments have to be reassembled by the destination host
  • NOTE: IP standard establishes that a datagram has to be

fragmented by the sender host

slide-11
SLIDE 11

Service times

Service Time

  • f a message

Time to transmit the message

  • ver the network

= = # of bytes of message bandwidth =

slide-12
SLIDE 12

Example WITHOUT fragmentation

300 byte message sent from a Client to a Server

TCP IP Client TCP IP Server

ethernet

T.R. FDDI

300 300 20 300 20 20 300 20 20 18 300 20 20 28 300 20 20 28 300 300 20 300 20 20 router1 router2 Bandwidth Eth: 10.000.000 bps FDDI: 100.000.000 bps T.R.: 16.000.000 bps MTU: 4444 bytes MTU: 4472 bytes MTU: 1500 bytes

slide-13
SLIDE 13

LAN service time

300 20 20 18 Service Time Eth = 10.000.000

= =

358 x 8 10.000.000 0.000286 sec. Service Time FDDI = 100.000.000

= =

368 x 8 100.000.000 0.00002944 sec. Service Time TR = 16.000.000

= =

368 x 8 16.000.000 0.000184 sec. 300 20 20 28 300 20 20 28

300 byte message sent from a Client to a Server

x 8 x 8 x 8

slide-14
SLIDE 14

Example WITH fragmentation

TCP IP client TCP IP Server

ethernet

T.R. FDDI

10000 4404 20 20 4424 20 1172 20 4404 20 20 4424 20 1172 20 28 28 28 4404 20 20 4424 20 1172 20 28 28 28 28 28

  • +

TR FDDI 28 28

+

  • 28

28

+

  • 4404

20 20 4424 20 1172 20 28 28 28 28

  • FDDI

28

  • 28
  • =

4424 = = 18 data ET

The Server sends a 10.000 byte reply to Client

Hypothesis: TCP does not know the local network MTU

20 1480 20 18 1480 20 18 1464 20 18 data IP ET 1460 20 18 1480 20 18 1464 20 18 data IP ET TPC 20 10000 20 router1 router2 MTU: 4444 bytes MTU: 4472 bytes MTU: 1500 bytes 4404 20 20 1172 20 1172 20

slide-15
SLIDE 15

LAN Service Time

Service Time =

16.000.000

The Server sends a 10.000 byte reply to Client

Hypothesis: TCP does not know the local network MTU

4404 20 20 4424 20 1172 20 28 28 28 + +

Service Time = 16.000.000 (4472+4472+1220) x 8

=

0.005082 sec.

( ) x 8

Case of Token Ring:

slide-16
SLIDE 16

TCP IP client TCP IP Server

ethernet

T.R. FDDI

10000 4404 20 4404 1192 4404 20 20 4404 20 1192 20 4404 20 20 4404 20 1192 20 28 28 28 4404 20 20 4404 20 1192 20 28 28 28 28 28

  • +

TR FDDI 28 28

+

  • 28

28

+

  • 4404

20 20 4404 20 1192 20 28 28 28 28

  • FDDI

28

  • 28
  • =

= = 1460 20 18 1480 20 18 1464 20 18 data IP ET 18 ET 20 20 20 20 20 20 20 20 20 20 20 TCP

Example WITH fragmentation

The Server sends a 10.000 byte reply to Client

Hypothesis: TCP knows the local network MTU

MTU: 4444 bytes MTU: 4472 bytes MTU: 1500 bytes router1 router2 4404 20 20 4404 20 20 1192 20 20 1192 20 20 data IPTCP

slide-17
SLIDE 17

Service Time =

16.000.000 4404 20 20 4404 20 1192 20 28 28 28 + +

Service Time = 16.000.000 (4472+4472+1260) x 8

=

0.005102 sec.

( ) x 8

20 20

0.005082 sec. 0.005102 sec. 20 µsec different

LAN Service Time

The Server sends a 10.000 byte reply to Client

Hypothesis: TCP knows the local network MTU

Case of Token Ring:

slide-18
SLIDE 18

Average service time

Evaluation without fragmentation

Let’s specify: MTUn: network n MTU (byte) XOvhd: X protocol overhead (byte) FrameOvhdn: network n overhead (byte) Overheadn: network n total overhead (TCP+IP+frame) (byte) Bandwidthn: network n bandwidth (Mbps) Ndatagrams: number of IP datagrams required Nsegments: number of TCP segments required (< or = Ndatagrams) N: number of networks

slide-19
SLIDE 19

Average service time

Without fragmentation

NDatagrams =

ServiceTimen =

MessageSize + NSegments x TCPOvhd minn MTUn - IPOvhd Overheadn = NSegments x TCPOvhd + Ndatagrams x (IPOvhd + FrameOvhdn)

8 x (MessageSize + Overheadn ) Bandwidth

NSegments = MessageSize 65515 NSegments = NDatagrams TCP knows LAN MTU TCP does not know LAN MTU

(rough estimate)

slide-20
SLIDE 20

Exercise

T.R. FDDI 100 Mbps MTU: 4472 bytes

The client sends 3 transactions per minute (0.05 tps), whose average message lenght is 400 bytes. Length of 80% of replies is 8092 bytes and length of the 20% is 100.000 bytes Assuming that no fragmentation exists and the TCP layer does not know the netwotk MTU, evaluate the average service time for requests and replies for each network.

router1 router2 Client DB server

Ethernet 10 Mbps MTU: 1500 bytes Token Ring 16 Mbps MTU: 4444 bytes

slide-21
SLIDE 21

Exercise - solution

  • Using

NDatagrams = MessageSize + Nsegment x TCPOvhd minn MTUn - IPOvhd

We can evaluate the numbers of Datagrams required in each case (request, short reply and long reply) (400+1*20)/(1500-20) = 1 (request) (8092+1*20)/(1500-20) = 6 (short reply) (100000+2*20)/(1500-20) = 68 (long reply)

slide-22
SLIDE 22

Exercise - solution

We can evaluate the network overhead (case of ethernet): OverheadEth = 20 + 1 (20 + 18) = 58 (request) OverheadEth = 20 + 6 (20 + 18) = 248 (short reply) OverheadEth = 20 + 68 (20 + 18) = 2604 (long reply) Overheadn = TCPOvhd+Ndatagrams x (IPOvhd + FrameOvhdn)

  • Using

We can evaluate the Service Time (case of ethernet): OverheadEth = 8 x (400 + 58) / 10.000.000 = 0.366 msec request OverheadEth = 8 x (8092 + 248) / 10.000.000 = 6.67 msec short reply OverheadEth = 8 x (100.000 + 2604) / 10.000.000 = 82.1 msec long reply

ServiceTimen = 8 x (MessageSize + Overheadn ) Bandwidth

  • Using
slide-23
SLIDE 23

Service times evaluation

Request Short reply Long reply Eth

Ndatagrams

1 6 68

Overhead (byte)

58 248 2604

ServiceTime(msec)

0.366 6.67 82.1

FDDI

Ndatagrams

1 6 68

Overhead (byte)

68 308 3284

ServiceTime(msec)

0.0374 0.672 8.26

TR

Ndatagrams

1 6 68

Overhead (byte)

68 08 3284

ServiceTime(msec)

0.234 4.2 51.6

Router

Latency (134 usec/packet)

134 804 9.112

slide-24
SLIDE 24

Network Router

Router queues

slide-25
SLIDE 25

Router Service Times

Router latency (µsec per packet): time spent by the router to process a datagram (the value is provided by the manufacturer). RouterServiceTime: Ndatagrams * RouterLatency Where

NDatagrams = MessageSize + TCPOvhd minn MTUn - IPOvhd

slide-26
SLIDE 26

Exercise

  • Router 1 and 2 process 400,000 packets/sec

⇒ Service time: 2.5 µsec (=1/400,000) ⇒ Service demand at router

T.R. FDDI 100 Mbps MTU: 4472 bytes

router1 router2 Client DB server

Ethernet 10 Mbps MTU: 1500 bytes Token Ring 16 Mbps MTU: 4444 bytes Client Request Short Reply Long Reply 1 x 2.5 = 2.5 µsec 6 x 2.5 = 15 µsec 68 x 2.5 = 170 µsec