Super User is a question and answer site for computer enthusiasts and power users. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

The number of subnets depends on the number of borrowed bits, but with the number of usable host is the thing that is not clear to me just like in this example.. I don't know where did the raised number come from....

enter image description here

share|improve this question
up vote 2 down vote accepted

Every IP address can be split into two parts: a "prefix", which basically specifies which network the associated host is on, and a host number on that network. An address can thus be considered to have a "netmask" or "prefix length", which determines where that split occurs (ie: which bits are in the prefix vs the host address). This information is often shown in one of two forms:

  • As an "IP address" where all one-bits represent the prefix and all zero-bits represent the host, like; or
  • As a number between 0 and 32, which represents the prefix length. That number typically follows the IP address, and is immediately preceded by a slash. For instance, the netmask has 26 one-bits, so an address with that netmask would look like /26.)

The 216, 211, etc come from the number of bits in the host part of the address -- that is, the number of bits not taken up by the prefix. The exponent is equal to the number of zero-bits in the netmask, or (32 - the prefix length). For example, the netmask for has (32 - 26) == 6 zero-bits, so there are 26 == 64 possible addresses on that network.

There are two special addresses, though, which is where the "- 2" in the math comes from. If the host-part of the address has all bits 0, that's the network address and is considered semi-special. If they're all 1, it's the broadcast address for that subnet. Most networks will not assign either of those addresses to hosts on the network, as all sorts of wackiness could ensue.

With all that said, it looks like your example pic considers the effect of splitting an existing /16 ("class B") address block into smaller subnets by "borrowing" bits from the host part of the address to lengthen the prefix.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .