DEV Community

Suruthika
Suruthika

Posted on • Edited on

CA 16 - IP address and Subnet

An IP address is used to identify a device on a network. It like a home address but for computers. Every device connected to the network has a unique IP address so data can be sent and received correctly. For example, an IP address like 10.1.34.81 is IPv4. there is IPV6 but it is a failure model and not used right now.

An IP address is made up of two parts. One part represents the network part and the other part represents the host (for our device). This is where subnetting comes.

Subnet is dividing a large network into smaller networks. This helps in improved performance and also when the ip address is not enough. Instead of having one large network with many devices subnetting allows to split it into small groups.

A subnet mask decides which part of the IP address belongs to the network and which part belongs to the host.

CIDR is Classless Inter-Domain Routing. It is modern way of representing IP addresses and subnet masks. Instead of writing the subnet mask separately, CIDR combines it with the IP address using a slash.

For example, 10.1.34.81/24 means that the first 24 bits are used for the network. This is the same as the subnet mask

In CIDR, the number after the slash is how many bits are used for the network. A higher number means less hosts, and a lower number means more hosts. For example, /16 allows more devices than /24.

Finally, IP addresses help identify devices, subnetting helps divide networks into smaller parts, and CIDR represents these networks. These concepts are important for understanding how networks work.

Top comments (0)