[Dnsmasq-discuss] Is there a way to return names for DHCP clients?
Grant Coady
grant_lkml at dodo.com.au
Fri Aug 22 22:27:13 BST 2008
Hi there,
My linux boxes all have static addresses, but dnsmasq is set to give
DHCP address to 'casual' boxes, usually a friend's box over for a
fixup, etc.
Today I installed linux on a friend's box with DHCP lookup, but I
cannot login by name:
$ ssh sharkey
ssh: Could not resolve hostname sharkey: Name or service not known
grant at deltree:~/ip2c$ ssh 192.168.1.107
...
grant at 192.168.1.107's password:
Last login: Sat Aug 23 06:17:41 2008 from sillywin.mire.mine.nu
Linux 2.6.24.5-smp.
...
Is there a dnsmasq DHCP option to fix this?
I have in server's /etc/dnsmasq.conf:
...
#-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
# Section 2. DHCP Server
# ```````````````````````
domain=mire.mine.nu
expand-hosts
dhcp-authoritative
dhcp-range=192.168.1.101,192.168.1.109,2h <-- this gave the address
dhcp-range=192.168.2.101,192.168.2.109,2h
dhcp-host=magpie,192.168.1.31,8h <-- windoze boxen
dhcp-host=toshnt,192.168.1.35,8h
dhcp-host=sillywin,192.168.1.36,8h
dhcp-host=silly64,192.168.1.37,8h
dhcp-host=tosh98,192.168.1.45,8h
dhcp-option=42,0.0.0.0 # This box is NTP server
# these are suggested for msft boxen:
# FIXME check rfc2132 for other option
#dhcp-option=19,0 # option ip-forwarding off
#dhcp-option=36,1 # use 802.3 ethernet
dhcp-option=44,0.0.0.0 # set netbios-over-TCP/IP nameserver(s) aka WINS server(s)
dhcp-option=45,0.0.0.0 # netbios datagram distribution server
dhcp-option=46,8 # netbios node type
dhcp-option=47 # empty netbios scope.
#
dhcp-lease-max=50
# end
The DHCP client looks correct:
root at sharkey:/etc# cat /etc/resolv.conf
# Generated by dhcpcd for interface eth0
search mire.mine.nu
nameserver 192.168.1.1
Thanks,
Grant.
More information about the Dnsmasq-discuss
mailing list