Clarification on finding number of useable subnets
AP1
Member Posts: 3 ■□□□□□□□□□
in CCNA & CCENT
I have Lammle's 5th edition book. To determine the number of useable subnets he says to use the equation 2^x (where x = number of bits turned on for the mask). So for a 255.255.255.224 (/27) (11100000) mask the equation would be 2^3 = 8 subnets. However, in the very same book (3rd edition) he writes the equation as as 2^x - 2, so 2^3 - 2 = 6 useable subnets.
Can someone explain to me which is correct, and if the latter is correct, why wo you need to subract 2 from the subnets? I already understand why for host addresses but am confused as to why the different equations.
TIA
Can someone explain to me which is correct, and if the latter is correct, why wo you need to subract 2 from the subnets? I already understand why for host addresses but am confused as to why the different equations.
TIA
Comments
-
Tricon7 Inactive Imported Users Posts: 238AP1 wrote:I have Lammle's 5th edition book. To determine the number of useable subnets he says to use the equation 2^x (where x = number of bits turned on for the mask). So for a 255.255.255.224 (/27) (11100000) mask the equation would be 2^3 = 8 subnets. However, in the very same book (3rd edition) he writes the equation as as 2^x - 2, so 2^3 - 2 = 6 useable subnets.
Can someone explain to me which is correct, and if the latter is correct, why wo you need to subract 2 from the subnets? I already understand why for host addresses but am confused as to why the different equations.
TIA
8 is correct; it is the total number of subnets available in your example. However, you have to subract 1 bit for the network and 1 bit for the broadcast, leaving 6 *usable* subnets. This is where the subtract-2 comes from. Make sense? -
AP1 Member Posts: 3 ■□□□□□□□□□No it does not. Because I thought you only subtract 2 from the availbale numer of host addresses, to get the network address and the broadcast address. I was not under the impression that I did not need to subtract for a subnet network address and a subnet broadcast address. Do I?
Like this question from subnettingquestions.comQuestion: How many subnets and hosts can you get from the network 172.29.0.0/24?
Answer: 256 subnets and 254 hosts
8 bits on for the subnet, 8 bits off for the host addresses. So 2^8 = 256 useable subnets. 2^8 - 2 = 254 useable hosts (minus 2 for the network and broadcast addresses).
Why isn't the correct answer for useable subnet hosts 254 then?
I guess what I am getting at is what is on the CCNA test? Can I use the .0 and .255 subnets? IE, would the answer on the CCNA test be 254 useable subents or 256? -
EdTheLad Member Posts: 2,111 ■■■■□□□□□□This topic has been discussed many times,do a search on the ccna forum for subnet-zero,you can also find a good document on this at www.cisco.com, on the exam you are told if subnet-zero is enabled or not for this type of question.Networking, sometimes i love it, mostly i hate it.Its all about the $$$$
-
dracula Member Posts: 9 ■□□□□□□□□□i've also got lammle 5th ed. my understanding is:
2^3 subnets if: "ip subnet-zero"
2^3 (-2) subnets if: "no ip subnet-zero"
haven't sat my ccna (yet), but from what i gather, one should assume ip subnet zero is NOT being used on the exam unless otherwise stated.
hosts are always 2 ^ n (-2) regardless of ip subnet zero (1 for network, 1 for broadcast)
i seem to recall reading somewhere that that exam objective (ip subnet zero) has changed in recent years which might account for the disparity between lammle 3rd and 5th edition.
i believe that is right but somebody pls jump in and correct if need be. -
AP1 Member Posts: 3 ■□□□□□□□□□Thanks Dracula, I thought that it had something to do with ip subnet-zero, just not sure what was expected on the test.
Thanks man. I understand the hosts aspect of it, just wasn't clear on why the discrepancies between the number of useable hosts. -
dracula Member Posts: 9 ■□□□□□□□□□AP1 - read the recent "Ambiguous questions regarding subnetting (subnet zero)" thread if you haven't...
sorry - seems that, if anything, one SHOULD assume "ip subnet-zero" on the exam (unless otherwise stated). i suppose that makes sense since the command is on by default cisco IOS v12 upward.