Terry Stockdale
Top Choices for April...

IP Addresses Explained, Part 2

That's why you see many things in the computer world referring to multiples of 2 — because, at its lowest leve, each memory location really only stores two possible values, a 1 or a 0. It's also why, if you get into any aspect of programming, most programs start counting with zero instead of starting with one.

Back to networks, the flip side of the IP address (which helps to define a specific network interface — e.g., a network card in a computer) is called the "netmask." The netmask used with an IP address to define a specific network. Just like the IP address, this is four 8-bit numbers, each ranging from 0 to 255.

But, in a netmask, each bit has a special meaning. If the bit is set (that is, if it has a value of 1), then it is significant in defining a network. If it is 0, then any IP address value for the corresponding bit is a wildcard and is part of the specific network.

 

Let's look again at the home network using 192.168.1.x. Another way, the more common way, of writing this is to use an IP address and a netmask, written this way 192.168.1.1/255.255.255.0.

The IP address looks like it refers to a single computer (actually it would be a single network interface — a single computer might have multiple wired and/or wirelss network cards and each would have its own IP address). But that's not all it can do.

For a network card, an IP address is a specific defining set of numbers. The complication is that a network has a bunch of IP addresses — the netmask is used to say which of those computers are really part of a network — which computers you want to have the ability to talk to each other and/or your router and ISP.

So, to define the home network that might have up to 254 computers on it, we would write 192.168.1.1/255.255.255.0 .

The 255s (which is 8 bits, all of which have a value of 1) in the network mask specify that each of the bits that make up the 192, the 168 and the first 1 are significant and required to define this network. The 0 in the last position of the network mask says "anything is ok here, any value here is part of the network."

Finally, back to my visitors, IP addresses are pre-defined to different parts of the world. There are different entities in different parts of the world that assign the IP addresses to ISPs and other companies who needi blocks of addresses on the Internet.

Most of us use IP addresses that are officially assigned to our Internet Service Providers. Some of us have static addresses assigned (ones that never change), while others have dynamically assigned addresses which "lease" to us for short periods of time (the duration of a phone call, 24 hours, etc.). If we stay connected via cable modem or DSL (or in a private network with its own DHCP server), we usually never know that a lease has expired and been renewed — that's a "computer detail" that we as humans normally don't have to worry about.

So, finally back to the country list, since IP addresses are required for communications to actually work on the Internet, and since IP addresses are assigned in known blocks to countries and geographical businesses and ISPs, it is fairly easy to back-track and see from where a visitor came.

Email addresses, on the other hand, don't tell a lot. This is because so many people internationally have gmail.com, yahoo.com, hotmail.com and such addresses can't definitively be identified by country.

Other domains like cox.net and bellsouth.net, both of which I know are US entities) are identifiable by country, as are email addresses ending in a 2-character country code, such as .uk, .au, .nz, .de, and .no. I still enjoy seeing the country codes in emails, since they are easier to notice.

What's the value in knowing the countries? For me, the curiosity and the thrill of having an internationally known newsletter and web site.

 

Link to this page — just add this code to your web page!

<a href="http://www.terryscomputertips.com/computers/ip-addresses-explained2.php">IP Addresses Explained, Part 2</a>

Copyright © 2006 Terry A. Stockdale. All rights reserved.


 
Web www.terryscomputertips.com
Terry's Computer Tips - computer tips articles and newsletters
Subscribe to my free
Terry's Computer Tips
email newsletter.
Your Name: E-mail Address: