cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
1704
Views
0
Helpful
10
Replies

help with /17 and /18 subnetting

Akbarayub
Level 1
Level 1

Dear all,
I was wondering if someone could help me with class B /17 and 18 subnetting i don't understand how the octets increment i find subnetting easy on class C now but get confuse with increments with class B. . I would appreciate if you can provide me with examples for the whole range so that i can make my own conclusions. Thanks in advance.

10 Replies 10

JohnTylerPearce
Level 7
Level 7

A /17 is using 17 bits for the network prefix, so with a class B , you are reserving one bit for the network portion 15 for host bits. So you are going to have 2 subnets and 32766 hosts if I did my math right. 184.64.0.1 - 184.64.127.254 and 184.64.128.1 - 184.64.255.254.



Sent from Cisco Technical Support Android App

Akbarayub
Level 1
Level 1

Thank you for the prompt response. But i thought on a /17 it increments at 128 and your example is showing 64 i think.

Sent from Cisco Technical Support iPhone App

Your math is not correct. John is correct that a /17 would have only two subnets in which the third octet would start at 0 and increment to 128 as his post shows.

HTH

Rick

HTH

Rick

Akbarayub
Level 1
Level 1

Thank you for the response how do you figure out the number of hosts?

Sent from Cisco Technical Support iPhone App

Disclaimer

The  Author of this posting offers the information contained within this  posting without consideration and with the reader's understanding that  there's no implied or expressed suitability or fitness for any purpose.  Information provided is for informational purposes only and should not  be construed as rendering professional advice of any kind. Usage of this  posting's information is solely at reader's own risk.

Liability Disclaimer

In  no event shall Author be liable for any damages whatsoever (including,  without limitation, damages for loss of use, data or profit) arising out  of the use or inability to use the posting's information even if Author  has been advised of the possibility of such damage.

Posting

Actually what John showed was the addresses for hosts, actual address blocks would be:

x.x.0.0/16 (x.x.0.0 - x.x.255.255)

x.x.0.0/17 (x.x.0.0 - x.x.127.255)

x.x.0.0/18 (x.x.0.0 - x.x.63.255)

x.x.64.0/18 (x.x.64.0 - x.x.127.255)

x.x.128.0/17 (x.x.128.0 - x.x.255.255)

x.x.128.0/18 (x.x.128.0 - x.x.191.255)

x.x.192.0/18 (x.x.192.0 - x.x.255.255)

Hosts are 2 to the N (host bits) - 2.  So for a /16 you have 2**16-2=65,534; for /17 2**15-2=32,766; and for /18 2**14-2=16,382

Akbarayub
Level 1
Level 1

Thank guys still not sure how to do class B subnetting.

Sent from Cisco Technical Support iPhone App

You have told us that you are comfortable with subnetting of class C where the subnets are configured in the fourth octet. Subnetting with a class B is quite similar where the subnets are configured in the third octet.

HTH

Rick

HTH

Rick

Akbarayub
Level 1
Level 1

Dear Rick,
Thanks for the prompt response. Yeah i can easily subnet class C using the magic number method. I get all confused with class B for some strange reason. I just wanted some clear examples to help me understand it.

Sent from Cisco Technical Support iPhone App

This works for me. I hope that it will work for you also:

! class C subnetting

mask /30  number of host bits 2 number of hosts (2^n - 2)  = 2

mask /29  number of host bits 3 number of hosts (2^n - 2)  = 6

mask /28  number of host bits 4 number of hosts (2^n - 2)  = 14

mask /27  number of host bits 5 number of hosts (2^n - 2)  = 30

mask /26  number of host bits 6 number of hosts (2^n - 2)  = 62

mask /25  number of host bits 7 number of hosts (2^n - 2)  = 126

mask /24  number of host bits 8 number of hosts (2^n - 2)  = 254

! class B subnetting

mask /23  number of host bits 9 number of hosts (2^n - 2)  = 510

mask /22  number of host bits 10 number of hosts (2^n - 2)  = 1022

mask /21  number of host bits 11 number of hosts (2^n - 2)  = 2046

mask /20  number of host bits 12 number of hosts (2^n - 2)  = 4094

mask /19  number of host bits 13 number of hosts (2^n - 2)  = 8190

mask /18  number of host bits 14 number of hosts (2^n - 2)  = 16382

mask /17  number of host bits 15 number of hosts (2^n - 2)  = 32766

mask /16  number of host bits 16 number of hosts (2^n - 2)  = 65534

HTH

Rick

HTH

Rick

Hi Akbar

There is simple rule of subnetting forgot class A,B,C. Just you need to remember the number bits you have to borrow from host part to network.

There would be 2 questions :

1. You know the host count and you need to create subnet accordingly.

For example you have 172.16.0.0/16 network and you required to create subnets so that each subnet have 500 hosts.

Answer> so for that you use the formula:      2^n-2 => 502  so from here  you need to get the value of n (where n is number of host bits)

here in our case n=9

172.16. _ _ _ _ _ _ _/ _ . _ _ _ _ _ _ _ _ :::::: So here you can see the / is distingusing the subnet or network part with host. 

So the first subnetwork will be  172.16.0.0/25    

First ip : 172.16.0.1

last IP : 172.16.1.254

Broadcast IP : 172.16.1.255

Hope this will help you.