[Dnsmasq-discuss] Use hardware(macaddress) in dhcp-option

Simon Kelley simon at thekelleys.org.uk
Wed Jan 13 14:07:40 GMT 2010


Arends, R.R. wrote:
> Hi all,
>  
> I'm switching from dhcp3 to dnsmasq.
> I want to use gpxe/pxelinux and let it load dynamic config files by 
> using the hardware(macadres) of a machine as config filename.
> But can't seem to figure out how to translate this setting to dnsmasq tho.
>  
> In dhcp3 i use it the following way:
> option pxelinux.configfile =
>         concat("?mac=", binary-to-ascii(16, 8, "", hardware));
> which sets the dhcp option 209 for example to "?mac=00:21:9B:19:B1:F4"
>  
> How can i do the same in dnsmasq?
> i only came this far :) :
> dhcp-option-force=209,?mac=
>  
> I hope its possible to achieve the same.
>  
>

It's not possible to do the same in dnsmasq, sorry.

I'm probably missing something, but doesn't your example above just do
what pxelinux does anyway? I'm sure it looks for a file whose name is
the mac address, and then if it doesn't find that it searches for config
files based on the IP address.

Cheers,

Simon.






More information about the Dnsmasq-discuss mailing list