Google
 

Step 2: Satisfy Host and Network Requirements
In the second step, you�ll use three formulas:

1. 2 power of X => number of networks you need (X represents subnet bits)
2. 2 power of Y - 2 => number of hosts on your largest segment (Y represents host bits)
3. X + Y <= total number of host bits


In the first step, you need to figure out how many bits you need to steal from the host bits to create your subnets. In the second step, you need to figure out how many host bits you need to accommodate your host requirements. And last, you need to make sure that when you add up the bits that you stole for subnets, and the bits that you need for your hosts, that you didn�t exceed the original number of host bits that you started out with, based on the class A, B, or C network.

As an example, if you had a Class C network and were subnetting it and needed 5 bits for subnets and 4 bits for hosts, this would total 9 bits. Unfortunately, Class C networks only have 8 host bits to begin with, so this wouldn�t work. In this situation, you would either need a Class B network or 2 Class C networks. As an other example, if you had the same Class C network and were subnetting it, and you needed 3 bits for subnets and 4 bits for host addresses, this would total 7 bits. In this situation, the Class C network as 8 bits, and you only need 7. This gives you some flexibility--you could use the extra bit to either create more subnets, or to have more hosts with your 3 bits of subnets.

Let�s go back to our original example of 192.168.1.0, where you need 14 subnets with a maximum of 14 hosts on each:

1. 2 power of X => 14 subnets; in this example, X needs to be 4, which would result in 16 subnets.
2. 2 power of Y - 2 => 14 hosts; in this example, Y needs to be 4, which would result in 14 hosts.
3. X + Y <= 8 (class C network); in this example 4 + 4 is less than or equal to 8.


Let�s break this down step-by-step. In the first step, you need to find a power of 2 that will give a number that is either equal to or greater than the number of subnets that you need. In our example, the power of 2 needs to be 4: 2 power of 4 = 16. This meets our subnet requirements, since we only need 14 subnets (there are only 14 segments).

Next, you need to figure out your hosts bits by using this formula: 2 power of Y - 2 => 14 required hosts; where Y is the necessary number of host bits. In this example, 2 power of 4 - 2 = 14, so you need 4 host bits to get your required 14 hosts.

And last, since we are dealing with a class C network, we only have 8 original host bits. We need to make sure that the total of our subnetting and host bits does not exceed this original value. In our case, 4 + 4 = 8, so we�re okay. If the number of bits totaled higher than 8, then we would need two Class C networks, or a Class B network. If the number of bits were less than 8, then we could allocate the extra bit or bits to either create more subnets and/or hosts. Remember that if you are ever in this situation where you have extra bits to deal with, then you need to closely examine your network and figure out, based on future growth, whether you should create more subnets, or allow for more hosts on a subnet.

ccnaguru.com

Step 3 >>>