9.1. QoS Past and Present
In traditional telephony, quality of service for each and every phone call is guaranteed by the constant availability of dedicated bandwidth. Whenever a channel or "loop" is established across the network, the bandwidth allocated to that channel is steadfast and unchanging. Most digitally encoded call paths on the PSTN use the same codec, G.711, so transcoding isn't necessary. Almost no processing bottlenecks will be found on the PSTN, and since the system isn't generally packet-based, there is almost never degradation in perceived call quality as a result of congestion.
If the PSTN and SS7 can't establish a full-bandwidth path through the network, the call just doesn't get connectedand the caller hears a busy tone. The designers of the PSTN felt a breakdown of connectivity would be preferable to a breakdown of quality.
Of course, packet networks work the other way. When bandwidth availability drops , as more packets are sent on the network, throughput slows. Until a certain breaking point, bandwidth availability can be compromised while still allowing data through; the transmission just slows down. Some applications tolerate congestion and slow throughput better than others. The more tolerance an application has, the higher its error budget is said to be.
Slowness of transmissionlatencyis the enemy of Voice over IP, and one of the key contributors to failure with the technology. Aside from careful network design and bandwidth provisioning, which are factors in building any IP network, there is an elegant solution to the latency problem, one that allows local and end-to-end guarantees of bandwidth and prioritization of real-time traffic over less sensitive traffic. This chapter covers that solution, which comes in the form of QoS protocols and standards: 802.1p, 802.1q VLAN, DiffServ, RSVP, and MPLS.
220.127.116.11 Call-quality scoring
Historically, the quality of phone calls' audio has been measured using the mean opinion score (MOS) from a group of listeners. These listeners hear sound samples from calls of varying quality, recorded during different sets of network conditions. A sound sample from each set of conditions is played for the opinion group, and each rates the sample's quality on a scale of 1 to 5, with 5 being the best quality. The conditions that can be used to alter the quality of a sound sample are choice of codecs, transcoding combinations, packet interval, and packet loss rate.
Using the MOS technique, researchers have determined that, with no packet loss, G.711's highest perceived quality score is 4.4. By comparison, G.729A's is only 3.6. But, when packet loss occurs, G.711's resilience stands out, as in Figure 9-1. There are other quality scales for gauging phone calls, but the MOS scale is still the most commonly used.
Figure 9-1. Packet loss has a direct negative effect on call quality (source: Nortel Networks)
It is unlikely that you'll need to use the MOS scale to grade call quality on your VoIP network. But it's important to note what the scale says. As you can see in Figure 9-1, you don't want to use G.729A across an ultrafast Ethernet link because the quality perceived by your system users will be lower than it ought to be. It also illustrates that you must arm your IP network against congestion.
18.104.22.168 How you can use the MOS scale
MOS can aid you in rating the perceived quality of your legacy system. Not all system builders will have the time or inclination to do this. But, if you support more than a few- dozen users or if call quality can vary depending on the call path, you should determine the MOS rating of all call paths on your current system. Ask a group of users to place calls across each call path and then record their MOS opinions of each call.
Do this before you replace your legacy links with VoIP. This way, you can use the scores as a guide when selecting standards and equipment for your new VoIP system. You can also tell whether you've succeeded in replicating the call quality you had before you started to replace legacy equipment.
After the implementation, particularly in large corporate or carrier-class networks, establish an SLA (service-level agreement) between you and your users that provides an MOS expectation for every call path that meets or exceeds that of your legacy system.
In traditional telephone networks, like the PSTN, the MOS scale was used to give engineers feedback that could be used to improve perceived quality. One of the biggest factors in perceived quality is noise. VoIP itself doesn't increase or decrease noise in the traditional sense, except where digital signal processing is applied specifically for noise reduction.
Noise can be added to the phone circuit at many points. Consider a phone call placed from a loud factory floor. The person making the call will likely jam the phone receiver up to his ear as closely as possible, while plugging his other ear with a finger, all so he can hear the call more easily. What he's doing is noise reduction . There are electronic methods for noise reduction, too, but none are really specific to Voice over IP.
But VoIP does introduce new kinds of noise, broadening the traditional definition to include everything shown in Figure 9-2. Noise includes not only background noise and signal interference, but also a wide range of new elements that change the perception of the sound in the telephone earpiece. These noise elements can be momentary, like a short burst of packet loss, or permanent, like transcoding distortions that occur when the lossiness of a particular codec is compounded by the lossiness of a second codec. The resulting signal may sound robotic or machine-like.
Figure 9-2. Sources of noise occur at almost every OSI layer
When noise alters a signal, the signal is said to be distorted . Distortion can be either additive or subtractive, meaning that the strength or amplitude of the sound is increased or decreased by the distortion. Additive distortion sources are things like background noise and amplification, while subtractive distortion is caused by signal loss and attenuation.
Thankfully, a PhD's knowledge of electromagnetics isn't essential. As an enterprise VoIP maintainer, it's probably enough to know that, while noise cannot be entirely avoided, it should be minimized. One of QoS's roles is to help you avoid situations in which poor service at the lower layers of the network results in additive or subtractive noise.
Some noise elements cannot necessarily be improved by VoIP QoS techniques, because they aren't exclusive to VoIP environments:
Using an IP network as a transport for voice can indeed impair the sound signal, and this is where network QoS measures come into play. Since IP networks weren't originally designed for "reliable," real-time, and connection-oriented transmission the way the PSTN is, QoS measures can make up for IP's shortcomings and make for a network that is actually more resource- sparing than the PSTN could ever be.
9.1.3. QoS is Two Things
Quality of Service is both a network design concept and a set of standards for bandwidth reservation on the network. The QoS concept deals with fundamental detractors from qualitylike packet loss and latencyand their cure: sound network design. This means providing enough bandwidth and proper physical and geographic organization of network traffic. Indeed, most network engineers, when faced with bottlenecks, instinctively seek to add more bandwidth. There's nothing wrong with thatit's just not the most elegant or cost-effective way of dealing with the problem. As a result, many network engineers overbuild from the get-go, and this can be a waste. After all, it's quality of service that's needed, not quantity of service.
The QoS standards , on the other hand, are specific network protocols that provide quality measures such as bandwidth reservation and packet prioritization.
22.214.171.124 Does overcapacity remove the need for QoS?
Some system builders approach the Quality-of-Service challenge by building a network that has so much capacity that quality problems are unlikely to occur. This may indeed work for web surfing and database apps, but it doesn't always work for voice. Besides, it's foolhardy to assume that, just because you're building your network big, you'll never need to manage bandwidth on it. QoS measures help you do the managing.
A second argument against overcapacity is in the cost of infrastructure. Installing a 10 gbps Ethernet switch is a less efficient method of ensuring on-time delivery of voice packets than a much cheaper gigabit switch that's coupled with a QoS measure or two.
Transistor technology doubles computer processing capacity once every few years , resulting in a constant upgrade cycle that yields ever more powerful computer hardware and software. When new, faster processors come to market, they are usually prohibitively expensiveand so are new, bigger-capacity networking devices. As is often the case with the latest Pentium iteration, it pays to wait a few months or a year until the cost of high-capacity network gear drops.
This way, your cost per megabit stays low. QoS can help you slow the costly cycle of infrastructure growth on your network. If money is tight, wouldn't you rather use your project budget for user -pleasing telephony features than for additional bandwidth that will be 30% cheaper a year from now?
QoS protocols approach this matter with an assumption of limited bandwidth resources. Their purpose is to increase the availability of the network for high-priority traffic. Sometimes, this just means handling voice packets before handling other kinds (precedence); other times, it means allocating a logical channel of dedicated bandwidth across the entire network from caller to receiver just as the PSTN does during call-setup for a long-distance call (bandwidth reservation).
Several protocolsRSVP, MPLS, DiffServ, and 802.1pprovide different approaches to QoS. Some of them work on a coarse, or single-link basis. Others work on a fine, or end-to-end basis. These two basic types of quality measures are described in Table 9-1.
Table 9-1. Class of Service versus Quality of Service
In Table 9-2, the QoS standards are compared and contrasted.
Table 9-2. Quality of Service standards compared