Ensure a Fast Internet Connection When You Need It
Posted by Adam Pash at 4:00 AM on November 28, 2007

Your internet connection is an indispensable part of your life, but between BitTorrent, Xbox Live, web browsing, and VoIP, sometimes there's not enough bandwidth to go around. But rather than running around the house shutting down all of your computers next time you're experiencing a little lag on Xbox Live or Skype is breaking up on you, you can set up Quality of Service (QoS) rules on your router to distribute bandwidth to your different gadgets and applications based on your priorities. Today I'll show you how.
NOTE: Not all routers support Quality of Service settings, so check your router's manual or rummage through your control panel to see if yours does. The router I'll be using in the screenshots and in my examples is my $600-for-$60 router running DD-WRT (on this common Linksys router). If you're interested in turning your $60 router into a $600 router and using that for these instructions, you can find out how here.
Initial QoS Set Up
If you're using the same router as I am, head to your router's Control Panel, which by default is located at http://192.168.1.1, click the Applications and Gaming tab, and then click the tab labelled QoS. Alternately, you can just point your browser straight to the QoS page. If you've set a password for your router (hopefully you have), you'll need to enter it to access the QoS page.
If you're using a different router that supports QoS, browse to your Quality of Service page. (I highly recommend my router, though!)
Now that you're there, it's time to enable QoS, adjust its settings to fit your internet connection, and start adding your QoS rules. We'll start by setting up the connection.
After you enable QoS, you'll notice a slew of boxes that need fillin' out, so let's start from the top. First, make sure the Port is set to WAN and the Packet Scheduler is set to HTB (which works better than the alternate HFSC, according to the DD-WRT wiki). Now it's time to set our Uplink and Downlink speeds, which will determine how much real-world bandwidth your router will dedicate to each application. That means that first we need to get an idea of what your real-word bandwidth is. To do so, head to an internet speed test site (I like Speakeasy's speed test) and test your upload and download speeds (be sure you're not running any bandwidth hogs like BitTorrent while you run the test, as it will provide inaccurate results).
Once you've got your speeds, you should enter roughly 85% of the up and down speeds in the corresponding Uplink and Downlink boxes. So, for example, if my speed test showed that I had 7339 kbps down and 962 kbps up, I'd enter something like 6238 down and 818 up.
Finally, you'll notice a checkbox to Optimize for Gaming, which optimises your bandwidth usage for a certain set of PC games. In general, rather than taking this route, I'd suggest prioritising by application, IP address, or device—all of which we'll discuss below.
Prioritizing Your Bandwidth
You get five choices when setting your QoS priorities in DD-WRT: Exempt, Premium, Express, Standard, and Bulk. According to the DD-WRT QoS page, they prioritise bandwidth as follows:
- Exempt - This class tries to keep the bandwith and packet flow untouched.
- Premium - The top bandwidth class. By default handshaking and icmp packets fall into this class. This class should be used sparingly. Occasionally VoIP service may be placed in this class so that voice receives top priority.
- Express - The Express class is for interactive applications that require bandwidth above standard services so that interactive apps run smoothly.
- Standard - All services that are not specifically classed will fall under the standard class.
- Bulk - The bulk class is only allocated bandwidth when the remaining classes are idle. Use this class for P2P services and downloading services like FTP.
For example, you could choose to ensure at least 10% of available bandwidth to your BitTorrent downloads at all times (Standard—though it can grab more if available) while ensuring that your Xbox Live or Skype chats are ensured 75% of your bandwidth when they need it. Any application that you don't apply a priority for defaults to Standard. Now here's how to apply those priorities.
Throttle By Application
Setting priorities by application is simple. Find the section labelled Services Priority, choose the application you want from the drop-down menu (if it's listed) and select Add. If everything's set up well, that's all you need. If you don't see the application you want listed, or you want to edit a service (like the ports it uses), click the Add/Edit Service button. Then enter the name of the service, the ports it uses (you can generally find this information in an application's preferences—for example, in uTorrent go to Options -> Preferences and then click Connection in the sidebar to find the port it's using), and the protocol. To begin with you may want to try setting the protocol as L7, which attempts to detect the type of application sending or receiving data and doesn't require any port information at all, but I prefer setting the ports because L7 has been hit or miss for me.
Throttle by IP Address
You can also set priorities by IP address or even range of IP addresses (the address of your computer on your local network given to your networked devices by your router). I'm not actually sure what you might use this for except in instances where you've set up some sort of free public Wi-Fi because you're really generous—but not that generous—so I won't go into a lot of detail. That said, just enter the IP address (or if it's a range, use this calculator to determine the address range as it should be entered), click Add, and set your priority.Throttle By Device
Throttling network traffic by device is probably the easiest way to set up Quality of Service for devices dedicated to just one thing—like your Xbox, for example—or for the most important computers in your household (if you prioritise like that). DD-WRT's QoS offers two different ways to throttle bandwidth by device. You can either throttle by MAC address, a unique 12-digit identifier for every networked device, or by the ports on the back of your router.
You can generally find the MAC address several simple ways on most operating systems. In Windows, the easiest way is to open your Command Prompt and enter ipconfig /all. Your MAC address is the Physical Address. On a Mac, just open the Network Utility and look for the Hardware Address. If you're looking for your Xbox's MAC address, these instructions should help.
Once you've got the MAC address of a device you want to set a priority for, just enter it into the MAC Priority section and click the Add button. Then, like before, set the Priority from the drop-down and save your changes.
If you simply want to set priorities based on ethernet ports on the back of your router (which, naturally, will only work on your wired connections), just find the Ethernet Port Priority section, pick the port on your router you want to prioritise, and set the rate. Keep in mind that if you set all of your ports to Premium, you haven't really done anything.
The Best Setup?
There's no best way to set up your QoS on your router, and it really just depends on what you need and what you use most. I use a combination of application priorities and MAC Priorities to get the kind of setup that I want, but depending on what kind of use your network gets, you may go for a completely different setup—just try a few different ways and see what works for you. I'm pretty new to QoS, too, so if I'm missing something or if you're rolling with Quality of Service on your router, let's hear how you prioritise your bandwidth in the comments.
Adam Pash is a senior editor for Lifehacker who hates the heartbreak of lag. His weekly feature Hack Attack appears every Wednesday on Lifehacker AU.
Tags: feature | hack attack | top

Comments (AU Comments · US Comments)
There are currently no AU comments for this post.
Shoeb Ahmed
Posted 2:50 PM 27/11/07
The real firmware is called Tomato.
DD-WRT has become bloated, and has too many issues before you get a successful flash, if any.
3 bricked routers, and numerous hours wasted.
Then I came across Tomato. Smooth install, ultra smooth setup.
Shoeb Ahmed
ConstyXIV
Posted 2:47 PM 27/11/07
Is there any way to do "reverse QoS" by MAC, to make sure anyone not on your whitelist gets next to zero bandwith (or at least a speed to make unwelcome users very uncomfortable). I'd think it would be a more discrete way of ensuring you don't have any leeches over a direct MAC block
ConstyXIV
LittlestLamshi
Posted 2:39 PM 27/11/07
Thanks! I've been trying to maximize my bandwidth for my gaming needs.
LittlestLamshi
rubbsdecvik
Posted 2:37 PM 27/11/07
@Weazul: Thanks for the link. Unfortunately,it isn't a supported router, but I can live with it for a while.
rubbsdecvik
rubbsdecvik
Posted 2:34 PM 27/11/07
@A3sthetix: Unfortunately my router isn't compatible. I wish it was. I'll have to deal with this one for a while. I'm a poor college student with little to no money, so buying another one is out of the question.
rubbsdecvik
dschwab
Posted 2:19 PM 27/11/07
@laurion: Thanks for that tip. I was about to post a response on how this isn't very reliable with bittorrent and Vonage competing for bandwidth even with the proper QoS settings in place in DD-WRT, but I didn't realize that traffic encryption may be the issue I'm having.
dschwab
Weazul
Posted 2:08 PM 27/11/07
@rubbsdecvik and everyone: Check the DD-WRT supported devices list [www.dd-wrt.com], very few netgear devices are support by DD-WRT. If not check the manual of your router device.
If you still really wanted it you could just add ad DD-WRT capable router between your internet connecting device (router, cable modem, whatever) and your home computers. Sure is another level of sometimes unneeded complexity, but hey then you'll have QoS and everything else DD-WRT supports.
Weazul
lael
Posted 1:43 PM 27/11/07
QoS actually slowed me down. I have Comcast Cable, and I'm using DD-WRT. Its great. I wanted to ensure that my VOIP phone was not interrupted. QoS via DD-WRT worked well. The problem was that everything else was slower.
It turns out that Comcast has this feature called "Power Boost" which delivers the first X KiloBytes at ~ Double your speed. I missed that feature, So I turned off the QoS and upped my service since it was the upload rate that was more of a bottleneck.
lael
laurion
Posted 1:42 PM 27/11/07
Unfortunately, if you set your bittorrent to use a random port, and to encrypt traffic (as a lot of people do to bypass blocks and avoid tracking), then it is really difficult to set a QoS rule for it. You may have to do the inverse of lowering priority for bittorent specifically, and instead, increase priority for the things you want to take precedence.
laurion
A3sthetix
Posted 1:40 PM 27/11/07
@rubbsdecvik: Check the DD-WRT compatibility list: [www.dd-wrt.com]
I've had issues with QoS on DD-WRT pre v19. I have been staying away from it since, it can really take down your network. I might visit this again if I have 6 people on my network (no more roommates).
A3sthetix
dlab
Posted 1:37 PM 27/11/07
@aeronaut:
Do you have a make / model number? There may still be much that can be done. dslreports.com would be a good place to start looking...
dlab
heavylee-again
Posted 1:36 PM 27/11/07
The factory firmware in new Linksys WRT54Gs have QoS built in now.
heavylee-again
skilled1
Posted 1:26 PM 27/11/07
Great tutorial, well written, and straight to the point.
You can also go ahead and expand your cable bandwith for business at your house, an extra 20$ a month and almost triple the bandwith of regular cable internet service.
skilled1
TendoMentis
Posted 1:14 PM 27/11/07
DD-WRT actually makes this task easy. I had to figure out how to do this on the Verizon FioS Actiontec router, and it's not as simple.
But between my three room-mates on WoW, and my running my app server and VPN with the one Actiontec as the gateway, QoS is a must, so a weekend I did lose to this noble endeavor.
TendoMentis
ronnsprocket
Posted 1:04 PM 27/11/07
adam,
also, I should mention that I appreciate lifehacker and hackattack a ton.
have you considered doing a series on useful router hacks such as this. I think domestic networking is becoming more prevalent by the day, and most of us are probably missing out on some sweet features.
thanks again.
ronnsprocket
rubbsdecvik
Posted 1:03 PM 27/11/07
Is there any way something like this can be done with a WGT624v3 router (Netgear)? I was just curious. I didn't see it, and I haven't seen any way to flash it with Linux or anything.
rubbsdecvik
ronnsprocket
Posted 12:59 PM 27/11/07
this is nuts.
i was looking for this exact thing to be explained. I just moved in with a new roomate and between the two of us and xbox live, Its been terrible.
ronnsprocket
tei
Posted 12:59 PM 27/11/07
Well... QoS don't run on "magic". QoS-ish stuff don't change the fact TCP is bloated, and UDP is cool but unrealiable. QoS-ish stuff can make TCP much more bloated, and UDP much more unrealiable. This add another 10% evilneess factor. So QoS-ish stuff is now 110% evil.
This is the last warning. Now go and buy a good router for your home-lan!
tei
aeronaut
Posted 12:56 PM 27/11/07
Now, if I can get Qwest's aDSL regional router adjusted...
aeronaut
killershatner
Posted 12:32 PM 27/11/07
This sounds great, thanks for the tutorial! I wonder if my router at home has this option (I've already tried this at school and it just doesn't pan out).
killershatner
Streeks1984
Posted 12:27 PM 27/11/07
ima try this when I get home.
Streeks1984
Tetelestia
Posted 12:21 PM 27/11/07
It's a beautiful thing to see the correct use of 'ensure' instead of 'insure'.
Oh and the article is great as well.
Tetelestia
ecltech
Posted 4:22 PM 27/11/07
@Shoeb Ahmed: Try the mini version of the DD-WRT firmware if the standard is too bloated. I also agree with you on the Tomato firmware. It's not bloated, do what it's suppose to, has a nice QoS setup and I really like their Bandwidth measuring feature. DD-WRT add this to the latest Release Candidate and it works but I like the historical data that Tomato stores. I can get the same thing installing a 3rd party app on DD-WRT but having it built-in is better. :)
ecltech
TendoMentis
Posted 4:05 PM 27/11/07
@Shoeb Ahmed: I guess it depends on the router and version you tried to install.
Currently, I'm using DD-WRT v23sp2 on all my routers and they went in clean and easy. Bloated....don't know about that. If by bloated you mean chock full of creamy-admin-options-goodness, then you are correct.
I've heard good things about the Tomato firmwares too, but if you want the most options stick with DD-WRT.
TendoMentis
rasti
Posted 3:53 PM 27/11/07
Nice post.
Especially useful if you run a cybercafe
rasti
Luziphir
Posted 5:14 PM 27/11/07
To anyone considering making the $60-for-$600 router mentioned in this article: Get Tomato, not DD-WRT. It's a lot more stable and functional, especially when ti comes to QoS.
Luziphir
awdark
Posted 6:10 PM 27/11/07
The configuration for the DDWRT seems far easier to understand than the one included with my Dlink dir-625 router... that one has a bunch of weird extra options. Is there a way to really test if the QOS config is working?
awdark
aeronaut
Posted 10:24 PM 27/11/07
@dlab: At home, my system runs fine; I was joking about the router that Qwest has for this part of the city.
aeronaut
Fallen_Reality
Posted 2:32 AM 28/11/07
My wireless connection seems to have stopped working. I used a Lynksys WRT54GS v6. It works great for my wired computer, but my Wii and DS cannot find it. Any help? I decided to do the 60$-600$ thing and did it correctly.
Fallen_Reality
spuddude
Posted 11:30 AM 28/11/07
I just purchased a Linksys DD-WRT capable router from Amazon and I'm waiting for it to arrive. Thank you for the timely article Adam!
Now, I'm conflicted as to whether to use DD-WRT or Tomato. Are there any good guides to help in making the decision?
By the way, I LOVE all of the input given by so many LifeHackers!
spuddude
ecltech
Posted 12:58 PM 28/11/07
@spuddude: In deciding if to use DD-WRT or Tomato, try them both. It's one of those things that I think it's personal choice and depends on the features/functions you need. Tomato has the basic functionality and works great. It's stable. I've had it running for over 4 months with no problem but went back to DD-WRT because I needed multiple SSID support. DD-WRT also have features such as wireless HotSpot, additional services, etc. Just take a look at both, try them out and see which one meets your needs and works best. :)
-Mike
ecltech
EddieStarr
Posted 7:04 PM 27/11/07
I have comcast in South Sacramento . . . 19650 down and 1875 up
EddieStarr
awilsonx
Posted 5:49 PM 27/11/07
FWIW, there are DD-WRT routers for sale on eBay. I bought an RCA router with DD-WRT installed about a year ago off eBay to get a Linux PC to connect to my native Linksys router wirelessly. I forget the DD-WRT tweak, but I connected the PC's NIC card to the DD-WRT router with a wire and then the DD-WRT router could communicate with my native Linksys router.
awilsonx
spuddude
Posted 1:02 PM 28/11/07
Thank you Mike!
You also answered the second question I had which is can one change back and forth.
I'm inclined to try DD-WRT first as I'd like to play with the VPN capabilities. :-)
Thanks again!
spuddude
jesterpb
Posted 6:09 PM 30/11/07
Worked great for me. I've got the TMobile Curve with wi-fi, and have been wanting to set up QOS by MAC. Thanks for the assist.
A question: How do you set the priority for Firefox? I don't see any browsers in the services section.
jesterpb
takemetoyourtoaster
Posted 9:25 AM 1/12/07
hey i don't know my username or password for the router, how do i find out, i'm on a mac
takemetoyourtoaster
vsolis
Posted 4:57 PM 1/12/07
@jesterpb-i would think you would want to just give port 80 express of premium class of service.
vsolis