Do Routers Have IP Addresses? If So, How Many?

In today’s CCNA session, we’ll discuss IPv4 address network and host portions and subnet masks. Every machine connected to a TCP network must have a unique IP address, and each network must have a unique network number. IP addresses consist of two parts: the network part and the host part. The network part identifies the network number, while the host part identifies the individual machine on the network.

However, how does a host know which part of the 32-bit IP address is network and which part is host? This is where the subnet mask comes in. The subnet mask is a 32-bit number that tells the computer which part of the IP address is network and which part is host. It’s compared to the IP address from left to right, bit by bit. The ones in the subnet mask represent the network portion, and the zeros represent the host portion.

For example, let’s take the IP address 192.168.123.132 with a subnet mask of /24 or 255.255.255.0. Lining up the IP address and the subnet mask together, we can separate the network and host portions. The first 24 bits, the number of ones in the subnet mask, are identified as the network address. The remaining 8 bits, the number of zeros in the subnet mask, are identified as the host address. This gives us a network address of 192.168.123.0 and a host address of 132.

Note that the subnet mask does not actually contain the network or host portion as an IP address. It simply tells the computer where to look for these portions in a given IPv4 address.

In the next session, we’ll discuss IP address classes. Thank you for reading!