VPN Speed

Your IP address is:

00.000.000.00

-

More details

What is a Subnet mask?

Sometimes we need to determine to which group of IP addresses this or that IP address belongs. In other cases, we need to determine what part of the IP address belongs to the network address, and which one belongs to the host address in the network itself. In these cases, the subnet mask is used.

To make it easier to understand how the subnet mask works, let's look at a simple example.

We have an IP address of the form 192.168.1.34. And we need to understand to which network this address belongs.

We know that the subnet mask for this address is set to 255.255.255.192.

Now we decompose the IP address and network mask to the binary system and, using the logical AND operation, we get the network address for this IP.

11000000.10101000.00000001.00100010 is an IP address.

11111111.11111111.1.100000000.00000000 is the subnet mask.

Applying the operation "logical AND" results in: 11000000.10101000.00000000.00000000.

And after the conversion to the decimal system - 192.168.0.0. This is the subnet address.

Now that we know the subnet address and network mask - can we find out what the maximum number of IP addresses is on this subnet?

It turns out to be very easy to do. You need to count the number of zeros in the network mask, and raise 2 to the power of this number.

In our example, we need to raise 2 to power 14, and get 16 384 addresses.

If the bits in the network address that correspond to the zeros in the mask are replaced by ones, you can get the Broadcast address.

In our example, we get the address of the form: 11000000.10101000.00111111.11111111 or in the decimal representation - 192.168.63.255.