Mailing List Archive
tlug.jp Mailing List tlug archive tlug Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]Re: [tlug] Re: "Password on localhost" [C&C, y'r welcome, Josh]
- Date: Sat, 08 Mar 2008 12:51:12 +0900
- From: "Stephen J. Turnbull" <stephen@example.com>
- Subject: Re: [tlug] Re: "Password on localhost" [C&C, y'r welcome, Josh]
- References: <4fefd6340803062016q3e34cf59jccbd4b8bb6906e50@mail.gmail.com> <d8fcc0800803062231k1e60d7afv867ee756b27cfcab@mail.gmail.com> <47D17DA1.6030201@imaginatorium.org> <20080307204531.GA18183@mail.scottro.net>
Scott Robbins writes: > localhost means the computer you are physically in front of, and > using at the moment. Right. The reason is a little complex. As the OP is probably aware, the Internet does not transmit data continuously like the telephone or television, but instead cuts it into packets, and then ships each packet independently. So when you send a message (eg, to request a web page) to another system, first the OS bundles it into a packet. Then it puts it in a "buffer", which is just a place (region of memory) to hold the packet data until the system is ready to send it. When it's time to send, the system takes it from the buffer, outputs it to a network interface, which sends it "over-the-wire" to be received by another system's interface. There it is input to a buffer where it waits until the program (in the example, web server) to handle it is ready. Now, it turns out to be very useful to have a *loopback* interface. In this case, there is no wire, and in fact not even a hardware interface: you just move the packet from the send buffer to the receive buffer on the same machine! Since there is no other machine involved, the loopback interface can have the same address on every machine without confusion, and that address is 127.0.01. It is conventional to give that address the name "localhost", again without confusion. (There's no confusion for precisely the same reason that "I" is unambiguous to the person who says it.) What this means is that any program that can be used across the Internet can also be used on the same host *in exactly the same way*, even without a network card! This is useful for all kinds of testing, obviously, but also for many other purposes. Eg, "pydoc" is a program that displays documentation for the Python programming language in an ordinary web browser. You can run it on a LAN, or across the Internet even, but it's just as useful on a disconnected host. Not only is true that on the Internet you can't know that the other end of the connection is a dog -- you may not even know that that dog is you, too! [There's more, Joshbert, so don't pick up yer mug 'o Java quite yet.] > localhost is the name that the operating system gives the machine that > is running the system. Actually, that's a little imprecise. First, it's not the "machine", it's a network interface. Second, it can be anything you like, or nothing at all. Conventionally it is "localhost", and you'll find it in scripts and the like. So it's convenient to follow convention. > So, if you look at your /etc/hosts file you'll see something like > 127.0.0.1 You'll see exactly that, and these possibly something like ::1 which is the same thing in the IPv6 domain. These are defined in the Internet RFCs. > and the name you gave your machine If your machine is on the Internet (and that name is know on the Internet), you probably shouldn't see that associated with the loopback address. The reason is that it is generally a good idea to have a 1-1 correspondence between IP addresses and A names. > Most have us have been at that, I don't understand anything stage once > in awhile. Yeah. Even after 20 years in this community, I can still read posts by Stallman and his acolytes and realize that at least one end of the channel (possibly both) has no clue about anything! Just happened again today.... [OK, *now* you can indulge your caffeine jones, Josh!]
- References:
- [tlug] Re: "Password on localhost"
- From: Gernot Hassenpflug
- Re: [tlug] Re: "Password on localhost"
- From: Josh Glover
- Re: [tlug] Re: "Password on localhost"
- From: Brian Chandler
- Re: [tlug] Re: "Password on localhost"
- From: Scott Robbins
Home | Main Index | Thread Index
- Prev by Date: Re: [tlug] Freely distributable Japanese capable utf8 font?
- Next by Date: Re: [tlug] Freely distributable Japanese capable utf8 font?
- Previous by thread: Re: [tlug] Re: "Password on localhost"
- Next by thread: Re: [tlug] Re: "Password on localhost"
- Index(es):
Home Page Mailing List Linux and Japan TLUG Members Links