Subnetting help. Subnets and hosts.

Radiant9Radiant9 Member Posts: 28 ■□□□□□□□□□
Hi all. Hoping you all can help me understand something. I'm really struggling to understand how to quickly figure out how to make subnets to fit a given # of subnets/hosts.

I have read the outstanding thread "Subnetting made easy". I can now go to the subnetting questions websites and do most of them in my head (which I am quite proud of and extremely grateful for). But figuring out the most accurate subnet to get a certain number of hosts just isnt clicking. An example:

I need to design a lab network. I am given the class c network 192.168.7.0/24. I need Subnet A = 110 hosts, Subnet B = 54 hosts. The 0 subnet is used. I need to create the smallest possible subnets that satisfy all requirements.

So, if I may, here's what I understand;
Subnet A needs 110 hosts. The closest power of 2 that fits that is 128 (2^7). So I need to use 7 bits for the hosts? That seems like a TON of bits for 110 hosts. But I understand the binary math of it, so ok. So 32-7=25. So instead of the default /24 mask I would subnet it using a /25 mask? Is that accurate?

Thank you for your help...

Comments

  • j-manj-man Member Posts: 143
    You are correct.

    While using 7 bits for hosts seems like a bunch, it is the only option that meets both requirements. If you used 6 bits, you'd have 62 hosts per subnet which would meet the requirement for one (54 hosts) but would be too small for the other subnet.

    I'm not too sure if VLSM could be used in this case though. I haven't gotten that far.
  • rob_crossleyrob_crossley Member Posts: 38 ■■□□□□□□□□
    VLSM would be used here, so you'd use 192.168.7.0 /25 for the first subnet, which would give you 128 addresses -2 (for the subnet ID and the broadcast address of the subnet), from 192.168.7.0 - 192.168.7.127.

    So for subnet b where you need 54 hosts you would need to borrow 6 bits, giving you 64 addresses (again -2) so you'd use 192.168.7.128 /26 which would give you a range from 192.168.7.128 - 192.168.7.191

    Correct me if im wrong here follow posters.
    Study Hard! Learn Hard! Earn Hard!
    "If you stop learnin, you stop earnin!"
  • Radiant9Radiant9 Member Posts: 28 ■□□□□□□□□□
    But just wasn't sure. Seems like maybe I understand it but just lack confidence. I'll have to keep practicing. If anyone has any more input, please feel free! I really enjoy all the info flying around here.
  • j-manj-man Member Posts: 143
    VLSM would be used here, so you'd use 192.168.7.0 /25 for the first subnet, which would give you 128 addresses -2 (for the subnet ID and the broadcast address of the subnet), from 192.168.7.0 - 192.168.7.127.

    So for subnet b where you need 54 hosts you would need to borrow 6 bits, giving you 64 addresses (again -2) so you'd use 192.168.7.128 /26 which would give you a range from 192.168.7.128 - 192.168.7.191

    Correct me if im wrong here follow posters.

    That makes sense. Just to make sure I'm following VLSM. Let's say the requirement is for three subnets with the first two being the same and the new third requiring 25 hosts. Using VLSM, would the third be a 192.168.7.0/27 which would support 30 hosts and give you the network 192.168.7.192. First address 193, last address 222 and broadcast 223?
  • rob_crossleyrob_crossley Member Posts: 38 ■■□□□□□□□□
    Yeh although the address would be 192.168.7.192/27 because you've already allocated the address range 192.168.7.0 - 191.

    Make sense?
    Study Hard! Learn Hard! Earn Hard!
    "If you stop learnin, you stop earnin!"
  • j-manj-man Member Posts: 143
    Ahhh, 192.168.7.192/27 Got it. It does make sense.

    I somehow missed the 192.168.7.128/26 network reference in your post.

    Thanks much :D
Sign In or Register to comment.