IP Quality of Service Part 3

In the first part of this series, we looked at the need for Quality of Service (QoS) and how it is not a single protocol or device but an overall structure of a system design to ensure that the most important data is tagged as such and the network equipment is set up to give that data priority. Remember, a network can only delay, drop or pass through any particular IP packet. By assigning a priority level to real-time data, such as IP video or audio, its timely arrival becomes more assured. With real-time data, there is no time for any dropped IP packets to be resent, such as what happens when a file transfer (non-real time) IP packet is dropped by a network.

In the second part, we went over how QoS is implemented using the Type of Service (ToS) field within the IP packet header. Every IP packet is stamped with its own ToS that denotes its level of priority to every device it passes through. Each device must be set up by the network engineer to look for and know what to do with packets of different priority levels. QoS rules tell these devices how to handle their internal queues in relation to the ToS of various priority levels.

Level 3 OSI

QoS using the ToS field in an IP packet means the network is using data that is present on Level 3 of the OSI model for network communications. If we look at how data that is sent out over an Ethernet network is formed, we can see where the IP packet fits in. (See Figure 1.)

Layer 1 is concerned with the electrical signals, cabling and connectors that physically make up a computer network. Layer 2 is about the actual devices on the network, their unique addresses (MAC addresses that can’t be changed) and how data is directed to them. It is at this level where network switches operate, looking at MAC addresses and switching Ethernet frames of data to the correct node. Layer 3 if farther up the OSI chain and is concerned with more virtual matters such as IP addresses, which can be changed. Above this is the realm of software and programming.

How deeply a device looks at data flowing through it labels it as either a Layer 2 or Layer 3 OSI device. Because a network switch looks just at the MAC address of an Ethernet frame, and MAC addresses only reside on Layer 2 of the OSI model, network switches are considered Layer 2 devices, or switches. A router, on the other hand, receives the same Ethernet frame, but it looks deeper into the packet and extracts and acts on the IP address contained within. This makes it a Layer 3 device, because IP addresses reside on Layer 3 of the OSI model.

Some devices look much deeper into a packet to actually examine the data payload of the packet — the TCP or Layer 4. This usually is done to block certain types of data traffic that could harm the network and the computers connected to it.

Layer 3 switches and QoS

There is a type of network switch that works on Layer 3 of the OSI model. This type of switch is used in special applications where virtual LANs (VLANs) are needed. This switch will examine Ethernet frames down to the IP packet level to switch them (using their IP addresses) and to segregate the various VLAN domains. (See Figure 2.)

When using VLANs (IEEE 802.1Q), the Ethernet frame is altered to carry extra data, which is called VLAN tagging. This extra data identifies this Ethernet frame as belonging to a VLAN, as well as its priority level and to which VLAN that particular frame belongs to. (See Figure 3.)

The priority level is in the form of the Priority Code Point (PCP), which is a 3-bit field that prioritizes the Ethernet Frame from zero (lowest) to seven (highest). This is another form of QoS that is separate from the one used within the IP packet header, i.e. the ToS.

The VLAN identifier (VID) is a 12-bit field used to identify the particular VLAN the Ethernet frame is associated with. If this ID is set to 00, it indicates that this Ethernet frame is not associated with any VLAN and that the VLAN tag is only being used for priority signaling.

For this to work, the proper equipment must be installed and set up correctly. This starts at the source of the Ethernet frame and follows through to the Layer 3 switches as well as any router used to cross between VLANs.

From this small glimpse into QoS, you can see how and why it is important in today’s networks that are inundated with streaming media. As TV stations move forward, it is inevitable that they will be using IP networks to transport many types of data, including video, audio and transport streams. As this happens, it will become increasingly important for engineers to understand the overall design and implementation of QoS on the network.