A n00bs guide to QoS

QoS or Quality of Service as is defined by Wikipedia states :
In the field of computer networking and other packet-switched telecommunication networks, the traffic engineering term quality of service (QoS) refers to resource reservation control mechanisms rather than the achieved service quality. Quality of service is the ability to provide different priority to different applications, users, or data flows, or to guarantee a certain level of performance to a data flow. For example, a required bit rate, delay, jitter, packet dropping probability and/or bit error rate may be guaranteed. Quality of service guarantees are important if the network capacity is insufficient, especially for real-time streaming multimedia applications such as voice over IP, online games and IP-TV, since these often require fixed bit rate and are delay sensitive, and in networks where the capacity is a limited resource, for example in cellular data communication.
In layman’s term QoS is the process by which you set some pre-defined rules which determines which data packets are to be allowed first based on their priority level.
For example consider yourself to be an avid Bit-Torrent as well as a VOIP user. Now suppose you want your VOIP experience to be of excellent quality (i.e. of the same level when you are not downloading anything) even when your Bit-Torrent is running in the background with heavy downloads. How do you do it? Simply by configuring QoS in a fashion that it gives the VOIP traffic a higher priority level than the Bit-Torrent traffic.
Now i give you a real case scenario. I surf a lot and at the same time would like to have my Bit-Torrent running at full force in the background without hampering my surfing experience.I am on Reliance UL 400kbps plan. So practically i get anything between 40~55kbps on torrents with the average being around 38~48kbps (applicable for well seeded torrents also). Now previously with no QoS configured my surfing experienced sucked big time. Pages would take a long time to load as most of my bandwidth was blocked by the Bit-Torrent traffic. After configuring QoS (as per my needs) my pages load as if there is nearly no Bit-Torrent traffic hogging but at the same time the torrent download continues in full fledged.
I use a Linksys WRT54GL Wireless-G Broadband router. I flashed my router with the Tomato firmware since its implementation of QoS is far better than the stock firmware of Linksys.
P.S : The images shown below are for the BSNL UL 256kbps plan that i was using previously. Right now since i have shifted to Reliance UL 400kbps. So the images might have a bit of discrepancy in the data [I will notify of the discrepancy as and when required].
Also i am using Tomato 1.23 since that is the latest version and i upgraded to that.
WRT54GL running Tomato 1.19
This is my break up of the QoS traffic classification which works best for me.
Now majority of my traffic is generated by the Bit-Torrent, so i have set all the Bit-Torrent, eMule and other bulk Traffic as Lowest class.
Also since i want my surfing experience to be of top-notch quality hence i have set the DNS query port to the Highest class and the HTTP,HTTPS,FTP and Telnet ports to the High class.
This effectively translates that even with torrents running at full blast any DNS query made for any site is always allowed first to be resolved followed by the display of the page and then the Bit-Torrent Traffic is allowed to pass-through. This improves your surfing experience a lot since the request for the web pages always gets priority over the Bit-Torrent traffic.
Since its been a long time i have not played on-line, so my configuration does not include any for the games or Steam.
In case you want your gaming experience to be good in spite of downloads going on make sure you set the port required by Steam or the game to the Highest/High class.
Setting QoS Outbound/Inbound rate
The below setting show my outbound and inbound rate for my connection. As you might have known the UL plans from Reliance have symmetrical upload and download speeds. So as per that my outbound and inbound max bandwidth should have been 400kbps. But keeping in mind the real world scenario i have put the values at 90% of the max/advertised values which comes for my case to be 360kbps. This is because mostly the end-user gets around ~90% of the advertised bandwidth.
P.S: The images below show the Outbound and Inbound Max Bandwidth as 230kbps since the images were taken when i was using the BSNL UL 256kbps plan. After I changed my plan to Reliance UL 400kbps and upgraded the Tomato Firmware to 1.23 i felt lazy and did not take the latest screen shots. So do bear with the old images. ![]()
Another way you can set the inbound rate is to set all the class limits to none. This basically means inbound filtering is turned off and all the classes get maximum inbound bandwidth.
The above screen shot shows WRT54GL with Tomato 1.19 and with no inbound filtering configured in QoS.
I have tried to make this guide as precise and easy as possible and in the process may have missed out on some finer points.
If you happen to have found out anything missing do point it out so that I can add it to the post and make it much more enhanced.
Lastly hope that this guide will help you guys set up QoS on your routers if it supports and you can use this as a reference for your router settings.
Happing surfing…





Although it is pretty obvious, the order on the \Classification\ page is the order they are applied, so make sure Bulk Traffic is at the bottom, otherwise it will catch everything and the filters underneath will not be applied, I didn’t realize this when I first set it up, but it’s clear after looking at th graphs and seeing the usage for each category.
@pceasies: Thanks for pointing out that from your own user experience. Hope others will find your point useful
Thanks a bunch for pointing this out! I have been wracking my brain trying to figure out why my traffic didn’t seem to be classified correctly. After I saw your post I was like *facepalm* “Why didn’t I think of that?” Once again, thanks a lot!
Only want to say your article is impressive. The clearness in your post is simply impressive and i can assume you are an expert on this field. Well with your permission allow me to grab your rss feed to keep up to date with succeeding post. Thanks a million and please keep up the fabulous work.
Thanks a lot
Keep up the good work!
Thank you for the great post!
Thanks that you liked it
I love to read articles that are informative, Thanks again for a nice site
Exceptional post. My family and I were just talking about this the other day. Also your page looks nice on my old palm treo. And thats rare. Nice work.
very informative thank you
Hello, great point. Posts like this one are why I follow your blog. Have a great 2010!
It was a really nice thought! Just wanna say thank you for the selective information you have diffused. Just continue writing this kind of post. I will be your loyal reader. Gives Thanks over again.
Hi Adolfo,
Thanks a lot that you loved the post
nice article, check out my sig for my new blog
Thanks that you liked it….
I really liked reading your post!. Quallity content. With such a valuable blog i believe you deserve to be ranking even higher in the search engines
. Check out the link in my name. That links to a tool that really helped me rank high in google. This way even more people can enjoy your posts and nothing beats a big audiance
You are welcome…
Many thanks for the post. I liked it. You have a very nice website.
Thanks and you are welcome..
Thanks for great post! Will be bookmarking this article for future reference!
Thanks that you liked it …
Just landed on this post via Google search. I love it. This post switch my perceptual experience and I am fixing the RSS feeds. Cheers.
How long has this blog been around? I have been searching for this kind of information for the past week and a half.
Was reading this on the bus while I was searching through QoS guides and I have to say, it’s very impressive. Awesome work!
I was wondering if this would be similar if I were to place limits on separate computers in the same network and not just within on computer.
Hi Andrew,
See i have used that on my router.
I don’t know what you are trying to achieve is possible or not..if you are successful then do tell me …
I have been interested in this. Good on you for posting it.
Hi James,
Glad that you liked it
no facebook like button?
Nopes
I can’t tell you how impressed I am with your article. Your insight and unique ideas have inspired me to think about many things contain here. Thanks for this info.
I used to be very pleased to find this internet-site.I wished to thanks on your time for this glorious learn!! I undoubtedly having fun with every little bit of it and I have you bookmarked to check out new stuff you weblog post.