It is easy to add static DNS entries to the dd-wrt GUI interface. Follow the below simple steps and then reboot your router. In the below directions the dd-wrt version is v24-sp2.

  1. Login: First login to your wired or wireless router that is running dd-wrt software.
  2. Open Services: Click the “Services” tab which will default to the “Services” sub tab as well.
  3. Modify DNSMasq Settings: Scroll down to the “DNSMasq” section.
  4. Enable DNSMasq and Local DNS: Select the radial button next to Enable for both “DNSMasq” and “Local DNS”. Then click the Save button at the bottom of the screen.
  5. Add Static DNS Entries: In the “Additional DNSMasq Options” text field add entries in the below format.
    address=/host.domain.com/secondary.domain.com/192.168.1.10
    address=/router.domain.com/wrt54g.domain.com/192.168.1.1
    

    Note you can add multiple names for each IP address separating with a forward slash. Multiple entries are created just by adding a new line as shown above. Now click the “Save” button at the bottom of the screen.

  6. Save, Apply, and Reboot: Now click “Save” button followed by the “Apply Settings” button. Next click the Administration tab, scroll to the bottom, and click the “Reboot Router” button.

This is a great feature for adding static DNS entries for your local network. You can verify DNS is operational on the router after enabling DNSMasq by port scanning the device and making sure that it is now listening on port 53.

To test from a windows client open a command prompt and type the below. In this example the routers IP address is 192.168.1.1.

C:>ping router

Pinging router.domain.com [192.168.1.1] with 32 bytes of data:

Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64
Reply from 192.168.1.1: bytes=32 time<1ms TTL=64

Ping statistics for 192.168.1.1:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms

C:>
DeliciousStumbleUponDiggTwitterFacebookRedditLinkedInEmail
Tags: , , , , , ,
4 Responses to “Add Static DNS Entries to DD-WRT Router Firmware”
  1. Sonal says:

    Actually, I have a Time Capsule heokod up to the Motorola, then an iMac directly connected to the Time Capsule, and an iPhone (and occasionally a Macbook Air) connected via wifi. The wifi is off on the Motorola, and I use the Time Capsule to create the WAN.

    [Reply]

    alex Reply:

    Hello Sonal,

    Ummm OK. Was there a question here or just making a comment about your network?

    Thanks.
    alex

    [Reply]

  2. Linus says:

    My DD-WRT router doesn’t have a “reboot” option on the Administration tab. Also, it ignores the static DNS settings, opting to use whatever it gets from the ISP instead.

    [Reply]

    alex Reply:

    Hello Linus,

    Sounds like you might have a buggy older version of DD-WRT. My suggestion would be to update the DD-WRT firmware.

    Thanks.
    alex

    [Reply]

  3.  
Leave a Reply

*Type the letter/number combination in the abvoe field before clicking submit.

*