Finding what's after the slash
Barry Margolin
barmar at genuity.net
Thu May 11 20:40:16 UTC 2000
In article <00051114144601.00395 at sparc1.np.rbp.com.br>,
augusto bott <augusto.bott at via-rs.net> wrote:
>I've seen lots of messages, texts and pages around and was trying to figure
>out how one can know what to write after a slash ("/") on a subnet...
>
>like, for instance, 10.1.1.0/26 meaning ip's from 10.1.1.1 untill 10.1.1.50
>(is this statement correct?)
No. It goes from 10.1.1.0 to 10.1.1.63.
Subnets are always a power of 2 in size.
>i.e., for a net like 192.168.2.45 untill 192.168.2.221 it would be what?
>Thanks...
The smallest block that encompasses that range is 192.168.2.0/24, i.e. the
whole class C.
The number after the slash is the number of 1-bits in the corresponding
subnet mask. If you're looking for a simple formula, for subnets of a
class C (i.e. only the last byte varies), subtract the last byte of the
mask from 256, determine what power of 2 that is, and then add that to 24.
--
Barry Margolin, barmar at genuity.net
Genuity, Burlington, MA
*** DON'T SEND TECHNICAL QUESTIONS DIRECTLY TO ME, post them to newsgroups.
Please DON'T copy followups to me -- I'll assume it wasn't posted to the group.
More information about the bind-users
mailing list