In this tutorial, you will learn the basic concepts of quality of service. After reading this tutorial, you will learn about various ways to improve the Quality of Service, Resource Reservation, and Models of QoS.
Contents:
- Quality of Service (QoS)
- Techniques to Improve QoS
- Scheduling of Packets
- Integrated Services
- Resource Reservation Protocol (RSVP)
- Differentiated Services (DS)
- DS Fields
- Traffic Conditioner
Quality of Service (QoS)
The quality of service provides reliability to the users by managing the congestion on the network. It focuses on reliability, delay, jitter, and bandwidth.
- Reliability: there is less reliability or no reliability, the chances of packet or acknowledgment loss increases.
- Delay: packet delay from the sender to the receiver should be minimal. May tolerate delay in some applications. In telephone communication, audio, or video conferencing, minimal delay is required, whereas in file transfer or email the delay is less significant.
- Jitter: ‘s kind of a delay. In audio and video applications, jitter is acceptable. If the difference in latency of the sent packets is high, the jitter is also high.
- Bandwidth: is used according to the type of network and application. For example, video calling requires more bandwidth because we need to send millions of bits per second to refresh the color screen.
The diagram below shows the performance of the parameters required in various applications.

As shown in the figure, reliability, bandwidth, delay, and jitter are the parameters of the quality of service. Some applications require high bandwidth, and some require low bandwidth. We can say that the network is reliable and has good quality of service if there is reliability and minimum delay for transmission of packets.
Techniques to Improve QoS
Traffic shaping, admission control, resource reservation, scheduling are the techniques used to improve the quality of service (QoS).
Traffic Shaping: is the mechanism used to control the rate of traffic flow sent over the network. Leaky buckets and Token buckets are traffic shaping techniques.
- Bucket: network consists of a bucket with a small hole through which traffic leaks at a constant rate as long as traffic remains in the bucket.
- Token Bucket: disadvantage of the leaky bucket is that if the host does not send traffic for some time, the bucket becomes empty. Now, if all of a sudden the host sends a lot of traffic, the leaky bucket still leaks the traffic at a constant rate. In a token bucket, it gives tokens to hosts for future use if the host is inactive. So, if heavy traffic comes at once, he can handle it easily.
Admission Control: Routers and switches have flow specification parameters based on which routers and switches accept or reject the flow of packets.
- When a flow or traffic enters the network, the router checks the bandwidth of the flow (buffer size, CPU speed, etc.) and matches it with its capacity to check whether it can handle the traffic.
Resource Reservation: In this method, resources (buffers, bandwidth, CPU time, etc.) are reserved before the communication between the sender and the receiver takes place to improve the quality of service.
Scheduling of Packets
The packets come from different networks to the router or switch, and they have to be held by the router for further processing. So, three scheduling techniques are used to improve QoS. FIFO (First In First Out), Priority Scheduling, and Weighted Fair Queuing.
FIFO: In FIFO, the packet waits in the buffer (queue) until the router or switch picks it up and processes it. If the buffer is full, the router discards the new packet.
The figure below explains FIFO.

As shown in the figure, there is a queue in which the packet will wait until the router is processed. If the arrival time exceeds the processing time, the new packet will be discarded by the router.
Priority Scheduling: In this method, each packet is assigned to a priority class where the priority class has its own queue. The packets in the higher priority queue are processed by the router first.
The diagram below explains the Priority Scheduling.

As shown in the figure, there are two priority classes, high and low. High-priority queue packets will be processed first, and low-priority queue packets will be processed last. It provides better QoS than FIFO.
Weighted Fair Queue: In this method, the packets are still in class as priority scheduling. But here, packets are given priority instead of queues. A higher priority packet means more weight. The packet will be processed by the node using a round-robin algorithm. Packets are selected based on their priority.
Integrated Services
Integrated services and differentiated services are two models for providing quality of service. These models are used at the network layer. Integrated Services is also known as IntServ. It is a flow-based QoS model in which the user is required to create a virtual circuit flow from sender to receiver. It is generally designed for Internet Protocol (IP). Signaling, Flow Specifications, Admission, and Service classes are integrated services.
- Signaling: We can implement the flow-based model on the connectionless network by using a signaling protocol. Basically, a signaling protocol is used for IP which provides signaling technology to reserve resources. It is also known as Resource Reservation Protocol (RSVP).
- Flow Specification: After resource reservation is made, the source defines the resource specification (Rspec) and the transport specification (Tspec). Using Rspec, the source knows which resources to reserve. The Tspec defines the characteristic of the traffic.
- Admission: When the router receives the flow specification from the sender, it decides to accept or reject the service.
- Service class: Guaranteed service class and Controlled-load service class are two service classes for integrated services.
- Guaranteed Service Class: This class ensures minimum end-to-end delay between sender and receiver. Here, the end-to-end delay is the sum of the delays in the router.
- Controlled-load Service Class: This class is designed for applications that accept some delay but are sensitive to the threat of packet loss.
Resource Reservation Protocol (RSVP)
Resource Reservation Protocol (RSVP) is the signaling protocol, which helps IP to form a flow such as virtual-circuit network, and consequently make resource reservations.
- Multicast Tree: RSVP is designed for multicasting and is also used in unicasting. This design enables RSVP to provide resource reservations for all types of traffic on the network.
- Receiver-based reservation: In this reservation, instead of the sender, the receiver makes the reservation.
- RSVP Messages: There are different types of messages in the RSVP protocol. In this, we will discuss only two that are Path and Resv.
- Path message: When the receiver makes a reservation, it does not know which way the packet will come. So, RSVP consists of the path messages, which travel from the sender and reach all the recipients.
- Resv Message: When the receiver successfully receives the Path message, it sends the Resv message to the sender and makes a reservation on the router that supports RSVP.
The below diagram explains the Path and Resv message.

As shown in the figure, the sender sends the path message to all the routers in the multicast group. When routers receive a path message, in response, they send a Resv message to make a reservation.
Reservation merging: In RSVP, reservations are merged, and resources are not reserved for each receiver in a flow or virtual-circuit network.
Reservation styles: If more than one flow or a virtual-circuit network exists, the router makes reservations to accommodate all of them. The wild card filter style, the fixed filter style, and the shared explicit style are types of reservation styles.
- Wild card filter style: In this, the router creates only one reservation for all the senders, and the reservation is based on the largest request.
- Fixed filter style: In this, the router creates separate reservations for different flows, which means that if there are n flows, then n reservations are made.
- Shared Explicit Style: In this, the router creates a single reservation that is shared with a set of flows.
Differentiated Services
Scalability and service-type limitation are two problems with integrated services. As we discussed that in integrated service, each router holds information for each flow, so if the network scales, the problem becomes severe. Also, Integrated Services provides only two services, guaranteed and control-loaded. Applications may require more than two services. Hence differentiated services came into play.
- Differentiated services handle the problems of integrated services. It was introduced by the IETF.
- In differentiated services, routers do not need to store flow information, this approach solves the scalability problem. The service is defined by applications when they need to send packets.
- Services are defined in packets and based on the service the router routes the packets. This approach solves the service-type limitation problem of integrated services.
DS Fields
Differentiated Services are also known as DiffServ in which, each packet has a field named DS field. The DS field is determined by the router located at the border of the network.
The figure below explains the structure of the DS field.

- As shown in the figure, the DS area consists of the DSCP (differentiated service code point) and CU (currently unused) sub-fields. The DSCP and CU bit sizes are 6-bit and 2-bit, respectively.
- The DSCP field is 6-bit, which defines per-hop behavior (PHB).
Per-hop behavior: There is a per-hop behavior (PHB) for each router that receives a packet from another node. Here, the PHB is defined by the DiffServ model.
- DE PHB (Default PHB), EF PHB (Expedited Forwarding PHB), and AF PHB (Assured Forwarding PHB) are sub-fields of PHB.
- DE PHB: This is similar to the best effort distribution used in IP packets.
- EF PHB: Low packet loss, low latency, and assured bandwidth are the services provided by EF PHB.
- AF PHB: Delivers packets with high assurance as long as class traffic does not exceed the node’s traffic profile. When packets start being discarded, users should be aware of it.
Traffic Conditioner
The node uses traffic conditioners (meters, markers, shapers, and droppers) to implement differentiated services.
The diagram below explains the structure of a traffic conditioner.

- As shown in the figure, the meter, marker, shaper, and dropper are traffic conditioners.
- Meter: The meter is used to check whether the incoming flow matches with the pre-defined traffic.
- Marker: A marker marks the packet when it finds that the packet is using best-effort delivery. If the flow does not match the traffic profile negotiated based on the information sent by the meter, it down-marks the packet.
- Shaper: Shaper reshapes the incoming traffic if it does not match the negotiated traffic. For that, it uses the information received from the meter.
- Dropper: When the packet flow violates the specified traffic profile, the dropper drops the packet. The dropper is a shaper but has no buffer.
Key Points to Remember
Here is the list of key points we need to remember about “Quality of Service”.
- The quality of service provides reliability to the users by managing the congestion on the network. It focuses on reliability, delay, jitter, and bandwidth.
- Traffic shaping, admission control, resource reservation, scheduling are the techniques used to improve the quality of service (QoS).
- The packets come from different networks to the router or switch, and they have to be held by the router for further processing. So, three scheduling techniques are used to improve QoS. FIFO (First In First Out), Priority Scheduling, and Weighted Fair Queuing.
- Integrated services (IntServ) are generally designed for Internet Protocol (IP). Signaling, Flow Specifications, Admission, and Service classes are integrated services.
- Resource Reservation Protocol (RSVP) is the signaling protocol, which helps IP to form a flow such as virtual-circuit network, and consequently make resource reservations.
- Differentiated services handle the problems of integrated services. It was introduced by the IETF.
- Differentiated Services are also known as DiffServ in which, each packet has a field named DS field. The DS field is determined by the router located at the border of the network.
- The node uses traffic conditioners (meters, markers, shapers, and droppers) to implement differentiated services.