SEARCH

How-To Geek

How to Prioritize Your Network Traffic with DD-WRT

banner-01

Having a media server is really awesome, unless the other people on your network don’t know how to share the bandwidth. Using some simple QoS rules, you can give your computer a priority and stop your streams from dropping out.

If you have a media server or a HTPC that streams, you’ll obviously want to make sure you can watch your content without having it stutter or drop out. The problem is, with a ton of devices on your network, the bandwidth on your HTPC needs a priority. Alternatively, maybe you have a kid who streams a little too much and is sucking up more than his or her fair share of bandwidth. You can throttle the connection to one computer without messing with the rest.

Because this tip can be used to unbalance your bandwidth as well as balance it, we urge you to exercise caution and restraint. With the great power of QoS and DD-WRT comes great responsibility.

Prioritizing via MAC Address

Using a computer’s MAC address is a great way to prioritize its traffic because it will work even if its IP changes. However, this really only affects prioritization if the connection is initiated from this hardware address. That means if traffic was initiated elsewhere, our settings won’t make a difference even if the destination is this particular computer. As such, this works well when trying to add importance to traffic that a computer starts, like streams, and is less effective for things like throttling torrents.

Open up your browser and head over to your DD-WRT-enabled router’s login page. Click on NAT/QoS and then QoS. This will bring you to the Quality of Service page.

sshot-1

Here, you want to make sure that Quality of Service is enabled, it’s set to WAN, and you’re using HTB as the packet scheduler.

You also want to set the Uplink to somewhere between 80% and 95% of the max upload bandwidth you have. The Downlink should between 80% and 100%. In theory, you want to make sure that if there’s a bottleneck in speed going into or out of your network, it’s at the router so that it can be managed.

Next, head down to the MAC Priority section.

sshot-2

Enter your computer’s MAC address. If you’re not sure how to look it up, check out our article on Static DHCP and scroll down to see how to find your MAC address.

sshot-3

Then, you can just set the priority. You can set it to Premium or Express, both of which will vastly improve the speeds your computer will get.

Prioritizing via IP Address

When you change priorities via IP address, DD-WRT will manage all traffic, not just traffic that is initiated by that particular computer. This means that receiving IMs, torrenting, and other traffic that the computer is receiving that may start from an outside source is affected. As such, you can use this method to deprioritize a computer on your network much more efficiently, though the consequences can be made more severe by utilizing specific choices. This method works very well with a Static DHCP setup, so that IP addresses are tied to individual computers and they don’t change.

Follow the above instructions, but instead of going to the MAC priority section, go down to the Netmask Priority section.

sshot-4

Add the IP address of the target computer, followed by the mask. The mask will tell DD-WRT what length of the IP address to apply the rule to. For example, a mask of 24 will change the priority for 192.168.1.x addresses, and a mask of 32 will change the priority of a single IP address. You will likely want to use 32.

sshot-5

Next, you can change the priority. If you want to increase it, choose Premium, as that will work best. If you wish to lower it, choose Standard and use this in conjunction with a prioritized computer elsewhere on the network. If you really want to be mean, you can choose Bulk for severely deprioritized traffic. Choosing Bulk will only allocate significant bandwidth when all other classes are not receiving traffic. This is perfect for a BitTorrent or FTP server on your network, as well as forcing a misbehaving user to come talk to you about reduced bandwidth.

 


DD-WRT offers a few unique ways of shaping your internet traffic. We’ve had a few requests specifically for increasing and decreasing traffic priority for specific computers on your network. Once again, we suggest you use this responsibly.

 

Do you have any stories where this could have helped your situation? Share your experiences in the comments!

Yatri Trivedi is a monk-like geek. When he's not overdosing on meditation and geek news of all kinds, he's hacking and tweaking something, often while mumbling in 4 or 5 other languages.

  • Published 08/16/11

Comments (7)

  1. Kevin

    I’ve tried to set this up in the past, but every time I try to use an application that uses a lot of connections (bittorrent) it brings my network to its knees. Even setting the router to ignore the computer that’s using bittorrent QoS wise. I’ve always suspected it’s because my router doesn’t have the power needed to handle QoS with that many connections going.

  2. dima

    I have DD-WRT and QoS never works for me

  3. Screwtape

    Can anyone point out a good guide for QoS on Tomato flashed routers?

  4. Screwtape

    Nevermind, forgot about the guide published about a month ago.
    http://www.howtogeek.com/67943/5-tips-for-getting-the-most-out-of-your-tomato-router/

  5. ron9

    You find it under tutorials on tomatousb homepage!
    http://tomatousb.org/tut:using-tomato-s-qos-system

  6. Edward Allen Weissbard

    @ dima-I’ve had issues with QoS and DD-WRT in the past as well. It’s been awhile since I’ve tried. The issues may have dealt with with some of the new builds. When was the last time you’ve used QOS in DD-WRT?

  7. herpderp

    QoS on DD-WRT blows chunks. Its a fat joke and that’s all there is too it.
    I have a different version of DD-WRT that came with my buffalo router and it looks nothing like the screen shots above. It doesn’t have a drop down box for Priority. It just has max kbits Up&down but they do NOTHING to throttle speeds.

Enter Your Email Here to Get Access for Free:

Go check your email!