IP Addresses and IP Networks

The Essentials

This section summarises the content on this page (read on for the full tutorial):

IP Addresses

Each computer has an address by which messages can be delivered, its IP address. Note in IP terminolgy the computer is more commonlly called a "host" as it hosts client and/or server apps that do the real work with the received messages.

In normal terminology we speak of IP addresses as consisting of four numbers between 0 and 255, each separated by a dot e.g. 192.168.1.7, this is referred to as "dotted decimal notation".

In a typical SOHO network you will have an address of 192.168.1.x, where x is the only number that changes in value i.e. bewteen 1 and 254. Each device in the network will have a different value for x and from one day to another you may be allocated a new value for x on the same device. See Dynamic Host Control Program (DHCP) below for more on this.

HowTo Find Your IP address

How can you find the IP address of your computer or mobile device? Check out the link to the right.

IP Networks

The first IP networks were made by cabling/wiring collections of computers on college campuses. In the diagram "A small, early, IP network" we have three computers (hosts), each with their own IP address. The computers are connected by a hub which simply acts to connect the cables, it has no intelligence and does not need an IP address.

A small, early, IP network

Here all of the computers have addresses between 192.168.1.1 and 192.168.1.254 and are said to be in the same IP network.

It's possible to have IP networks with more than 254 hosts, this is decided by the first number of the address. It's the 192 in our example address which indicates that we have a network of only 254 addresses.

Important: Never assign hosts to the first or last available network addresses, e.g. never assign 192.168.1.0 or 192.168.1.255, as the .0 address is used to identify the network and the .255 address is used by a special IP broadcast function.

By convention the first available network address e.g. 192.168.1.1 is assigned to the router, see "An example SOHO network" below.

How do I know what your IP address ranges are likely to be? Well the typical SOHO address range is a consequence of something called Network Address Translation (NAT) which allows a router to hide the local network from the internet. These hidden networks should only use private IP address ranges, such as 192.168.1.x. When connecting to the internet, any and all of the devices in such a LAN are mapped at the NAT gateway (in your router) to a single internet IP address assigned by your ISP.

Note: NAT will be explained in more detail in a later tutorial.

Sub-Networks and Network Masks

Now let's consider a larger network using the private IP address range 10.x.x.x, again it's the 10 that defines the network size and in this case we have 16.6 million IP addresses. This is too many hosts to manage as a single entity so we break the network up into sub-networks. The most common way to define a sub-network is by using a Network Mask. If in our example we establish a network mask of 255.255.0.0 then hosts with addresses 10.0.0.2 and 10.1.0.2 will be in different sub-networks. This type of network then requires some kind of internal routing capability to know how to find the different sub-networks, as such this sub-network structure is more typical of larger enterprises than a SOHO environment.

In a typical SOHO network we will have an IP address of 192.168.1.x and a network mask of 255.255.255.0, this mask is saying that sub-networks are not in use.

Tech: For windows, Android and Apple systems our standard mask is the one used, however, there are other ways of specifying sub-networks:

Dynamic Host Control Program (DHCP)

A DHCP server, usually located in your router, can lease IP addresses to client hosts. A client requests an IP address using a LAN based broadcast protocol (not TCPIP as it does not have an IP address until one is allocated). The server chooses an available address from a pool of available addresses and passes this to the client. Along with the client's IP address DHCP servers pass information such as the sub-network mask and the default gateway's IP address.

For devices in your network containing server apps e.g. a NAS box or an IP camera, you might need to have a fixed or static IP address. An alternative to specifying fixed address parameters in the IP configuration of these boxes is to use DHCP but then code a fixed relationship between the host's MAC address and the IP address the DHCP server is to allocate. This is done in the DHCP server administration, probably an option on your router congiguation. With this technique your IP address administration is in one central location (duplicate IP addresses on a network will lead to all sorts of difficult to detect problems).

Your SOHO Network

An example SOHO network

In your SOHO network you probably have wireless mobile, tablet and laptop connections. You may have one or two wired connections, such as the desktop PC illustrated in "An example SOHO network". The heart of your LAN network and gateway to internet access will be your router. You may have been asked for a ""Default GW" this is the first hop address to reach any other internet IP address i.e. the address of your router.

Typically your router will also house:

Your router is probably not doing any clever routing of messages. When your ISP leases it an IP address it probably supplies a Default GW address of its own local router. This router at your ISP will make complex decisions on how best to send your message.

Note: As shown, you may also have a separate modem for communications with your ISP over glass fibre, cable, or telephone line.

IPv6 and the Internet of Things (IoT)

What we have been looking at until now is the SOHO network of today, based on IPv4. The Internet of Things, where your coffee maker instructs your toaster to get the bread browning, is going to require many more addresses than todays 255**4 i.e. some 4 billion addresses. IPv6 has 256**16 addresses, that's a little more than a 3 with 38 zeros behind it addresses.

IPv6 is beyond the scope of this tutorial but I hope to write a document about this new architecture soon.

 

URLs, Domains and DNS
Next
TCPIP Networking
Contents
TCPIP Introduction
Prev