04-10-2008 03:53 AM - edited 03-05-2019 10:19 PM
Hi. I just need to clarify if ip subnetzero is enabled, does that mean i can use subnetworks as ip addresses like 192.168.0.0 for example?
Thanks in advance.
Solved! Go to Solution.
04-10-2008 04:19 AM
No that's not what ip subnet-ero means.
192.168.0.0 255.255.255.0 = subnet 192.168.0
You can use this subnet but 192.168.0.0 is not an address, it is a subnet number so the first address would be
192.168.0.1 255.255.255.0
You generally wouldn't want to allocate another IP out of the same subnet to another interface on the same router - with ethernet it will not let you, with serial i seem to remember reading on this forum that the router will let you do this but not sure why you would want to.
Jon
04-10-2008 03:55 AM
Assuming 192.168.0.0/24 yes it does mean that.
Jon
04-10-2008 04:02 AM
Just to clarify, does that mean that i can assign an ip add of 192.168.0.0/24 on one serial int and 192.168.0.1/24 on another attached serial interface within the same subnet which is 192.168.0.0/24?
04-10-2008 04:19 AM
No that's not what ip subnet-ero means.
192.168.0.0 255.255.255.0 = subnet 192.168.0
You can use this subnet but 192.168.0.0 is not an address, it is a subnet number so the first address would be
192.168.0.1 255.255.255.0
You generally wouldn't want to allocate another IP out of the same subnet to another interface on the same router - with ethernet it will not let you, with serial i seem to remember reading on this forum that the router will let you do this but not sure why you would want to.
Jon
04-10-2008 04:31 AM
Hi Jon
I just checked using Dynamips, and you are correct. A router will except IP addresses from the same subnet/network on serail interfaces.
Well blow me down with a feather!
Best Regards,
Michael
04-10-2008 04:26 AM
Hi Marcus
No, I don't think a router will not allow you to configure two separate interfaces with IP addresses from the same subnet or over lapping subnets (i.e. 192.168.0.1/16 and 192.168.1.1/24) for that matter.
***Edit*** This statement is not strictly correct, as a router will allow you to configure IP addresses from the same subnet on Serial interfaces. The above statement only applies to Ethernet interfaces. Thanks Jon *** End of Edit ***
Also having "ip subnet zero" enabled has nothing to do with configuring a subnet number on an interface. Whether "ip subnet zero" is enabled or not it is considered bad design practice to assign either the network/subnet number or the broadcast IP address to any interface, whether the equipment will accept this configuration or not.
The algorithm for working out the usable host IP addrsses on a subnet is (h^2)-2, where "h" equals the number of host bits (contiguous "0's") in the subnet mask, reading in binary from right to left. On a /24 subnet this figure is 254 or (8^2) = 256 -2 = 254.
Enabling "ip subnet zero" allows the use of the first and last subnets when subnetting a major network.
E.g
If you had the major network 152.16.0.0/16 and you want to subnet it using a /24 bit mask.
With "ip subnet zero" enabled the algorithm to work out the number of subnets is n^2, where "n" is equal to the number of host bits borrowed. 8^2=256, so you have 256 usable subnets.
With "ip subnet zero" disabled, the algorithm is (n^2)-2, where "n" is equal to the number of hosts bits borrowed. (8^2) = 256 -2 = 254, so you can only use 254 subnets.
HTH
Best Regards,
Michael
04-10-2008 04:20 AM
Jon, sorry to disturb you again. I got a bit confused on the subnet issue. Given an ip of 192.168.0.0/24, the total no. of subnets according to the formula is 254 right? But the actual subnet range would be from 192.168.0.0/24 to 192.168.254.0/24 isn't it?
Then the total would be 255. Is this right?
04-10-2008 04:26 AM
No problem.
192.168.0.0/24 = 192.168.0.0 255.255.255.0 = 1 subnet with 254 possible host addresses
Where your confusion comes from is the subnet mask ie. /24.
192.168.0.0/16 = 192.168.0.0 255.255.0.0 is what you are thinking of.
Jon
04-10-2008 04:34 AM
But considering that i intend to use 192.168.0.0/24, the subnet range would be 192.168.0.0/24 till 192.168.254.0 right? Which is a total of 255 subnets?
04-10-2008 04:36 AM
Okay i see the confusion. Yes your subnets would be
192.168.0.0/24
192.168.1.0/24
192.168.2.0/24
which is summarisable as 192.168.0.0/16.
Does this make sense ?
Jon
04-10-2008 05:00 AM
Thanks for your patience Jon. I guess i was referring to your previous statement where you said:
With "ip subnet zero" enabled the algorithm to work out the number of subnets is n^2, where "n" is equal to the number of host bits borrowed. 8^2=256, so you have 256 usable subnets.
Considering that i intend to use 192.168.0.0/24, does that mean that aside from being able to use 192.168.0.0/24 as a subnet, i can also use 192.168.255.0/24 as a subnet? If this is the case, the broadcast address of subnet 192.168.255.0/24 is 192.168.255.255 right? I think i get it now.
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