That is the original problem. Just trying to pass a custom DHCP header option to the dhcp-scrip=<file>. What do you mean by "So let us know which DNSMASQ_... you miss" ? I understand there is a lot of DNSMASQ_... options on the man page under dhcp-script. None let you grab all of the DHCP headers passed from the client to the server.
Thanks, Daniel ________________________________ From: Dnsmasq-discuss <dnsmasq-discuss-boun...@lists.thekelleys.org.uk> on behalf of Geert Stappers <stapp...@stappers.nl> Sent: Friday, August 10, 2018 7:20:50 AM To: email@example.com Subject: Re: [Dnsmasq-discuss] Set environment variable for dhcp-script On Fri, Aug 10, 2018 at 09:11:48AM +0000, Daniel Weller wrote: > From: Geert Stappers, Sent: Friday, August 10, 2018 1:51:26 AM > > On Thu, Aug 09, 2018 at 08:38:33PM +0000, Daniel Weller wrote: > > > Hello, > > > > > > I am trying to set an environment variable from inside dnsmasq- giving > > > the script being called by dhcp-script access to that variable. I > > > think the location to do this is inside helper.c in the create_helper() > > > function. However, when it forks I am unable to follow the child process > > > in my debugger. I have tried setting "set follow-fork-mode <mode>" & > > > "set detach-on-fork <mode>" but after the process forks- it seems to > > > just hang and never be called. > > > > > > Also I've got my local variable inside the lease struct and passed to > > > queue_script() in helper.c. > > > > > > Any ideas how to debug the dhcp-script child process or where I should > > > set the environment variable to allow the script called by dhcp-script > > > to read this environment variable? > > > > What is the original problem? > > > I am trying to pass a DHCP header value that is read from the client > DHCP request- to the file being called by dhcp-script=<file>. The > easiest way to do that I think is to set an environment variable that > the dhcp-script=<file> has access to while executing. > What is the original problem? So let us know which DNSMASQ_... you miss. ( check manual for DNSMASQ_ ) Groeten Geert Stappers -- Leven en laten leven _______________________________________________ Dnsmasq-discuss mailing list Dnsmasqfirstname.lastname@example.org http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
_______________________________________________ Dnsmasq-discuss mailing list Dnsmasqemail@example.com http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss