bug-inetutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-inetutils] dnsdomainname, domainname, nisdomainname, ypdomainna


From: Simon Josefsson
Subject: Re: [bug-inetutils] dnsdomainname, domainname, nisdomainname, ypdomainname
Date: Tue, 13 Mar 2012 15:31:00 +0100
User-agent: Gnus/5.130003 (Ma Gnus v0.3) Emacs/24.0.94 (gnu/linux)

Mats Erik Andersson <address@hidden> writes:

> tisdag den 13 mars 2012 klockan 09:57 skrev Simon Josefsson detta:
>> Mats Erik Andersson <address@hidden> writes:
>> >> I have pushed 'dnsdomainname' now.  Let's take a look at the others
>> >> next...
>> >
>> > BSD systems only provide hostname(1) and domainname(1).
>> >
>> 
>> I note that neither of these 'hostname' implementations appears to be
>> able to canonicalize the name using the resolver.
>> 
>> That means our 'dnsdomainname' is thus only for compatibility with
>> existing GNU/Linux systems.  Unless someone finds any other systems out
>> there with a 'dnsdomainname' tool on it...
>
> Observe that "hostname" and "dnsdomainname" were the only executables
> in the package "hostname" of Debian GNU/Linux until 2009 in version 2.97.
> Only then did "domainname", "ypdomainname", and "nisdomainname" enter.

The code has been in there for a long time though, on 1999 briefly the
package installed hardlinks for domainname, nisdomainname and
ypdomainname:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=22993

but that lead to a conflict with the 'nis' package:

http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=48850

so it was reverted.

The NIS package in Debian is from http://www.linux-nis.org/ and it
appears to be maintained, however the {yp,nis,}domainname tool is
GPLv2-only.

Presumably *BSD's have NIS as well?  Then they probably have some subset
of {yp,nis,}domainname commands?  The reason there were no man page for
it might just be because it is not part of a normal NIS-less
installation.

> In addition, for GNU/Linux "domainname" is an interface into the settings
> of the Linux kernel, it has nothing to do with the resolver. Hence it will
> return "(none)" unless the kernel has been told otherwise. This is in
> accordance with the mechanisms for BSD systems.

Ah, that is where '(none)' comes from.  It should not be needed in the
dnsdomainname tool, though.

This discussion makes me think separating dnsdomainname from hostname
was a good move, the tools serve quite different needs and with
different history.

/Simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]