Playing around with DD-WRT

I finally got around to trying DD-WRT. I have a friend who raved about it and I always meant to learn a little more about networking, but I just never got around to it until now. My major motivations for doing it now:

  • Friends/family coming over wanting to use the wireless; but I don’t want to tell them my password and don’t particularly want them on the same network as my other stuff. So I want to offer multiple SSIDs and segregate networks.
  • OK, this isn’t really specific to DD-WRT, but my old router only supports WEP “security” – needed to get with the times!
  • Want to set up outgoing VPN connections at the router level instead of doing this per machine (having this is another good reason to isolate visitors from the main LAN).
  • And hey, a local VPN accessible from the internet too, though most routers probably do this out of the box?
  • Static DHCP and DNS allocations so all my devices get names without having to cart around a hosts file or set up my own DNS server. Since I’ll be setting up a ton of VMs this is kind of important.
  • Ability to set up virtual LANs and fiddle with various networking things I don’t really understand yet.
  • Ownership of my router. Ability to do all this stuff on my terms instead of with whatever capabilities the manufacturer deigns to put in the thing (reserving the best for a more expensive model).

I am not foolhardy enough to try this with the router I currently have in place and risk having no internet connection except my phone. After a little searching on Amazon (having Prime pretty much rules where I look for things now) I decided on the Linksys WRT160N. This looks pretty decent even out of the box, and for $31 I wasn’t going to cry much if I bricked it. I didn’t have any way of knowing which version I’d be getting – according to the router database v1 and v3 are supported, but not v2 – but as luck would have it I got v3.

The installation guide for DD-WRT in general (and the “Peacock” thread) is full of all kinds of warnings about how you need to read *everything* on the wiki to avoid bricking your router. In that way it’s worse than manufacturer manuals! Sorry, fellas, I know you’re trying to help but it’s a bit much. The main thing I got out of this is that it’s really important to do a 30/30/30 reset before and after flashing the firmware.

The basic procedure for flashing DD-WRT onto a router from scratch is as follows:

  1. Comb the DD-WRT site for all the instructions and firmware images you’ll need, and have them on your computer before you try to do anything.
  2. Connect your computer to the router with a cable (doing it wirelessly isn’t gonna fly).
  3. Do a 30/30/30 reset on the router.
  4. Using the router’s standard administration UI (which allows you to reflash firmware in order to enable manufacturer updates), flash the first firmware image – this will usually be a special bootstrap image (or a “kill image”) just to make the transition off the factory router firmware.
  5. Do a 30/30/30 reset on the router.
  6. Now using the DD-WRT UI, flash the real firmware you’ll be using. You may not have a lot of choices – I had two listed in the router database.
  7. Do a 30/30/30 reset on the router.
  8. Start looking through all the crazy options DD-WRT offers, and enjoy!

The specific instructions for the WRT160Nv3 are pretty succinct and I got things working pretty quickly. Yeah – it’s really not too bad! I had it working right away with only one hitch – my browser kept caching the “apply.cgi” page which is used to alter settings. The cached page was simply blank and doesn’t actually apply anything (of course). There used to be a simple way to clear cached items in Firefox but it doesn’t seem to be in the settings anymore – maybe it’s extended settings or needs a plugin now. I solved it simply by setting up a /etc/hosts entry for the router and referring to it by a new name.

DD-WRT offers the capability to set up virtual SSIDs, but this is a little trickier than the interface would have you believe. Once you create a virtual SSID, at least if you want to isolate it as I mentioned above (and why else would you want to do this?), you need to do some hackish stuff. I found a guide here that was very helpful. Alas, I think my stock G1 phone ran afoul of some of the problems with virtual SSIDs mentioned there, because it holds onto the main SSID from an early configuration I tried and completely refuses to see the new setup (even after I manually entered the SSID and WPA2 password for it). My modded G1 seems to see everything fine as does my laptop. I will probably have to play around with SSID visibility to get this right (or – mod my stock G1 – but it’s my main phone currently and I’m reluctant to lose all my settings etc.).

The DD-WRT help that comes with the firmware (displayed from the UI so you don’t even need working internet) is pretty decent (to say nothing of the help you can find on the internet). There is an unbelievably variety of features built in. This should keep me busy for a long time!


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: