# need to figure out this subnet mask please is it correct? [duplicate]

Possible Duplicate:
How does IPv4 Subnetting Work?

The largest subnet has 300 hosts so I am trying to workout the number of host_id bits I require for the mask but I am confused as each octet goes to 255 max? So do I carry on in the next octet starting from one. This way I have come to the following subnet mask please check it is correct: Subnet Mask: 255.255.192.0

The supernet mask is then straight forward I assume I have used 14 bits for host_id I have 10 subnets on the intranet including leased lines but I did not include the ATM switch as I believe it is just a switch forwarding packets so not separate subnet is that correct?

OK so 10 subnets that means I need 4 bits, so add 4 + 14 host_id bits = 18

32-18 = 14 subnet_id bits, 2^(32-14)= 262144 possible address

So I have Subnet Mask = 255.255.192.0 and Supernet Mask = /14

Is this calculation accurate? I am confused. Thanks

-

## marked as duplicate by MadHatter, Evan Anderson, longneck, Michael Hampton♦, kceJan 14 '13 at 17:33

You should learn to count in binary. It's fun. – Evan Anderson Jan 14 '13 at 17:06
Yeah its great fun thanks a lot the the help. Real useful, wise guy. – Jatinder Singh Jan 14 '13 at 17:51
I was being serious. You need to learn how to count in binary. Then you can solve arbitrary subnetting problems (and lots of other computer-related problems) versus treating it as a black box and just asking for help. It's all addition and subtraction of whole numbers. – Evan Anderson Jan 14 '13 at 17:53
Yay! @EvanAnderson 's back! Answer a bunch of questions, man, you've deprived us too long! – Ward Jan 14 '13 at 22:10
@Ward: You flatter me... I stopped by briefly today to answer some questions to blow off steam. Unfortunately work has me absolutely hammered, and where work doesn't soak up all my time increasing personal obligations do. I miss Server Fault, and I think about it frequently. >smile< I keep telling my wife "I gotta get some time to work on Server Fault or I'm gonna lose!" – Evan Anderson Jan 15 '13 at 0:00