[Dnsmasq-discuss] can we set dhcp-option-force in optsfile?

Mauro Rodrigues maurosr at linux.vnet.ibm.com
Thu Apr 16 16:55:06 BST 2015


Hi! 

So I'm currently running dnsmasq using --dhcp-optsfile with the
following contents:

tag:tag0,option:dns-server,9.114.219.1
tag:tag0,option:classless-static-route,169.254.169.254/32,9.114.219.191,0.0.0.0/0,9.114.219.254
tag:tag0,249,169.254.169.254/32,9.114.219.191,0.0.0.0/0,9.114.219.254
tag:tag0,option:router,9.114.219.254
tag:78baad92-d8cd-4acc-96c8-fa112954566d,option:tftp-server,9.114.219.72
tag:78baad92-d8cd-4acc-96c8-fa112954566d,option:server-ip-address,9.114.219.72
tag:78baad92-d8cd-4acc-96c8-fa112954566d,option:bootfile-name,pxelinux.0

and the process is started with 
dnsmasq --no-hosts --no-resolv --strict-order --bind-interfaces
--interface=tap30cc9287-f6 --except-interface=lo
--pid-file=/opt/stack/data/neutron/dhcp/3970ede5-8169-40a5-8a0c-401ed68fb335/pid
--dhcp-hostsfile=/opt/stack/data/neutron/dhcp/3970ede5-8169-40a5-8a0c-401ed68fb335/host
--addn-hosts=/opt/stack/data/neutron/dhcp/3970ede5-8169-40a5-8a0c-401ed68fb335/addn_hosts
--dhcp-optsfile=/opt/stack/data/neutron/dhcp/3970ede5-8169-40a5-8a0c-401ed68fb335/opts
--leasefile-ro --dhcp-authoritative
--dhcp-range=set:tag0,9.114.219.0,static,86400s
--dhcp-lease-max=256 --conf-file= --domain=openstacklocal

Some things have change and now I need to also send option 210
(path-prefix) to use it on pxe AND petitboot.

What I've tried so far: 
Add to optsfile the following:
tag:78baad92-d8cd-4acc-96c8-fa112954566d,210,/opt/stack/data/ironic/tftpboot/

Which worked *only* for petitboot cause it explicitly asks for such
option, pxe though doesn't ask for it, which led me to dhcp-option-force
that I've added to the command line that starts dnsmasq:
 
--dhcp-option-force=208,f1:00:74:7e
--dhcp-option-force=210,/opt/stack/data/ironic/tftpboot/

That still doesn't work for pxe, dhcpdump is pasted here:
http://paste.openstack.org/show/204123/ the 210 parameter is not sent.

So I ask, is there any problem by using both --dhcp-optsfile AND
--dhcp-option-force to start dnsmasq?
Is there a way to add force options in the dhcp-opts file?


Thanks,

--
Mauro Rodrigues




More information about the Dnsmasq-discuss mailing list