NOTE: I no longer use DD-WRT and am unable to answer any questions about it.
On my ASUS RT-N16 router, I run the open source DD-WRT firmware rather than the ASUS firmware. Why? Well, lots of reasons actually. This router, like the others, is on all the time so any service it provides is available all the time. DD-WRT provides the following features the ASUS doesn’t.
- Local DNS. It can answer name queries for local devices on my network in addition to forwarding external name (ie: web) queries.
- Custom DDNS updater. At periodic intervals the router checks the WAN IP and reports any change to OpenDNS. I use OpenDNS as part of allowed content filtering solution into the home.
- Bandwidth management (QOS – quality of service) on a per device basis, as well as group settings
- Web server (small but enough to serve some static pages). I have a couple of pages that I serve up so any device can get access to them.
- Network time server. It stays in sync and all the network devices can query it.
- Reporting. At any given time I can see what the months ISP bandwidth utilization is. In a world of data caps, this helps. And the ability to see whats happening through the router in real time.
Enable JFFS:
Before you can really make use of the local DNS or web server functions, you have to enable JFFS2. This will tell you how. Follow it exactly. It’s expected that the base configuration is already complete.
- Login to the router web page.
- Click Administration.
- Look for the “JFFS2 Support” section.
- For the JFFS2 option, click the Enable radio button.
- Click Save at the bottom. Wait a few seconds. Once the screen refreshes, click Apply at the bottom and wait again.
- Look for the “JFFS2 Support” section again.
- For the “Clean JFFS” option, click the Enable radio button.
- DO NOT click “Save” at the bottom! Instead, click Apply at the bottom. The router will format the available space. Wait until the web GUI is back which may take a minute or two.
- Look for the “JFFS2 Support” section again.
- For the “Clean JFFS” option, click the Disable radio button.
- Click Save at the bottom.
- Click the Administration tab.
- Click the Maintenance tab.
- Click Reboot Router at the bottom.
After the boot is complete there will be a “/jffs” filesystem present. It will have a “tmp/ipkg” directory in it which you can ignore. Just leave it there.
Populate Persistent Data:
Now you can create a storage location(s) in the JFFS filesystem to hold those things you want to preserve across boots (ie: hosts file, startup scripts, web pages, etc).
Login via ssh as root, then create the directories. I created these.
cd /jffs mkdir etc mkdir bin mkdir web
Now you can scp the files you need into those directories, or use vi and create them manually.
I’ll expand on making use of this in another post.
Pingback: Using DD-WRT for Local DNS and DHCP | c0mm0n b1ts
Too bad not all versions of dd-wrt come with JFFS installed – mine for the DIR-632 does not 😦
Having JFFS operational is not a requirement for local DNS to work. If you have NVRAM enabled for DNS, that can work sufficiently as well.
It is if you are supplementing the DHCP assigned addresses with a list of static ones, as I am doing.
Pingback: Using DD-WRT for Local DNS and DHCP | Unfinished Bitness
Pingback: Fixing DNS Rebind on DD-WRT | Unfinished Bitness
When logging in with SSH and cd /jffs, I have read only filesystem errors when trying to create the directories as per the instructions.
I tried to chmod 777 /jffs, but I have the same error coming up.
How do you go from there?
Check or repeat steps 6 through 10. They MUST be done in order. You may want to disable JFFS, save, apply, and reboot and start over. Ensure you are at the root / directory before trying to chmod the jffs directory. I didn’t have to change its permissions. Its possible your also using a newer build than I did.
Can you indicate me a cheap router that supports dd-wrt with jffs, please?
thanks
The DD-WRT website has a list of compatible hardware. You’ll have to shop the list.