[Dnsmasq-discuss] Using dhcp-host hostname as address for DNS
Simon Kelley
simon at thekelleys.org.uk
Fri Jul 20 12:07:57 BST 2012
On 20/07/12 11:56, Alvaro Gamez wrote:
> Uh, I was asking because that didn't work :)
>
> Without the address line:
>
> root at alfa:/etc/dnsmasq.d# grep zulu radio
> #address=/zulu.ea4rct.org/192.168.0.254
> <http://zulu.ea4rct.org/192.168.0.254>
> dhcp-host=00:18:84:12:7e:10,zulu,192.168.0.254,1w
> root at alfa:/etc/dnsmasq.d# !hos
> host zulu.ea4rct.org <http://zulu.ea4rct.org>
> Host zulu.ea4rct.org <http://zulu.ea4rct.org> not found: 3(NXDOMAIN)
>
> With it:
> root at alfa:/etc/dnsmasq.d# grep zulu radio
> address=/zulu.ea4rct.org/192.168.0.254
> <http://zulu.ea4rct.org/192.168.0.254>
> dhcp-host=00:18:84:12:7e:10,zulu,192.168.0.254,1w
> root at alfa:/etc/dnsmasq.d# host zulu.ea4rct.org <http://zulu.ea4rct.org>
> zulu.ea4rct.org <http://zulu.ea4rct.org> has address 192.168.0.254
>
> Thanks!
Do the host actually have DHCP leases? If there exists a current DHCP
lease for a host called zulu, and you've configured --domain=ea4rct.org
then an A record for zulu.ea4rct.org will exist.
Try looking in /var/lib/misc/dnsmasq.leases for the IP address and name.
Cheers,
Simon.
>
> 2012/7/20 Simon Kelley <simon at thekelleys.org.uk
> <mailto:simon at thekelleys.org.uk>>
>
> On 20/07/12 11:30, Alvaro Gamez wrote:
> > Hi all!
> >
> > I'm just recently starting to use dnsmasq and I'm facing a problem,
> > maybe it's trivial but I haven't found the answer.
> >
> > I've configured dnsmasq to set specific IP addresses to some
> hosts, like
> > this:
> > domain = ea4rct.org <http://ea4rct.org> <http://ea4rct.org>
> > dhcp-host=00:e0:4c:a4:13:ac,foxtrot,192.168.0.6,1w
> >
> > I'd like the name, foxtrot, to be visible from the LAN, so I added:
> > address=/foxtrot.ea4rct.org/192.168.0.6
> <http://foxtrot.ea4rct.org/192.168.0.6>
> > <http://foxtrot.ea4rct.org/192.168.0.6>
> >
> > This way, local computers can just use foxtrot or
> foxtrot.ea4rct.org <http://foxtrot.ea4rct.org>
> > <http://foxtrot.ea4rct.org> as the name for this computer.
> > But this is repetitive and error-prone. Is it possible to avoid the
> > _address_ line, which is redundant?
> >
>
> Yes, just delete those lines. It will all Just Work.
>
> Cheers,
>
> Simon.
>
>
> _______________________________________________
> Dnsmasq-discuss mailing list
> Dnsmasq-discuss at lists.thekelleys.org.uk
> <mailto:Dnsmasq-discuss at lists.thekelleys.org.uk>
> http://lists.thekelleys.org.uk/mailman/listinfo/dnsmasq-discuss
>
>
>
>
> --
> Álvaro Gámez Machado
>
More information about the Dnsmasq-discuss
mailing list