IP Address in Networking
IP Address in Networking
IP Address in Networking
In networking,
• IP Address is short for Internet Protocol Address.
• It is a unique address assigned to each computing device in an IP network.
• ISP assigns IP Address to all the devices present on its network.
• Computing devices use IP Address to identify and communicate with other devices in
the IP network.
Types Of IP Address-
1. Static IP Address
2. Dynamic IP Address
1. Static IP Address-
NOTE
• Some ISPs do not provide static IP addresses.
• Static IP Addresses are more costly than dynamic IP Addresses.
2. Dynamic IP Address-
IP Address Format-
1. Network ID represents the IP Address of the network and is used to identify the
network.
2. Host ID represents the IP Address of the host and is used to identify the host within
the network.
IP Address Example-
Classful Addressing-
1. Class A
2. Class B
3. Class C
4. Class D
5. Class E
1. Class A-
If the 32 bit binary address starts with a bit 0, then IP Address belongs to class A.
In class A IP Address,
• The first 8 bits are used for the Network ID.
• The remaining 24 bits are used for the Host ID.
We have-
• Minimum value of 1st octet = 00000000 = 0
• Maximum value of 1st octet = 01111111 = 127
From here,
• Range of 1st octet = [0, 127]
• But 2 networks are reserved and unused.
• So, Range of 1st octet = [1, 126]
Use-
• Class A is used by organizations requiring very large size networks like NASA,
Pentagon etc.
2. Class B-
If the 32 bit binary address starts with bits 10, then IP Address belongs to class B.
In class B IP Address,
• The first 16 bits are used for the Network ID.
• The remaining 16 bits are used for the Host ID.
We have-
• Minimum value of 1st octet = 10000000 = 128
• Maximum value of 1st octet = 10111111 = 191
Use-
• Class B is used by organizations requiring medium size networks like IRCTC, banks
etc.
3. Class C-
If the 32 bit binary address starts with bits 110, then IP Address belongs to class C.
In class C IP Address,
• The first 24 bits are used for the Network ID.
• The remaining 8 bits are used for the Host ID.
Total Number Of IP Addresses-
We have-
• Minimum value of 1st octet = 11000000 = 192
• Maximum value of 1st octet = 110111111 = 223
4. Class D-
If the 32 bit binary address starts with bits 1110, then IP Address belongs to class D.
We have-
• Minimum value of 1st octet = 11100000 = 224
• Maximum value of 1st octet = 11101111 = 239
5. Class E-
If the 32 bit binary address starts with bits 1111, then IP Address belongs to class E.
We have-
• Minimum value of 1st octet = 11110000 = 240
• Maximum value of 1st octet = 11111111 = 255
Classes of IP Address-
Total
Class of 1st Octet Number of Hosts Default
Number of
IP Decimal Networks per Subnet
IP
Address Range available network Mask
Addresses
Not
Class D 228 224 – 239 Not defined Not defined
defined
Not
Class E 228 240 – 254 Not defined Not defined
defined
Important Notes-
Note-01:
• All the hosts in a single network always have the same network ID but different Host
ID.
• However, two hosts in two different networks can have the same host ID.
Note-02:
• A single network interface can be associated with more than one IP Address.
Note-03:
• IP Address of the network called Net ID is obtained by setting all the bits for Host ID to
zero.
Note-05:
Note-06:
• This is to account for the two reserved network IP Addresses 0.xxx.xxx.xxx and
127.xxx.xxx.xxx.
• IP Address 0.0.0.0 is reserved for broadcasting requirements.
• IP Address 127.0.0.1 is reserved for loopback address used for software testing.
Note-07:
In all the classes, total number of hosts that can be configured are 2 less.
• This is to account for the two reserved IP addresses in which all the bits for host ID
are either zero or one.
• When all Host ID bits are 0, it represents the Network ID for the network.
• When all Host ID bits are 1, it represents the Broadcast Address.
Note-08:
• Only those devices which have the network layer will have IP Address.
• So, switches, hubs and repeaters does not have any IP Address.