[Dnsmasq-discuss] How to get name of DHCP'ed system?

richardvoigt at gmail.com richardvoigt at gmail.com
Fri Jan 23 17:55:20 GMT 2009


On Fri, Jan 23, 2009 at 11:23 AM, Paul Smith <psmith at gnu.org> wrote:
> On Fri, 2009-01-23 at 16:29 +0000, Chris G wrote:
>> Where is dhcp.leases?  I've looked in the obvious places and can't see
>> it, a quick Google suggests it should be /var/dhcp.leases but I
>> haven't got that.
>
> The file is actually called "dnsmasq.leases" (at least on the systems I
> have) and it's in /var/lib/misc.

Sorry about that.  I use the scripted external database so I don't
have a leasefile at all, and didn't check before providing the
information.

The man page mentions two possible paths:
/var/lib/misc/dnsmasq.leases
/var/db/dnsmasq.leases

Of course the path can be changed with the dhcp-leasefile option.

Simon, the man entry for dhcp-leasefile is awfully confusing.  Is that
always a ISC dhcpd-compatible file, or only when old behavior is
triggered by the lack of dhcp-range options?

>
>> It does seem that there's a need for a simple utility to get these
>> names though.
>
> You can write a little script to query the dnsmasq.leases file :-)
>
>
> _______________________________________________
> 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