10

I've got a laptop running Ubuntu 12.04 that is sharing its wifi connection to another machine through the eth0 interface using NetworkManager. This seems to be done by dnsmasq.

Now I need to set up PXE/TFTP booting on the other machine, so I'd like to configure the dnsmasq instance that is spawned through NetworkManager to add a couple of lines for PXE/TFTP. How is this done? It seems to ignore /etc/dnsmasq.conf.

Previous answers seem to indicate that the configuration is hardcoded into NetworkManager. Is this still the case? If so, is there an easy way to achieve what I'm trying to do here? I suppose I could just disable the network sharing in NetworkManager and set it up manually, but I'd rather keep this all managed in one place if it all possible.

edit: Indeed, it seems the dnsmasq configuration is still hardcoded in NetworkManager. See source here. It seems to me that it would be a much better solution to simply specify an alternate dnsmasq.conf file here, but I'm sure there are issues I haven't considered.

blaabjerg
  • 133

1 Answers1

8

Dnsmasq doesn't "share connections". The role of the NetworkManager-controlled dnsmasq is to route DNS traffic.

You can't configure the NetworkManager-controlled dnsmasq process in Precise. In Quantal you are able to configure it via files in /etc/NetworkManager/dnsmasq.d/. See dnsmasq(8).

Another possibility is to use the standalone dnsmasq server which is fully configurable even in Precise. To run standalone dnsmasq alongside NM-dnsmasq in Precise you need to give standalone dnsmasq the "except-interface=lo" option. This is not necessary in Quantal.

jdthood
  • 12,625