Comment 1 for bug 234111

Revision history for this message
Thomas Hood (jdthood) wrote :

Tom Wood wrote:
> I am assuming that "boxname" is under 127.0.1.1 because eth1 is the active NIC.

"boxname" is under 127.0.1.1 because that is standard in Debian and Ubuntu.

If a machine has a permanent IP address then it is appropriate to assign that IP address
to the hostname, e.g.,

   123.45.67.89 boxname.foo.com boxname

> My observations are that there are several issues that could be resolved simply
> by two things: First, assign the FQDN and it's non-FQDN both to the 127.0.0.1
> loopback interface, not the 127.0.1.1.

No, that is non-standard in Debian and Ubuntu.

This:

> 127.0.0.1 localhost boxname.example.com
> 127.0.1.1 boxname.example.com

is invalid. The 127.0.0.1 should contain the hostname "localhost" and only the hostname "localhost".

Further, with that configuration the hostname "boxname" can't be resolved. It should be included as an alias.
Thus /etc/hosts should look like this in your case:

    127.0.0.1 localhost
    127.0.1.1 boxname.example.com boxname

Please see http://www.debian.org/doc/manuals/reference/ch-gateway.en.html and hosts(5).