[Dnsmasq-discuss] prevent dnsmasq from releasing IPs

Stefan Priebe - Profihost AG s.priebe at profihost.ag
Tue Jan 26 13:42:48 GMT 2016


Am 26.01.2016 um 14:32 schrieb Simon Kelley:
> 
> 
> On 26/01/16 07:25, Stefan Priebe - Profihost AG wrote:
> 
> 
>> Am 25.01.2016 um 23:20 schrieb Simon Kelley:
>>> Not directly. If you just want a record of leases after they've
>>> been released, then you can save information by using the
>>> dhcp-script function. If you want to stop re-use of the
>>> addresses, then the best you can easily do is to allocate static
>>> addresses to clients. That will stop the addresses being
>>> allocated to other clients, even when not leased.
> 
>> I had the hope that dnsmasq evaluate the return code of the
>> dhcp-script and i can use exit 1 if i do not want to delete the
>> IP.
> 
> That's an interesting thought. The dhcp-script gets run
> asynchronously, so it wouldn't be trivial to implement, but it may be
> possible.
> 
>> Is it possible that i readd the IP to the leases file in the 
>> dhcp-script? Or does dnsmasq remove the entry after processing the 
>> dhcp-script?
> 
> That wouldn't work at all. Dnsmasq only reads the contents of the
> lease file at startup. The rest of the time it's working from an
> internal copy. If you altered the file, your changes would just be
> overwritten and ignored.

what about writing and sending kill 1 / HUP?

> 
> 
> Cheers,
> 
> Simon.
> 
> 
>> Stefan
>>>
>>>
>>> Cheers,
>>>
>>> Simon.
>>>
>>> On 25/01/16 16:42, Stefan Priebe - Profihost AG wrote:
>>>> Hi,
>>>
>>>> is there any way to keep IPs in the dnsmasq DB even the host
>>>> sends a release?
>>>
>>>> I want to keep those entry at least for 2 more days.
>>>
>>>> Greets, Stefan
>>>
>>>> _______________________________________________
>>>> Dnsmasq-discuss mailing list
>>>> Dnsmasq-discuss at lists.thekelleys.org.uk 
>>>> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>>>
>>>
>>>
>>>>
> _______________________________________________
>>> 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