Quality of Service For Ethernet: Matthew Demyttenaere, Application Engineer Sophie Legault, Product Manager

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 4

134

APPLICATION NOTE
Matthew Demyttenaere, Application Engineer Sophie Legault, Product Manager

QUALITY OF SERVICE FOR ETHERNET

Introduction
Data services are making a significant shift towards supporting a variety of applications on the same network. This shift has fuelled the need for quality of service (QoS) to ensure the condition and reliability of services. Service providers need to assign different qualities of service to each type of service they offer. For example, most often, real-time applications such as video and voice are assigned the highest priority. Critical data applications frequently take second place followed by email and web browsing. Different mechanisms exist to deploy QoS, and this creates the need to properly test the network configuration. This application note discusses the importance of QoS and offers QoS testing methods when activating data services.

What is quality of service (QoS)?


QoS is a mechanism that allows service providers to offer different classes of service to their customers. There are two main methods used to provide QoS, depending on the type of network service that is being provided. The most common and simplest service offered is Layer 2 Ethernet transport. This means that the service provider will offer Ethernet (at Layer 2 of the OSI model) as the transport mechanism. In this case, the service provider does not have to test for higher protocol layers, for example, Layers 3 or 4. When providing this kind of service, Virtual local area network (VLAN) tagging is used for QoS. If the service provider is offering services up to Layer 3 (IP), then the type of service (ToS) or differentiated services code points (DSCP) is used for QoS. This is a more complex service to provide and requires more extensive testing before it can be delivered to the customer.

Why is QoS important?


QoS is very important for both service providers and their customers. When service providers offer a service, they are required to guarantee a certain level of quality. The quality of the service depends on the agreed service contract or service-level agreement (SLA). For example, some customers may have more critical traffic and be willing to invest more to ensure that their traffic remains of the highest priority on the network. Other customers may have less-critical traffic and therefore not require uninterruptible, 24-hour service. No matter what the agreement, failure to respect the QoS requirements of the customer contract often results in damage compensation by the service provider. For this reason it is vital to properly test and deploy QoS.

What are the different types of QoS?


If service providers are offering Layer 2 services, then they can use the IEEE 802.1 Q/p standard for providing QoS. This standard allows a service provider to attach special tags, called VLAN IDs, to all incoming frames from a customer. By doing this, the service provider can have multiple customers using the same circuit, but still maintain a separation between them. Each customers traffic is identified by a different VLAN tag. The method also allows for the addition of a priority value to be associated to the VLAN tag. By using the priority field, the service provider can offer different classes of service to their customers (see Appendix I for more details on VLAN tagging and priority). If service providers are providing Layer 3 (IP) services, then there are currently two QoS standards available. The first standard is the RFC-791, which defines the ToS. The second standard is RFC-2475, which defines DSCP. Both of these standards use the same field in the IP packet header to identify the level of service for the packet. The RFC-791 was the original standard but was replaced by the newer standard RFC-2475. This newer standard gives the service provider more flexibility in configuring different QoS parameters for customers (see Appendix II for more details on these RFCs). These different QoS parameters (either for Layer 2 or 3) are stored as part of the overhead in the frames that are transmitted.

www.exfo.com
Telecommunications Test and Measurement

Application Note 134

How to test QoS?


When testing QoS, it is important to understand where it is being implemented. Is it being implemented at Layer 2 (e.g., a switch) or Layer 3 (e.g., a router)? If the QoS is implemented at Layer 2, then it is important to validate that the VLAN tag and priority have been configured correctly on the different switches across the network. This can be accomplished by using a test set that is capable of generating frames with the different VLAN tags and their associated priorities (see Figure 1). Using this test set should make it quite simple to see if the switch has been configured correctly.

Figure 1

If the QoS is implemented at Layer 3, then there are two choices available: ToS and DSCP. At this stage it is important to know which standard is being used on the networking equipment. If RFC-791 is being used, then there are a few different parameters on the router which can be configured, for example: precedence, delay, throughput, reliability and monetary cost (see Figure 2).

Figure 2

If RFC-2475 is being used, then there are two parameters that need to be configured; differentiated services code points (DSCP) and explicit congestion notification (ECN) (see Figure 3). Both standards use the same bits in the overhead of the frame; however, they are just defined differently. In most cases RFC-2475 is selected because it offers the user a lot more flexibility and is much easier when implementing QoS over Layer 3 equipment.

Figure 3

When testing for Layer 3 QoS, the same principals used for Layer 2 testing can be applied. Layer 3, however, is considerably more complicated. The reason for this is that once a service provider sells a Layer 3 service, there are many more additional parameters that need to be configured, such as the firewall. Whether Layer 2 or 3 is being used, it is important to have the capability of replicating real traffic conditions in order to test QoS properly. Sending different streams of traffic containing different levels of QoS (at Layer 2 or 3) across the network is a way of reproducing real network conditions (see Figure 4). With this type of traffic it is possible to test the proper traffic prioritization performed by switches and routers in the network.

www.exfo.com
Telecommunications Test and Measurement

Application Note 134

Figure 4

Other network parameters affecting QoS


As described in the previous sections, QoS across a network can be established using the VLAN tagging and ToS/DiffServ mechanisms embedded in the network protocols. However, even if all network elements across a path have these proper QoS configurations, many other factors can affect the quality of service. These main factors are frame delay variation (packet jitter), latency, throughput and frame loss. Specific service types are more affected by certain parameters than others. For example, time-sensitive applications such as Voice and Video will be more impacted by packet jitter and latency than regular data traffic. It is therefore extremely important to test all these parameters across the network before handing a circuit to a customer.

Appendix I
VLAN tagging (IEEE 802.1Q/p) The IEEE VLAN standard, 802.1Q consists of adding 4 bytes to the Ethernet frame. The first 2 bytes are the type protocol identifier. This identifies the frame as a tagged frame. The second byte is the VLAN tag and is used to identify the frame as belonging to a specific group on the network. When the frames go through the Ethernet network, the different switches along the way will read the VLAN tag and determine where the frame should be delivered. The first 3 bits of the VLAN tag are used to identify the priority of the frame. This refers to 802.1p.

Ethernet Frame Preamble 8 Destination Address 6 Source Address 6 Type 2 DATA 46-1500
IEEE 802.1q:81-00

FCS 4

IEEE 802.1q Tagged Frame Preamble 8 Destination Address 6 Source Address 6 TPID 2

Tag 2

Type 2

DATA 46-1500

FCS 4

Priority
3 bits IEEE 802.1p

CFI
1 bit

VLAN ID
12 bits (0 to 4095)

Figure 5

www.exfo.com
Telecommunications Test and Measurement

Application Note 134

Appendix II
Type of Service (ToS) and DiffServ The IP ToS field is an 8-bit field in the IP datagram (see Figure 6). The first 3 bits of the field are the Precedence field. This prioritizes packets within a queue. Packets with a higher priority value are transmitted before others. The other 5 fields that are present also act as routing criteria. These fields are: Delay, Throughput, Reliability, Cost and Future. Differentiated services (DiffServ) is a more recent model in which traffic is treated with relative priorities based on the same type of services (ToS) field in the IP datagram. The DiffServ standard supersedes the original specification for defining the packet priority described in RFC 791. DiffServ increases the number of definable priority levels by reallocating bits of an IP packet for priority marking. The first 6 bits of the ToS field are defined as the differentiated services code point (DSCP). There exists a number of class models for DSCP, some of them are described in the following RFCs: RFC2697, RFC 2698, and RFC 2598. Router companies also have their own automatic standard DSCP values. The last 2 bits of the ToS field in this case are not used for QoS. The ECN field is used for explicit congestion notification (RFC 3168).

IP Datagram
Bits Ver IP Header (minimum length 20 Bytes) IHL Identifier Time to live

Type of Service Field (1 byte)

1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
Type of service Flags Protocol Source Address Destination Address Options + Padding Source Port Sequence Number Acknowledgement Number U A P R S F Option + Padding Total Length Fragment offset Header Checksum

Destination Port

TCP Header (minimum length 20 Bytes)

Offset

Reserved Checksum

Window Urgent Pointer

Data

Figure 6

Type of Service (TOS), RFC 791 Precedence 3 Delay 1 0 = Normal 1 = Low Throughput 1 0 = Normal 1 = High Reliability 1 0 = Normal 1 = High Cost 1 0 = Normal 1 = Low Future 1

Differentiated Services Code Point (DSCP), RFC 2475 DSCP 6


Figure 7
Corporate Headquarters > 400 Godin Avenue, Vanier (Quebec) G1M 2K2 CANADA Tel.: 1 418 683-0211 Fax: 1 418 683-2170 info@exfo.com Toll-free: 1 800 663-3936 (USA and Canada) www.exfo.com EXFO America EXFO Europe EXFO Asia-Pacific EXFO China 4275 Kellway Circle, Suite 122 Le Dynasteur, 10/12 rue Andras Beck 151 Chin Swee Road, #03-29 Manhattan House Beijing New Century Hotel Office Tower Room 1754-1755 No. 6 Southem Capital Gym Road Addison, TX 75001 USA 92366 Meudon la Fort Cedex FRANCE SINGAPORE 169876 Beijing 100044 P. R. CHINA Tel.: 1 800 663-3936 Tel.: +33.1.40.83.85.85 Tel.: +65 6333 8241 Tel.: +86 (10) 6849 2738 Fax: 1 972 836-0164 Fax: +33.1.40.83.04.42 Fax: +65 6333 8242 Fax: +86 (10) 6849 2662

ECN 2

Appnote134.1AN

2005 EXFO Electro-Optical Engineering Inc. All rights reserved.

Printed in Canada 05/08

You might also like