cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
3610
Views
65
Helpful
28
Replies

Subnetting

mainodin87
Level 1
Level 1

Hi Team,

What valid host range is the IP address 10.255.207.175/20 a part of?

Answer: 10.255.192.1 through to 10.255.207.254

i know the concept but is there any simple and quick solution to find the first valid host address, because the IP in question is 10.255.20.175, how to guess the IP will be starting from 10.255.192.0 for this range.

Hope you got what am trying to ask.

Thank You,

Mainodin

2 Accepted Solutions

Accepted Solutions

Joseph W. Doherty
Hall of Fame
Hall of Fame

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 wha2tsoever (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

Hmm, to me, the simple and quick solution is to use a subnet calculator.

If you don't have that, I don't know a quick/simple method, although you can do it manually.

For example, your /20 divides the 3rd octet in half, so if we drop the right most 12 bits, we should have the starting IP for this address range.

i.e.:

207 = 11001111; drop right 4 bits, 11000000, and we have 192.

View solution in original post

:p

Add all 1s after that

1100 1111 1111111

207.255-1 the last usable IP.

View solution in original post

28 Replies 28

Joseph W. Doherty
Hall of Fame
Hall of Fame

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 wha2tsoever (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

Hmm, to me, the simple and quick solution is to use a subnet calculator.

If you don't have that, I don't know a quick/simple method, although you can do it manually.

For example, your /20 divides the 3rd octet in half, so if we drop the right most 12 bits, we should have the starting IP for this address range.

i.e.:

207 = 11001111; drop right 4 bits, 11000000, and we have 192.

Hello,

This is the way I do it

20=  8 + 8 +4(bits for subnet) + 4(bits for host)+ 8(bits for hosts)

You just need to work on 3rd octet

2 ^ 4= 16 so you can have 16 subnets.  256 /16= 16 (range of each subnet)

10.255.0.1

10.255.16.1

10.255.32.1

.....

10.255.192.1

10.255.208.1

...

Another example with /18

18=  8 + 8 +2(bits for subnet) + 6(bits for host)+ 8(bits for hosts)

You just need to work on 3rd octet

2 ^ 2= 4 so you can have 4 subnets.  256 /4= 64 (range of each subnet)

10.255.0.1

10.255.64.1

10.255.128.1

10.255.192.1

At first, it seems deficult but you can do it fast in your mind after some pratice.

Hope it helps,

Masoud

mainodin87
Level 1
Level 1

WOW thank you Joseph, can u pls let me know how to get the last available IP for the same range.

I'm too lazy to use my mind :P

:p

Add all 1s after that

1100 1111 1111111

207.255-1 the last usable IP.

Just to add to this.

If Joe's method works for you then use that but you do need to be able to work out the octet in binary first.

Masoud's way of doing it is the way I always use because there is no need to do binary in your head and is, at least for me,  a lot quicker to calculate.

Jon

mainodin87
Level 1
Level 1

Hey Joseph,

as i'm practicing subnetting, i find it very lengthy process to find network and broadcast adrees, can u pls let me know a simple trick for below question.

i got the answer through lenghty process , is thre any simple calculation for same.

what will be network and broadcast address for below ip ?

46.82.105.190 /19

/19 = 255.255.224.0

Take the first non 255 octet and subtract it from 256 -

256 - 224 = 32 so your subnets go up in 32's ie.

46.82.0.0/19
46.82.32.0/19
46.82.64.0/19
46.82.96.0/19
46.82.128.0/19
etc ...

 you can see 46.82.105.190 falls between 46.82.96.0/19 and 46.82.128.0/19.

So the subnet is 46.82.96.0/19 and then to get the broacast simply take the next subnet and go one back ie.

46.82.128.0/19 is the next subnet so one back from that is 46.82.127.255.

Once you do enough of these you can very quickly work out in your head what the answer is.

Jon

Hello,

The result is the same as jon result with slightly different approach. You can use any approach you are confortable with.

19=  8 + 8 +3(bits for subnet) + 5(bits for host)+ 8(bits for hosts)

You just need to work on 3rd octet

2 ^ 3= 8 so you can have 8 subnets.  256 /8 = 32 (range of each subnet)

46.82.0.0/19
46.82.32.0/19
....
46.82.96.0/19
46.82.128.0/19

network = 46.82.96.0    broadcast =46.82.127.255(one less than the next network)

Masoud

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 wha2tsoever (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

Well you can do it as both Masoud or Jon posted (or you can use a subnet caculator), but you can also do it in binary, similar to what I showed before.

As Masoud notes, a /19 uses the first 19 bits for the network and the remaining bits for host.  Remember, for a network address, we ignore the host bits.  For the network broadcast address, all the host bits are 1.

So also knowing the octets that will change will be the 3rd and 4th and also knowing the 4th octet will be zero (for network address) and 255 for broadcast, we only need to look at how the 3rd octet changes.

46.82.105.190 /19

3rd octet for 105 = 01101001 = 01100000 = 96, so network address = 46.82.96.0 /19

3rd octet for 105 = 01101001 = 01111111 = [edit]127, so broadcast address = 46.82.127.255 /19

BTW, similar applies with IPv6 addresses.  But as they are represented in hexidecimal, they are actually easier to convert, if needed, to/from binary.

If IPv4 was represented like IPv6, 46.82.105.190 /19 would appear like: 2E:52:69:BE/19

the network address would be: 2E:52:60:0/19 or 2E:52:60::/19  and the broadcast address 2E:52:DF:FF/19 

Hey Joseph,

Masoud and Jon's method is also good will practice that too, but in binary got one confusion,

how did you get broadcast address means,

for network address 3rd octed i got it its 01100000 which is 64+32 = 96

but 3rd octed for 105 to get broadcast = 01111111 which will be 64+32+16+8+4+2+1= 127 how did you get 223 ?

Hello,

It is just a typing mistake or Jopesph just copied and pasted it.

01111111 = 127.

Masoud

Yup, and I just edited my post.

Hey,

what will be number of subnet and host per subnet for below, i thought as per subnet mask the answer will be same but its different, want to know why and how ?

192.168.25.2 with subnet mask 255.255.255.192

10.100.25.2 with subnet mask 255.255.255.192

Thank you,

Mainodin

Hello,

They have the same number of hosts which is 64. (256-192=64)

Another way 255.255.255.192 =/26    32-26=6    2^6=64

You can create subnets when you change the subnet mask.

For example if you change the subnet mask from /26 to /28 in your example above, you have created 4 subnets.

192.168.25.0/26       = 192.168.25.0 192.168.25.63

192.168.25.0/28       = 192.168.25.0 192.168.25.15

192.168.25.16/28       = 192.168.25.16 192.168.25.31

192.168.25.32/28       = 192.168.25.32 192.168.25.47

192.168.25.48/28       = 192.168.25.48 192.168.25.63

Hope it helps,

Masoud

Review Cisco Networking for a $25 gift card