:: Re: [DNG] Networking with DHCP: Get…
Top Page
Delete this message
Reply to this message
Author: Dan Purgert
Date:  
To: dng
Subject: Re: [DNG] Networking with DHCP: Getting hostnames to work.
On Nov 26, 2025, Erik Christiansen via Dng wrote:
> Since SunOS4.1.3, I'd been content with fixed IPs and /etc/hosts. It worked OOTB.
>
> But these days it's all DHCP, including last night's Excalibur install. So it's time to figure out how to share hostnames with dhcp, I figure.
>
> The trusty Beowulf host, with all the files to shovel over, has in /etc/dhcp/dhclient.conf:
>
> send host-name = gethostname();
>
> so the dhcp server should have it.
>
> The new Excalibur host shows "dynamic" in the "inet" line for eth0
> result for the "ip address" command, so it should have what it asks
> for from the dhcp server.
>
> BUT a "ping greipner" gives "ping: greipner: Name or service not known".
>
> So the question is: How to tell the Excalibur host to request all
> local hostnames, so networking can function at one level above raw IP
> addresses?


You don't. A given host doesn't "request" hostnames on the LAN in the
sense of "okay DHCP server, thanks for the IP address, now please tell
me all other hostnames on the LAN".

The DHCP server needs to update the DNS server when a new host connects
and provides its hostname as part of the negotiation.

THEN, when you request 'ping greipner' from whatever host, it's going to
look at:

  (a) /etc/hosts OR
  (b) (optionally) mDNS OR
  (c) (optionally) its local DNS cache OR
  (d) if no hit in local cache (or no local cache), then ask DNS server
        defined in /etc/resolv.conf


(should be that order, anyway)

What are you using to provide local DHCP & DNS services on your LAN?