02-12-2012 06:35 AM - edited 03-07-2019 04:52 AM
My professor gave us a task in our networking class a few weeks before. The task was:
Given IP address
192.168.10.0
Make a subnet that has 127 hosts
My professor's answer was: (network address | host range | broadcast address)
192.168.10.0 | 192.168.10.1 - 192.168.10.126 | 192.168.10.127
192.168.10.128 | 192.168.10.129 - 192.168.10.254 | 192.168.10.255
My answer was: (network address | host range | broadcast address)
192.168.10.0 | 192.168.10.1 - 192.168.10.254 | 192.168.10.255
Now, my question is: Was my answer wrong?
Solved! Go to Solution.
02-12-2012 06:45 AM
Hi Nathaniel,
I am afraid your professor was not correct. The answer he/she gave provides only 126 usable addresses for hosts.
On the other hand, your answer is correct in the sense that it has enough addresses for 127 hosts. As a matter of fact, the smallest network that allows for 127 hosts must contain at least 256 addresses in total - because on top of 127 host addresses, you also need the network address itself and the broadcast address, leading to an address requirement of 127+2=129 addresses at least. The nearest network accomodating 129 addresses (including the two reserved addresses) is indeed the network with 256 addresses, as you correctly suggested.
Best regards,
Peter
02-12-2012 06:45 AM
Hi Nathaniel,
I am afraid your professor was not correct. The answer he/she gave provides only 126 usable addresses for hosts.
On the other hand, your answer is correct in the sense that it has enough addresses for 127 hosts. As a matter of fact, the smallest network that allows for 127 hosts must contain at least 256 addresses in total - because on top of 127 host addresses, you also need the network address itself and the broadcast address, leading to an address requirement of 127+2=129 addresses at least. The nearest network accomodating 129 addresses (including the two reserved addresses) is indeed the network with 256 addresses, as you correctly suggested.
Best regards,
Peter
02-12-2012 06:58 AM
That's what I was trying to explain to the professor but she insisted that I was wrong.
I appreciate the response,
Nath
02-12-2012 04:03 PM
Hi Nath,
I would like to add something.
If you teacher asked for a subnet for 127 hosts as you mentioned above, I think she is right. The difference is the word "usable". If she asked for 127 usable ip addresses your answer will be right.
Because she asked for 127 hosts (not usable hosts) her answer is right, because the last IP is brodcast IP for that subnet and belongs to all hosts (every host in that subnet can use that ip address to broadcast information to all other hosts in the subnet).
I hope this helps
Eugen
02-12-2012 04:14 PM
Eugen,
Actually, in our class, when she asks for a number of hosts it is always understood as "usable hosts" where 2^n-2. That's the reason why she provided a second subnet, as you can see in the example she gave. She said 192.168.10.129 is the 127th host.
Nath
02-12-2012 04:29 PM
I don't know in what context she asked the question, but 192.168.10.129 is the first usable host IP in subnet 192.168.10.128 from what I know. If you configured 192.168.10.1 and 192.168.10.129 on two PCs connected to a switch they wont be able to communicate and her explanation and answer is wrong.
Eugen
02-14-2012 09:48 AM
Thank you for the response. I appreciate it.
02-14-2012 09:59 AM
Hello Eugen,
The difference is the word "usable". If she asked for 127 usable ip addresses your answer will be right.Because she asked for 127 hosts (not usable hosts) her answer is right
I respectfully disagree here. You seem to suggest that the word host is interchangeable with the word address. However, that is not correct. A host is always a node in a network - be it an end node or a transit node. You can not assign an unusable address to a node in a network - its operating system will refuse to use the network or broadcast address as its own address. Hence, there is no concept of "usable hosts".
Best regards,
Peter
02-14-2012 05:08 PM
Hello Peter,
I respectfully agree with you. You are right, I used the wrong words to explain it.
Thank you for correcting me, that way other people reading this post will have the right answer. I will pay more attention next time.
Regards
Eugen
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide