DiffServ
ENTC 345Dr. Ana GoulartAssistant Professor
Announcement
Homework#6 due next Monday
Announcements
Syllabus Course Topics
Network Simulation – Introduction to Opnet Protocol Architecture Wide Area Networks –Frame Relay Local Area Networks
Ethernet WLANs
Internet and Transport Protocols Quality of Service Architectures Internet Applications – Multimedia and Internet Telephony
Announcements
Today (Monday)Quality of Service (Ch. 19)
WFQ with different weights DS codepoint (TOS byte)
Voice-over-IP (Ch. 24)Reminder – Throughput calculation of WLANs
Generalized Processor Sharing (GPS) WFQ calculates the finish number for each packet as if it
was served by GPS, and then use this finish number to order the service of packets.
schedulerN ConnectionsEqual weights
Bandwidth
1N
Bandwidth to eachConnection
Generalized Processor Sharing (GPS) For different weights:
scheduler
w1
Bandwidth
Scheduler servers an infinitesimal from each connection in turn.
w2
wn
Queue with weight w1 will have afraction equal to w1/(Σi wi) of the total bandwidth of the outgoing link.
Computing finish numbers
Packet size/weight + the greater ofThe finish number of the previous packet in
the same queueThe current round number
F(i, k, t) = P(i, K, t) + max { F(i, k-1, t) , R(t) }
i = connection identifierk = packet identifiert = time t
wi
Weighted Fair Queuing Example (1st part) Assume a WFQ Scheduler with 3 queues
(connections) wA = 1, wB=2, wC= 1 Packets of size 1, 2, and 2 units arrive at
time 0 on connections A, B, and C. The link rate is 1.0 unit/second Initialize the system with R(t) = 0.
WFQ Example – t = 0
A (1) B (2) C(1)
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 1 2 2 2
WFQ Example – t = 1
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 1 2 2 2
T=1 3 0.25 1 0.75 1 1.5 2 1.75
WFQ Example – t = 2
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 1 2 2 2
T=1 3 0.25 1 0.75 1 1.5 2 1.75
T=2 3 0.5 1 0.5 1 1 2 1.5
WFQ Example – t = 3
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 1 2 2 2
T=1 3 0.25 1 0.75 1 1.5 2 1.75
T=2 3 0.5 1 0.5 1 1 2 1.5
T=3 3 0.75 1 0.25 1 0.5 2 1.25
WFQ Example – t = 4
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 1 2 2 2
T=1 3 0.25 1 0.75 1 1.5 2 1.75
T=2 3 0.5 1 0.5 1 1 2 1.5
T=3 3 0.75 1 0.25 1 0.5 2 1.25
T=4 3 1 1 0 1 0 2 1
WFQ Example – t = 4
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 2 2 2 2
T=4 3 1 1 0* 1 0* 2 1
After 4 units of time, each connection has received 4*0.25 = 1 units of service.
That is enough service for the first and second packets to depart, but onlyhalf enough for connection C.
WFQ Example – t = 5
A B C
Time Connections Round Finish #
Rem. Finish # Rem. Finish # Rem.
T=0 3 0 1 1 2 2 2 2
T=4 3 1 1 0* 1 0* 2 1
T=5 1 2 1 0* 1 0* 2 0*
Actual delivery times
Note the finish numbers are not the times when the packets complete service.
The first packet to be serviced is packet 1 from A or packet 1 from B. Assume scheduler chooses to deliver packet from B. Service is completed at time 2.
The second packet to be serviced is packet from A, which completes at time 3.
The third packet to be serviced is packet from C, which completes at time 5.
B B A C C
T=5
Differentiated Services
Differentiated Services - Overview IP packets are labeled using the DS
field (or TOS – Type of Service field) All traffic with the same DS octet is
treated the same by the network service
VERS HLEN TOTAL LENGTH
0 4 8 16 19 24 31
IDENTIFICATION FLAGS FRAGMENT OFFSET
TIME TO LIVE PROTOCOL HEADER CHECKSUM
SOURCE IP ADDRESS
DESTINATION IP ADDRESS
PADDINGIP OPTIONS (IF ANY)
DATA
SERVICE TYPE
…
IP Header - originally
IP Header
Service type TOS byte – Type of service
D T R
3 1(Unused
bit)Precedence higher => better service
routers don’t look atthese bits (DTRM)
•DS (Differentiated Services) octet
M
IPv4 Precedence Service
IPv4 TOS field included subfields precedence (3 bit) - datagram urgency/priorityTOS(4 bit) - guidance on selecting next hop
D T R
3 1(Unused
bit)Precedence higher => better service
M
IPv4 Precedence Service
IPv4 TOS field included subfields precedence (3 bit) - datagram urgency/priorityTOS(4 bit) - guidance on selecting next hop
D T R
3 1(Unused
bit)Precedence higher => better service
M
Precedence: 111 – Network Control 110 – Internetwork control 101 – Critical 100 – Flash Override … 000 - Routine
Recommended values for TOS field
Application Minimize delay
Maximize throughput
Maximize
reliability
Minimize
Monetary cost
Telnet 1 0 0 0
FTP - data 0 1 0 0
TFTP 1 0 0 0
DNS (UDP) 1 0 0 0
SNMP 0 0 1 0
NNTP 0 0 0 1
However, most routers do not look at those bits.
Differentiated Services
Routers deal with each packet individually and do not have to save state information on packet flows -> per-hop behavior (phb)
Services (specified in TOS bits): Expedited Forwarding PHBAssured Forwarding PHB
DS Field (6 bits) Keeps compatibility with originalprecedence bits
Differentiated Services Domains
DS Configuration and Operation
within domain, interpretation of DS code points is uniform
interior nodes implement simple mechanisms per-hop behavior (PHB) on all routers
boundary nodes have PHB & more sophisticated mechanisms hence most of complexity
DS Traffic Conditioner