[Dnsmasq-discuss] dyndns-style addition of names

Simon Kelley simon at thekelleys.org.uk
Tue Apr 10 12:14:41 BST 2007


richardvoigt at gmail.com wrote:

> 
> Instead of adding code to persist the configuration, why not use the
> existing external script capability, and provide an example script?
> 
> Then a dbus method to cause dnsmasq to re-run its external script to
> learn any reservations, as it does during startup.

This facility already exists, in a slightly different form: sending
SIGHUP will make dnsmasq re-read /etc/ethers, which contains DHCP
address reservations.

Getting this information via the external script is problematic for a
few reasons: the current information returned is existing DHCP leases,
which is not the same as DHCP address reservations. Extending the
function in backwards compatible way would be possible, but not
neccesarily pretty. There's also a problem with permissions. Dnsmasq
runs the script as root to get lease information. Further calls to the
script are also doen as root via a helper process, because the main
dnsmasq process has dropped root by then. Getting information back from
the helper to the main process is difficult. (There is a pipe, but it's
one way, the wrong way.)

In general DBus is the way to go for this type of thing, and the ability
to easily make the config persistent might be a good thing to have.


Cheers,

Simon.

> 
>>
>>
>> Cheers,
>>
>> Simon.
>>
>>
>>
>> _______________________________________________
>> Dnsmasq-discuss mailing list
>> Dnsmasq-discuss at lists.thekelleys.org.uk
>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>
> 




More information about the Dnsmasq-discuss mailing list