Uname or hostname?
Sep. 23rd, 2005 06:18 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
Hostname, obviously. According to the docs, hostname "returns the standard host name for the current machine", whereas uname returns "name of this node within an implementation-dependent communications network", whatever that is.
no subject
Date: 2005-09-23 08:45 pm (UTC)no subject
Date: 2005-09-24 09:48 am (UTC)I seem to remember that uname under Unicos behaves strangely, producing non-standard output and using different options to everyone else in the Unix universe, but at least the stuff it dumps out is consistent. Other super trad versions of unix use a fixed 8 character string hardwired at compile time, so if you build the kernel on one host and copy out to the rest (as recommended by the docs), the nodename is almost always incorrect.