Andreas Bach Aaen wrote:
I would like to user dnsmasq as the one part of a PXE server on a
network. I would like to pass different options and filenames to
clients identified by different MAC addresses. How do I do this?
First, set a tag based on the client's MAC address.
Then, tag the dhcp-boot lines you want sent, like this:
and the options you want to be sent
A few things to note:
1) The syntax for tagging dhcp-boot and dhcp-option is different: the
-boot needs "net:" to distinguish the tag from the filename, -option
doesn't. Recent versions of dnsmasq will ignore net: if you add it to an
-option line, but not earlier ones.
2) The semantics of untagged -option is different from -boot. Untagged
options are always sent, untagged -boot is sent only when no tagged one
3) Only one dhcp-host line is ever matched for a given client, so if
you're already using dhcp-host to specify fixed addresses or hostnames,
you need to add the tag to the existing dhcp-host line. Alternatively,
you can match against a wildcarded MAC address using dhcp-mac:
This is useful for matching a large class of hosts, when dhcp-host
matcing might already be in use for more specific stuff. dhcp-mac is
only available in more recent releases.