Networking 101 - Introduction

greenspun.com : LUSENET : Countryside : One Thread

Networking 101 - Introduction.

* * Internet Protocol (IP) numbers * *

Since we all use the internet, and it's become apparent that some of us don't understand it quite accurately, I thought I'd try to do a brief rundown of the principles here.

First of all, the internet is run by something called IP (Internet Protocol) numbers. These are made up of four groups of numbers (e.g. 216.92.90.50 ). Each group can be between 0 and 255 (magic computer numbers).

A good analogy is that an IP number is like a phone number. You can say that the first group would be like a country code, the next like an area code, the next like an exchange number, and the last like a number for individual lines out of the exchange. That's not quite accurate, but it gives you the idea.

We are already running short of IP numbers - there are only about four and a half million possibilities, and some of them are reserved. Later they will go to a new version of the internet protocol called IP6, which will have MANY more addresses.

Back to our telephone numbers (IP numbers). Some people have a dedicated telephone line (one IP number). Other organisations reserve blocks of numbers (multiple lines). An ISP (Intenet Service Provider) acts like a switchboard. So do many businesses. They service many more people than they have outside lines. When you need to make a call (connect to the internet) they will give you an IP (say like an outside line). When you've finished, someone else will get that outside line (IP number). Next time you make a call, you may get the same number (line) but more likely not. However, the IP number you get will be from the block of IP numbers owned by your ISP (or office, or whatever).

Just to mess up the picture some more, some switchboards (ISPs) don't always drop the connection when you've finished the call. This is particularly true of cable modem connections. If the physical connection is always-on, they can leave you with the same IP number for months. This is sort of like night-switching the lines on an old-fashioned telephone switchboard.

So, if anyone checked out my posts here, they'd find no consistent IP number. However, they'd find several consistent blocks of IP numbers. One block would correspond to the office where I used to work, another to the one I work in now. Two would correspond to two different ISPs I use, one free but early-AM one, and one I pay for. There might or might not be a different block for the family farm - my brother pays for normal-hours use from the same ISP I get the awful-hours free service from, but our points-of-access are 180 kilometres apart. If you checked out my emails, you'd find yet another block of IP addresses, because I use Yahoo to send them.

OK, from all that, it's apparent that the same IP number can get used by many different people - one time it can be a bored and lonely 14-year-old, who may maintain his webtv connection all day, or even for several days. In fact, it might even be several months before the ISP changes the IP number. However, that same number could have been used by a mother emailing her daughter, a student surfing the web, a gun enthusiast (or even "gun nut" or "survivalist" or criminal) trying to buy a firearm, a slimeball seeking to prey on children, and many others.

* * Universal Resource Locators (URLs) and Domain Names * *

OK, you may have noticed that I didn't say a thing back there about names. That's because the internet doesn't need them - it's all done with mirrors - um, numbers. However, names make things easier for us - more friendly to remember www.countrysidemag.com than 216.92.53.127 . Post that IP number into the address window of your browser and see where you end up. So, there are name servers scattered all over the internet. When you enter a domain name, your computer will enquire of the computer it's been told to use first (the primary name server) as to which IP number corresponds to that name. If it doesn't get a response from that, it will then try a secondary name server. In theory, this could go on forever, but generally two name servers are all anyone sets up.

There are only a very few top-level name servers, equating to the various domain name registrars. When details of a domain name changes (say an IP number change because the owner of the domain has moved to a different host; or was doing things on the cheap hosting his own domain on a cable connection, and his ISP eventually changed his IP number); then these top-level name servers send the information out to all the other name servers on the net. What they do with it is up to them. Some do immediate updates, some run overnight updates, some forget about it for a week or forever. It's worth specifying your domain name servers from big professional organisations.

OK, that's domain names. Universal Resource Locators (URLs) are domain names (or even IP numbers) with a bit extra tacked on. Basically they point right to an individual web page. The domain name points to an individual computer (or a share of a computer on a web-hosting service). The rest of the URL specifies directories (folders) that the web page is kept in, and at last the individual web page.

Well, that's the way it started. However, there are other things on the web as well as static web pages. Greenspun is a simple example - a URL for here contains information for a query on a database. Other URLs these days can contain other information that feeds to programs that generate the information you see - the actual page you see on your screen may not exist anywhere else - it's been generated on-the-fly in response to your enquiry.

* * Cookies * *

Now, if you were paying attention, you may have noticed that I didn't say anything up there about maintaining a session. I talked about accessing individual pages. That's because the internet doesn't do sessions - just pages. Once you've got a page via the URL, that's the end of it. Technically, internet access is a "stateless" protocol - that is, it has no context outside the immediate - every request is a new request.

Um, you may say. What about eBay? What about Amazon? What about the Countryside forum, come to that? I'm definitely maintaining a session there.

Well, that's true too. YOU are maintaining the session (in co-operation with the computer at the other end). You have to add context to the internet, to remember things from previous pages, or your shopping cart would always be empty. That's where cookies come in. They are tiny little files that your computer stores at the direction of the central computer. Next page, the information from those cookies (say, the books you've "placed" in your shopping cart, possibly along with a session identifier) gets sent back to the central computer. It updates things, adds the next book, sends the information back for your cooky to be updated.

That's why you need cookies - that's why cookies are good. However, some organisations take enormous liberties, gathering and saving information about you (or your computer) that you may not want them to have. Others are just plain straight-out malicious. They may save information that they will later access to your detriment. For instance, an organisation mentioned above decided that if you were an established customer they wouldn't offer you as good a deal as if they were trying to get your business. Bigger discounts for new customers - old customers we don't need to buy their business. It is possible to set cookies which are "transient" - they only last for the length of the browser session, and are then automatically deleted when the browser is closed down - that's what I do.

That's about it. I might revisit the subject to talk about packets and routers, but that's technical stuff and it's not something you NEED to know to use the internet.

-- Don Armstrong (darmst@yahoo.com.au), November 22, 2001

Answers

Thanks Don!

I used to know a little about all of this....now I know a lot!

-- Jason in S. Tenn. (AJAMA5@netscape.net), November 22, 2001.


Don, You need some clarifications.

>First of all, the internet is run by something called IP (Internet >Protocol) numbers. These are made up of four groups of numbers (e.g. >216.92.90.50 ). Each group can be between 0 and 255 (magic computer >numbers).

The internet is not run by Somthing called IP, IP is one of many protocals that are sent across the internet. You dont need an IP number to have a network.

>A good analogy is that an IP number is like a phone number. You can >say that the first group would be like a >country code, the next like an area code, the next like an exchange >number, and the last like a number for >individual lines out of the exchange. That's not quite accurate, but >it gives you the idea.

This is a very poor analogy and will lead to more confusion. I address have no implication to a location. Two numbers in sequency may be hundreds of miles apart.

Cookies, A very antiquated way to handle sessions. You dont need cookies to handle sessions if youu write your application correctly. You will find many sites that set cookies never use them or dont use all of the cookies they set.

-- Gary (gws@columbus.rr.com), November 22, 2001.


Don, nobody here knew you could speak geekaneese, we thought of you as a lonely sheep herder from down under, at least I did. With your knowledge can you post a lesson per day for us new puter operators? I am new to puters, I can do email, surf the net, search engines, but do not know anything about cut and paste, hyperlinks, ect.

-- mitch hearn (moopups@citlink.net), November 22, 2001.

I would guess the point he was trying to make with the IP/Phone Numbers, was that of subsets of subsets of sets, and the exchange portion can often represent an ISP, rather than a physical location. It's a good simple response--explaining more accurately would require much more detail ( Class A,B, and C networks, subnets, hostmasks, etc.)

I know he certainly put it better than I could of, and I think he will certainly be doing more teaching, than confusing, with his method :)

-- Brendan K Callahan (Grinnell, IA) (sleeping@iowatelecom.net), November 25, 2001.

Wooooo~~~~ Brain on overload!~~~~ Need coffee!~~~~ Thanks Don for giving us that lesson. The really scarey thing about it was that I understood it :~}and I was reading it with the kids all making their normal morning noise around my head. Hey, not bad for a blonde huh? heehee! :~)!!! No one has ever "splained" it like that before! Looking forward to lesson 101-B. You are a good "splainer" Don!

-- Nan (davidl41@ipa.net), November 25, 2001.


Would someone please 'splain the cretins who continue to spam with porno products?

-- sheepish (the_original_sheepish@hotmail.com), November 25, 2001.

Sheepish, they say "there's one born every minute". That's the only possible explanation for spammers. Someone manages to convince them that annoying people is the way to make their fortune, and they say "what a great idea - making enemies is bound to make my fortune!" Then they go forth and spam. If you analyse the spam you get, some of it will be "how to make money from home by spamming people". In fact, there are only a few (say a dozen) people who make money this way, and they do so by victimising the idiots who pay money to learn how to become second-rate about-to-become-broke spammers.

-- Don Armstrong (darmst@yahoo.com.au), November 27, 2001.

Don't forget that you can delete all the cookies on your computer periodically by using the "Find" feature and then clearing the folder.

-- Anne (HealthyTouch101@wildmail.com), November 27, 2001.

I do that nearly every day, but don't the cookies stay on the sites where you have been? Betcha I have a ton of cookies on the sewing and recipe sites. If you have cookies on the recipe site, do you get Spam spam? Sorry, obviously it is early yet! heehee!

-- Nan (davidl41@ipa.net), November 28, 2001.

Moderation questions? read the FAQ