What is IP priority in QoS

QoS - Quality of Service (VoIP)

Quality of Service, QoS for short, are measures and procedures for influencing the data traffic in a network in order to improve or guarantee the quality and availability of network services.
In the TCP / IP world, Quality of Service describes the quality of a communication service from the perspective of the user. The network service quality is often defined using various parameters.

  • Bandwidth (transmission capacity)
  • Delay
  • Jitter
  • Packet Loss

By default, all data packets in a network are handled according to the best effort principle. This means that all data packets are treated equally. However, this also means that in a packet-oriented network, depending on the load, the individual data packets can travel at different speeds. As long as messages and files are mainly transmitted, there are seldom delays. However, if data packets from real-time applications such as Voice over IP or video streaming are transmitted, delays or even packet losses have a negative effect on the transmission properties of the connection.
As a result, there are disruptions in voice and video transmission. For example, through choppy language, scratching and cracking. This worsens the perceived speech quality and thus speech intelligibility.
Missing image fragments lead to pixelated or jerky playback in a video. In comparison, it is hardly noticeable if an e-mail reaches the recipient a few seconds later.

Because TCP / IP separates the application level from the transmission level and makes it independent, there is no longer any communication between these levels. The OSI layer model ensures that the protocols on the different layers work independently of one another. What makes sense in principle causes problems in audio and video transmission. The transmission systems are not able to differentiate between a voice packet and a normal data packet.

With Quality of Service (QoS) you can try to eliminate this deficiency and, for example, identify data packets with service classes that are assigned to certain applications. In this way, an attempt is made to define service features at the application level and to pass them through across the protocols.
In order for Quality of Service to work, the necessary QoS mechanisms must be implemented along the entire transmission path. Of course, this is only possible if the network belongs to a single organizational unit, which is not the case on the Internet.

Note: QoS measures do not provide any additional bandwidth. 10 Mbit / s will not become more. With QoS measures, you can only ensure that certain data is transmitted preferentially or prioritized over the 10 Mbit / s, for example.

Measure the quality of the transmission

Quality of Service is tuning in the network. Comparable to PC and car tuning. Quality improvements in the network should always be measured before and after.
If something is to be improved, it must be determined before doing what and how it can be improved. For this purpose, the quality must be checked with suitable measuring and monitoring tools. For example, the available bandwidth for certain applications must be continuously monitored.

Criteria for the quality of the transmission are, for example, packet delays, the rate of packet loss and jitter. Depending on the application, further quality features must be examined and measured.

Influences on the voice quality

When transmitting over different networks, there are fluctuations in the volume of traffic in these networks, which has a considerable influence on the transmission quality of a voice signal and thus also on the voice quality.

  • Bandwidth (transmission capacity)
  • Delay
  • Jitter (runtime fluctuations)
  • Packet Loss

QoS parameters: bandwidth (transmission capacity)

In the digital world one speaks of bandwidth, transmission capacity or transmission speed. The bandwidth is specified in bits per second (bit / s). The higher the bandwidth, the fewer problems you have with delays and packet loss.

QoS parameters: Delay (transit time delays)

The runtime of the voice packets is an important criterion for voice quality. One is interested in the total delay between the sender speaking and the recipient hearing (end-to-end delay).

root causerunning time
AD conversion20 ms
Package creation30 ms
other service times10 ms
Routing over 800 kilometers50 ms
Jitter buffering30 ms
D-A conversion20 ms
Total running time160 ms

Runtime delays, also known as delay, arise when the data formats are converted and by routing. The greatest delays occur during transport. Delays occur particularly in the intermediate stations (switch, router, gateway, firewall and proxy). This is where the packets are processed, which takes time and leads to delays. Routing is particularly critical. Especially when a media change takes place.
A delay also arises when the voice signal is digitized and compressed. The delay depends on the codec and the available computing power. The codec only has a small share in the overall delay. Therefore, optimizing the codec itself is usually of little use.

Voice transmission means that reciprocal communication is carried out via two connections (duplex operation) or at least one connection (half duplex operation). A maximum delay of 200 ms is therefore acceptable for duplex operation, and between 200 and 500 ms for half-duplex operation.
The total delay from participant to participant should not exceed 150 ms. A delay of less than 150 ms results in very good voice quality. A conversation is already negatively influenced from a delay of 250 ms. With up to 400 ms, a conversation is still considered acceptable. From a delay of 400 ms, clearly audible and uncomfortable pauses in speech occur. You can still hear the other participant speaking, although he has already finished speaking. This leads to the fact that you interrupt your conversation partner too often. This problem is known to exist in cell phone calls when the reception is poor on one side.

Note: If possible, you want a delay that is almost constant.

Measure runtime with ping

The ping can be used as a rough estimate to measure delays on a transmission path. It must be noted that the ping measures the total delay of the outward and return route (round-trip time, RTT). Voice data, on the other hand, is only transmitted in one direction and ends at the recipient. The receipt of the packages is not confirmed at the transport level. Therefore, the value that ping delivers must be halved. You have to take into account that the times for the way there and back can be different. But Ping does not show these times separately from each other. This is why ping times can only be used as a rough estimate. A measurement with meaningful and correct values ​​has to be done differently in practice.
To make the measurement with ping more or less realistic, the packet size of ping must be set. Assuming the coding with G.711 and 20 ms voice data per packet, this corresponds to 160 bytes (64 kBit / s x 0.02 s). You have to add 40 bytes for the IPv4 / UDP / RTP header portion. The ping should therefore send 200 bytes per packet.

Command for the Windows command line:

ping -l 200 -t {hostname}

Command for the Linux command line:

ping -s 200 {hostname}}

The command is repeated until the key combination Ctrl + C is pressed.

QoS parameters: Jitter (transit time fluctuations)

When transmitting data packets, there are certain delays in the runtime. These delays can vary. These time differences are referred to as transit time fluctuations, transit time differences or jitter. In particular, voice and video transmissions (real-time applications) suffer from differences in the runtime of the data packets.
Jitter is the term used to describe the deviation in the distance at which the packets arrive at the recipient. This is not about 10 ms more or less running time, but about the fact that this 10 ms running time can always be achieved and it is not even 5, 10, 15 ms or more.
Fluctuations in transit times lead to poor voice quality. Jitter buffers are used to avoid runtime differences. The jitter buffer can compensate for the irregularities between the incoming data packets to a certain extent. To do this, it temporarily stores incoming data and releases it again in a steady flow. This compensates for uneven, repeated or incorrect data flow.
But you can only minimize the jitter in your own routers. As soon as the data packets leave the network, there is no longer any influence on the jitter.

QoS parameters: Packet Loss

For the transmission of VoIP voice data, UDP is used, which cannot ensure the delivery of the packets. This also makes little sense with voice data. A language packet only contains around 20 to 30 ms of speech, which corresponds roughly to one syllable. Adding a syllable makes little sense and is also not necessary. If this doesn't happen too often, you can get over the loss. You can tolerate irregular packet losses. Our brain is able to independently and correctly add missing or incorrect words or word syllables that are in a logical sentence context. But if data packets are missing too often, this is noticeable through dropouts and failures. This reduces the voice quality. As soon as successive packets are lost, whole words or parts of sentences are missing.

The indication "Packet Loss" provides information about the percentage of data packets that have been lost. This value is usually one percent. A codec must be able to compensate for up to 5% data loss, which remains unheard when making a phone call.
The most common cause of packet loss is network congestion. Data buffers are a popular means of avoiding packet loss and compensating for short-term fluctuations in bandwidth by temporarily storing data packets. In principle, however, you should avoid buffering voice data during transmission. This only delays them unnecessarily.

QoS measures

Any quality of service (QoS) process or measure is used to give certain data packets priority in order to ensure the operation of time-critical applications. A good quality of service is a multitude of coordinated measures.

  • Overdimensioning of the networks (much more bandwidth than required)
  • Reservation of bandwidth for certain applications
  • Exclusive use for VoIP: with MPLS, VLAN or using your own lines
  • Prioritized transmission of certain data packets
  • Connection-oriented protocol below the IP layer

If you control your own network or a leased line and implement powerful QoS mechanisms, then the quality of service is usually not a problem. The properties are lost when switching to a foreign network.
If you can't get QoS, you "kill" the problem with more bandwidth or less other traffic.

QoS measure: oversizing the networks

It is quite common to forego Quality of Service and simply to provide a lot more bandwidth than is practically necessary. But more bandwidth is only useful where there is too little bandwidth. You have to take into account the bottlenecks along the entire transmission path.
If the bandwidth requirement increases over time, this must be taken into account and even more bandwidth must be made available.

QoS measure: reservation of bandwidth

In order to achieve a high quality of service, it is common practice to reserve the available bandwidth for certain applications. For example with the Resource Reservation Protocol (RSVP). Other applications are put on hold and have to make do with less bandwidth.

QoS measure: prioritization of data packets

The network load influences the quality of the transmission. For example, how long it takes for a data packet to arrive at the recipient. You can influence this by prioritizing certain data packets.
Prioritizing data packets requires the definition of service classes and traffic classes. The traffic class is defined according to a quality of service and assigned to an application. Data packets of a higher traffic class are forwarded preferentially in routers or switches.
However, the prioritization only works where the traffic classes apply. If prioritized data packets leave a network, other traffic classes may apply here.
Prioritization only makes sense if all network components and subnetworks support the same traffic classes and prioritization rules.

In the simplest case, the traffic types are differentiated based on the TCP and UDP ports. VoIP runs with SIP over 5060 / UDP and 5061 / UDP. For example, while surfing via 80 / TCP or 443 / TCP. Voice packets can be recognized by the RTP and SRTP headers. You can just as easily filter them based on the source ports. Voice transmissions can also be recognized by the packet length and the packet transmission frequency. In addition, NAT traversal traffic (STUN, ICE, TURN) and the associated metadata (IP addresses of register servers).

Connection-oriented protocols

With VLAN, ATM and MPLS, certain traffic characteristics are assigned to the traffic sources. Compliance with these properties is constantly monitored.

CoS - Classes of Service


Classes of Service defines classes of data transmissions to which data packets are assigned. Each class corresponds to a priority that is used to decide which data packets are to be transmitted with preference. It must be noted that the amount of data in the high traffic classes must be limited, otherwise no transmission is possible for low-priority data packets on overloaded connections.
The implementation of CoS usually fails due to the differently assigned CoS rules in the various networks of the network operators. Every network operator does its own thing here.

DiffServ - Differentiated Services

DiffServ is a method for prioritizing data traffic for real-time applications over IP. Each data packet is assigned to a traffic class. Data packets of a higher traffic class are treated preferentially over a lower traffic class.

Traffic shaping

When traffic shaping is activated, acknowledgment packets are preferentially transmitted in the uplink so that downloads running in parallel are not affected, the speed of which depends on the speed of the acknowledgments.

MPLS - Multiprotocol Label Switching

MPLS is often referred to as Quality of Service. However, this is only partially correct. MPLS is equivalent to Quality of Service, but only if you consider Quality of Service when setting it up.
In MPLS routers, labels are defined on the basis of which data packets are passed on to predefined outputs. In this way, the path of correspondingly marked data packets through a network is specified.
If you want to use MPLS as QoS, you have the option of selecting the labels according to characteristics such as availability, packet loss, latency, etc.


As long as the communication partners are in the same network, line quality and availability can be guaranteed via a corresponding agreement. How the provider then puts this into practice in his network is irrelevant to the customer. But as soon as the packets run over foreign networks, it becomes difficult to keep the agreement because there are no uniform standards and agreements for guaranteed cable quality.
And yet VoIP works quite well even without MPLS, RSVP or DiffServ. That's because traffic and bandwidth are very cheap. Most network operators implement QoS quite simply by using an oversized bandwidth.

Other related topics:

Product recommendations

Everything you need to know about networks.

Network technology primer

The network technology primer is a book about the basics of network technology, transmission technology, TCP / IP, services, applications and network security.

I want that!

Everything you need to know about networks.

Network technology primer

The network technology primer is a book about the basics of network technology, transmission technology, TCP / IP, services, applications and network security.

I want that!