1

It's really great letting DNSMasq take care of DHCP / DNS, as it "just knows" everything... as it should, considering it dished out the addresses to the hosts...

However, it seems (to me) - impossible to separate the "routing logic" from the DHCP portion of the program for most SoHo routers..

For example -

  1. A location's router cannot run DNSMasq.
  2. The LAN is served by a single IP / connection with NAT routing handled by WAN gateway router...
  3. Internal DNS and DNS forwarding is provided by an Internal host, possibly with ports 53 forwarded to it, etc.

  4. I've been too sure it would't work to ever try, but can you hand off the DHCP addressing responsibilities to the internal DNSMasq server (on a private IP), while still allowing a dedicated hardware router to serve as the external gateway..?

It seems like the address allocation is inextricably connected to the address allocation process, but that just seems so primitive..... Would a router be able to figure out the port-mapping and create the routing tables, if it had not allocated the addresses itself, possibly ARPing the whole thing as it goes along, or something?

0

1 Answer 1

0

Here's a quicky: If you can change the starting options of the dnsmasq daemon it supports what you're asking for: for disabling internal DNS caching -p 0 will facilitate that setting the dhcp option 6 (DNS server) and option 3 for the outbound gateway.

I would suggest looking at DHCP3-server on a cheap box, but that's just me. If this is what you've got the below should do the trick.

dnsmasq -p 0 --dhcp-option = 6,[ipofdnsserver] --dhcp-option=3,[ipofgateway]

(fyi dnsmasq man page: http://www.thekelleys.org.uk/dnsmasq/docs/dnsmasq-man.html)

2
  • Right... But will that be enough for the router to perform it's port mapping functions, etc... Traditionally, the Router has been performing those forwards based on static private allocations in it's own configuration... How can those same forwards be specified if the router isn't handling that address space's reservations? Would it be able to handle the dynamic port translation, but not static, possibly? DNS is not the issue, it's the routing / forwarding that seems iffy.
    – mralexgray
    Jun 11, 2011 at 18:08
  • If the head end is performing it's job with static nat to an inline soho then you'll need to define a dynamic nat rule to get your traffic out. If you're performing PAT down to some devices in your DMZ (or heaven forbid into your network proper) then you've gotta figure out how to define those. Ultimately what gravyface is getting at is, all of ^^that stuff has nothing to do with DNSmasq. If your soho box is running DNSmasq it's probably using iptables -nat MASQ rules to facilitate your natting.
    – Ori
    Jun 11, 2011 at 18:21

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .