HOSTNAME from DNS name server

Karl Auer kauer at biplane.com.au
Mon Jun 29 23:22:52 UTC 2009


On Mon, 2009-06-29 at 16:50 +0200, Pieter Donche wrote:
> > An alternative might be to set the hostname locally based on information
> > already in the DNS.

I've had a closer look at dhclient-script, and it looks like it will set
the hostname for you *anyway* - you just have to make sure that there is
no hostname already set. That is, it will not override an existing
hostname.

How you unset the hostname is not clear to me yet. Nor am I sure that it
uses the DNS name - it uses the host name sent by the DHCP server, which
is not necessarily from the DNS, but probably could be - check the DHCP
server settings, I guess.

And of course, you could just replace the guts of the set_hostname()
function with what we've been talking about...

Regards, K.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
URL: <https://lists.ubuntu.com/archives/ubuntu-users/attachments/20090630/e8b3e026/attachment.pgp>


More information about the ubuntu-users mailing list