remove localhost from /etc/hosts??

Tim ignored_mailbox at yahoo.com.au
Fri Jan 22 10:58:27 UTC 2010


On Thu, 2010-01-21 at 19:09 -0500, Neal Becker wrote:
> It is not supported for a Grid Engine installation that the local
> hostname contains the hostname "localhost" and/or the IP address
> "127.0.x.x" of the loopback interface.
> The "localhost" hostname should be reserved for the loopback interface
> ("127.0.0.1") and the real hostname should be assigned to one of the
> physical or logical network interfaces of this machine.

Conflicting advice, and the first lot is just plain weird.

127.0.0.1 and localhost being associated together is normal.  Also
including localhost.localdomain seems to be a peculiar Linuxism.  Also
adding another hostname to that line has been a problem with Linux for a
very long time, it breaks things that aren't tolerant.

It's about time the advice in the hosts file was changed from telling
you not to change the following line (which has often, ALREADY, been
badly mangled, but the person reading this is unaware) to telling you
precisely what the first two lines should be.

i.e. More like this:

 #   The first two lines of this /etc/hosts file
 #   should be like the following example lines,
 #   to avoid networking problems:
 #
 #   127.0.0.1  localhost.localdomain localhost
 #   ::1  localhost6.localdomain6 localhost6
 #
 #   Real hostnames should be listed afterwards.
 #   Preferably, not associated with the same
 #   numerical IP addresses.

 127.0.0.1  localhost.localdomain localhost
 ::1  localhost6.localdomain6 localhost6

Though, to be honest, I'm surprised that the TCP/IP stack isn't designed
to presume those addresses, already, without requiring entry into the
hosts file.  Other systems work that way.  Is there any situation where
you don't want those addresses to be interpreted like that?

-- 
[tim at localhost ~]$ uname -r
2.6.27.25-78.2.56.fc9.i686

Don't send private replies to my address, the mailbox is ignored.  I
read messages from the public lists.





More information about the users mailing list