localhost (was: Re: Talk and "protocol not supported")

Lerxt dave at murphy.UUCP
Fri Sep 5 01:08:32 AEST 1986


Summary: A couple of questions about the setup of localhost
Line eater: selected for input

In article <3048 at umcp-cs.UUCP>, chris at umcp-cs.UUCP (the esteemed Chris Torek)
writes:

>However, it [the address for "localhost" in /etc/hosts]
>should always be 127.0.0.1, lest `martian datagrams'
>leak out later.  You must also be sure to `ifconfig lo0 localhost up'
>in /etc/rc or /etc/rc.local.

I have a couple of questions.  First, does the localhost address have to
be 127.0.0.1, specifically?  It seems to me that since 127 is a class A
(one-byte) network number, that 127.1 should also work.  We use that here
and it doesn't seem to cause any problems.

Second: I hate to expose my ignorance to the world, but what do you mean
by "martian datagrams"?  Does this mean that if the localhost isn't right,
packets addressed to the localhost network can get out on the Ethernet?

Third: About the ifconfig for lo0: I've never had to do this under either
our UTX or Sun Unix 3.0, and they seem to work all right.  Maybe they
cleaned it up.  Hmmm...

Finally: in an article that Chris quoted, it was stated that for all BSD4.2
systems that are not connected to a network, it is necessary to have a
"localhost" in the /etc/hosts file.  This is picking a nit, but it is
more correct to say that ALL BSD4.2 systems must have a localhost, whether
connected to a network or not.  (And don't forget to put "loopback" in
the /etc/networks file as network 127.)

---
"Pick it up and put it in your pocket, or somebody else will" - Stan Ridgeway

Dave Cornutt, Gould Computer Systems, Ft. Lauderdale, FL
UUCP:  ...{sun,pur-ee,brl-bmd}!gould!dcornutt
 or ...!ucf-cs!novavax!houligan!dcornutt
ARPA: wait a minute, I've almost got it...

"The opinions expressed herein are not necessarily those of my employer,
not necessarily mine, and probably not necessary."



More information about the Comp.unix.wizards mailing list