Local DNS Server using DD-WRT | Buffalo Routers

August 13, 2017

A local DNS will help a developer to access and test the applications across local network having to worry about hostnames (Especially mobile devices, where updating host files may force one to root the devices)

This time we will see how a local DNS could be setup using relatively cheap WIFI routers running DD-WRT firmware

I am using a Buffalo router that acts as a WIFI access point at my home.

image

Make sure you are running the latest available firmware for the device to insure maximum stability. Once the firmware has been updated to the latest, Click on Services and you will be landed on Services page. Setting up the local DNS is most effective when you have all your “Computers” have static IP allocation (As seen with below image)

 

image

Don’t worry about the lease time parameters, as long your computers are having static IP addresses, these entries work as ‘A’ records, letting you to access the computers by their name, instead of IP addresses.

Set Used Domain as “LAN & WAN” & provide a meaningful name to “Lan Domain”. This name will be appended to your hostnames when you do a simple ping like commands. For example, when I try to ping “rajesh-pc” from command prompt, “rajesh-pc.my.home” will be automatically generated incase if you set up parameter “expand-hosts” with Additional DNSMasq options (Check below image)

 

 

image

Save the settings & apply. You are all set to start using the local DNS server. Whenever you have a new host, access the services page and create a static host entry (one time) & your last device is accessible using a name, instead of IP addresses.

 

Regards,