IP Address and Subnetting
By hubadmin
What is IP Address?
I stumbled upon my old notes from networking and thought of sharing a thing or two about it.
Objective
*Learn the different Classes of IP Address
*Identify IP Addresses
*Learn How to perform IP Subnetting
IP Address
IP Address is used to uniquely identify a device on an IP network. It is made up of 32 binary bits which can be divisible into a network portion and host portion with the help pof a subnet mask. It is a four decimal number seperated by dots. Each decimal can only be in the range of 0-255
192.168.100.87
8 + 8 + 8 + 8 = 32 bits
8-bits = 1 octet
1st . 2nd . 3rd . 4th - octet
Examples:
192 .168.1.2
130.10.1.50
12.11.5.111
IP Address CLASS
IP Address is classified into Classes:
Class A
To determine if the IP Address is class A the first decimal number from left should be in the range of 1-126. With default subnet mask of 255.0.0.0 or /8 and a total number of 16,777,214 host.
Ex. 12.8.123.43
Class B
To determine if the IP Address is class B the first decimal number from left should be in the range of 128-191. With default subnet mask of 255.255.0.0 or /16 and a total number of 65,534 host.
Ex. 150.23.73.23
Class C
To determine if the IP Address is class A the first decimal number from left should be in the range of 192-223. With default subnet mask of 255.255.255.0 or /24 and a total number of 254 host.
Ex. 192.24.37.12
Class D
To determine if the IP Address is class A the first decimal number from left should be in the range of 224-239.
Class E
To determine if the IP Address is class A the first decimal number from left should be in the range of 240-255.
Note: if you notice from the IP address range 127 is not included because it is a loopback address. Class D and E are used for research and testing.
Private IP Address
These are reserved IP address space for private internets (local networks)
10.0.0.0 - 10.255.255.255
172.16.0.0 - 172.31.255.255
192.168.0.0 - 192.168.255.255
*Addresses beyond those range are considered public IP addresses.
Subnet Mask
A mask used to determine what subnet an IP Address it belongs to.
Summary:
Classes--- IP Range-- Subnet Mask-- Slash-- No. of Host ----- Field
Class A-- 1-126 ------- 255.0.0.0 --------- /8-- 16,77,214 ------- N-H-H-H
Class B-- 128-191----- 255.255.0.0 ----- /16- 65,534 ----------- N-N-H-H
Class C-- 192-223 ---- 255.255.255.0 - /24-- 254 --------------- N-N-N-H
Class D-- 224-239
Class E-- 240-255
N = Network ID
H = Host ID
.Reserved IP Adresses
Network Address - is the network portion of an IP Address
Class A network address is the first byte of the IP address
Class B network address is the first two bytes of the IP address
Class C etwork address is the first three bytes of the IP address
Broadcast Address - A broadcast address is an IP Address that lets you target all systems on a specific subnet instead of single hosts.
Loopback Address - This is primarily intended as a means of testing the transmission or transportation infrastructure.
APIPA (Automatic private IP addressing) - When a DHCP server fails, APIPA allocates addresses in the private range 169.254.0.1 to 169.254.255.254. Clients verify their address is unique on the LAN using ARP. When the DHCP server is again able to service requests, clients update their addresses automatically.
Subnetting
Subnetting allows you to create multiple logical networks that exist within a single network. Subnetting provides preservation of address space, and security. The most common reason is to control network traffic.
Subnetting Table
I learned this Subnetting Table from my instructor it helped me alot especially in exams wherein they dont require us to use calculator. At first I was hesitant to use it because I do have my own methods in subnetting but when I tried to use this it made a big difference. For me its easier and faster to subnet a network.
Sample 1
Given: 172.16.0.0 /20 identify Subnet mask, Host adresses, Broadcast Address
Subnet mask 255.255.240.0
Host addresses 172.16.0.1 /20 - 172.16.31.254 /20
Broadcast Address 172.16.31.255 /20
refer to Subnet Table /20 = 3rd octet, 240 subnet mask, 16 increment
Sample 2
Given: 10.0.0.0 /13 identify Subnet mask, Host adresses, Broadcast Address
Subnet mask 255.248.0.0
Host addresses 10.0.0.1 - 10.7.255.254 /13
Broadcast address 10.7.255.255
refer to Subnet Table /13 = 2nd octet, 248 subnet mask, 8 increment
Sample 3
Given: 192.168.1.0 /27
Subnet mask : 255.255.255.224
Host addresses: 192.168.1.1 - 192.168.1.30 /27
Broadcast address: 192.168.1.31 /27
refer to subnet table /27 = 4th octet, 224 subnet mask, 32 increment
Subnetting for Network
Three steps in subnetting a network:
1. formula:
N = no. of nework in bits
2^N must be = or > required network
/(original slash) + /(N) = /(new slash)
2. find the octet and increment
3.determine network ranges, valid host and broadcast address
Sample 1
Subnet 192.168.1.0 /24 = 5 networks
step 1
we need 5 networks 2^N must be = or > than 5
2^1 = 2 , 2^2 = 4, 2^3 = 8
/24 + /3 = /27
step 2
refer to subnet table /27 is on the 4th octet and has 32 increment
step 3
Network 1 :192.168.1.0/27
Host addresses: 192.168.1.1 - 192.168.1.30/27
Broadcast address: 192.168.1.31/27
Network 2: 192.168.1.32/27
Host addresses: 192.168.1.33 - 192.168.1.62/27
Broadcast address: 192.168.1.63/27
Network 3: 192.168.1.64/27
Host addresses: 192.168.1.65 - 192.168.1.94/27
Broadcast address: 192.168.1.95/27
Network 4: 192.168.1.96/27
Host addresses: 192.168.1.97 - 192.168.1.126/27
Broadcast address: 192.168.1.127/27
Network 5: 192.168.1.128/27
Host addresses: 192.168.1.129 - 192.168.1.158/27
Broadcast address: 192.168.1.159/27
Subnetting for Host
three steps in subnetting for Host
1. formula:
H = no. of nost in bits
2^H -2 must be = or > hosts required
/32 - /H = /(new slash)
2. Get octet and increment
3. Determine Network ranges, valid hosts and broadcast address
Sample 1
subnet 192.168.1.0/24 = 2 host
step 1
2^2-2 = 2
/32 - /2 = /30
step 2 refet to subnet table /30 is on the 4th subnet and has increment of 4
Network 1: 192.168.1.0/30
Host addresses: 192.168.1.1 - 192.168.1.2/30
Broadcast address: 192.168.1.3/30
Netwoek 2: 192.168.1.4/30
Host addresses: 192.168.1.5 - 192.168.1.6/30
Broadcast address: 192.168.1.7/30






Jiji 4 weeks ago
Tq so much..very2 clear