jskfan
asked on
IP Subnetting
IP Subnetting
I have this Prefix 224.0.0.0/4 , If I am not wrong this will cover 224.0.0.0 to 239.255.255.255.
OK, if I will have to demonstrate that using binary, how can I do that ?
224.0.0.0
224 = 1110 0000 then the rest is 0000 0000 . 0000 0000 . 0000 0000
so where does the /4 belong there ?
Thank you
I have this Prefix 224.0.0.0/4 , If I am not wrong this will cover 224.0.0.0 to 239.255.255.255.
OK, if I will have to demonstrate that using binary, how can I do that ?
224.0.0.0
224 = 1110 0000 then the rest is 0000 0000 . 0000 0000 . 0000 0000
so where does the /4 belong there ?
Thank you
this ip range is belongs to multicasting ... not for unicast.
check the following link about it
http://www.dcs.gla.ac.uk/~lewis/networkpages/m05s08multicast.htm
all the best
check the following link about it
http://www.dcs.gla.ac.uk/~lewis/networkpages/m05s08multicast.htm
all the best
ASKER
What I meant is : 224.0.0.0/4
in Decimal going from
224.0.0.0 to 239.255.255.255
in Binary is from
224: 1110 0000 TO 239: 1110 1111
if it was 240 them it will be 1111 0000
is there a pattern in Binary when they give you for instance 224.0.0.0/4 you can demonstrate it how it gets the 239 ?
for instance if it was : 224.0.0.0/5 or 224.0.0.0/6
in Decimal going from
224.0.0.0 to 239.255.255.255
in Binary is from
224: 1110 0000 TO 239: 1110 1111
if it was 240 them it will be 1111 0000
is there a pattern in Binary when they give you for instance 224.0.0.0/4 you can demonstrate it how it gets the 239 ?
for instance if it was : 224.0.0.0/5 or 224.0.0.0/6
yes: You showed it yourself....
224-239 = 1110 xxxx where xxxx ranges from 0000 -> 1111
The netmask means:
So you endup wih networks 224 ... 239. for the first BYTE.
In this case hex bytes might show it also:
Ex xx xx xx
Fx xx xx xx
--------------- &
E0 00 00 00
EF FF FF FF
For all addresses. E0 = 224, EF = 239.
224-239 = 1110 xxxx where xxxx ranges from 0000 -> 1111
The netmask means:
1110xxxx xxxxxxxx xxxxxxxx xxxxxxxx
11110000 00000000 00000000 00000000
If you do bitwise AND al the xxxx are don't cares for the network part of the address.So you endup wih networks 224 ... 239. for the first BYTE.
In this case hex bytes might show it also:
Ex xx xx xx
Fx xx xx xx
--------------- &
E0 00 00 00
EF FF FF FF
For all addresses. E0 = 224, EF = 239.
ASKER
what about
224.0.0.0/5 and 224.0.00/6
how do you break it down into binary ?
224.0.0.0/5 and 224.0.00/6
how do you break it down into binary ?
/5 = 5 one bits, /6 = 6 one bits. (/32 = specific host, /31 makes no sense, /30 smalletsdeclarable network).
/5 = 11111000 0000....0
/6 = 11111100 0000....0
11100000 and 11111000 makes: 11100xxx as relevant network = 224 .. 231
11100000 and 11111100 makes: 111000xx as relevant network = 224 .. 227
please try to find ipcalc and use that to see other patterns.
(btw, the rules apply only to the addresses 1.0.0.0 - 223.255.255.255 as thsoe are regular routable addresses)
0.0.0.0/8 is specials as it means the local network.... and 224.0.0.0 - 239.255.255.255 are special because the are multicast addresses and as such handled differently.
240.0.0.0 255.255.255.254 are special experimental addresses.
255.255.255.255 is the universal broadcast address. (only work on the LAN though).
/5 = 11111000 0000....0
/6 = 11111100 0000....0
11100000 and 11111000 makes: 11100xxx as relevant network = 224 .. 231
11100000 and 11111100 makes: 111000xx as relevant network = 224 .. 227
please try to find ipcalc and use that to see other patterns.
(btw, the rules apply only to the addresses 1.0.0.0 - 223.255.255.255 as thsoe are regular routable addresses)
0.0.0.0/8 is specials as it means the local network.... and 224.0.0.0 - 239.255.255.255 are special because the are multicast addresses and as such handled differently.
240.0.0.0 255.255.255.254 are special experimental addresses.
255.255.255.255 is the universal broadcast address. (only work on the LAN though).
ASKER
/5 = 11111000 = 248
/6 = 11111100 = 252
I do not see how you came up with 231 and 227
/6 = 11111100 = 252
I do not see how you came up with 231 and 227
@Jskfan: for the NETMASK you are right.... for the 224 network... the ADDRESS is:
/5 = 1110X000 (network address bitwise AND with NETMASK.)
/6 = 1110XX00
/5 = 1110X000 (network address bitwise AND with NETMASK.)
/6 = 1110XX00
ASKER
so when they give you addresses below, what are the steps in binary to take to get to the address range covered :
224.0.0.0/5 ---
First Usable: 224.0.0.1 Last Usable: 231.255.255.254 --- How did they get to 231 ?
224.0.0.0/6
First Usable: 224.0.0.1 Last Usable: 227.255.255.254 --- How did they get to 227 ?
224.0.0.0/5 ---
First Usable: 224.0.0.1 Last Usable: 231.255.255.254 --- How did they get to 231 ?
224.0.0.0/6
First Usable: 224.0.0.1 Last Usable: 227.255.255.254 --- How did they get to 227 ?
When you bitwise AND the netmask with the IP address you get a number : the network address..... If the network address is different it is another network..
/5 case:
So for /5:
224 - 231 1110 0XXX where XXX is indifferent (see above table) then XXX = 000 is the lower bound and XXX=111 is the upper bound.
224 + 0 = 224, 224 + 7 = 231. ( the remainder of the address range also 0000 0000 = 0, until 1111 1111 = 255)
So for /6:
224 - 227 1110 00XX where XX is indifferent (see above table) then XX = 00 is the lower bound and XX=11 is the upper bound.
224 + 0 = 224, 224 + 3 = 227. ( the remainder of the address range also 0000 0000 = 0, until 1111 1111 = 255)
makes: 224.0.0.0 - 227.255.255.255
In Normal network ranges the IP with alle zeros is the ME host, and the the IP with all 1's is the everyone else IP, therefor the first and the last address cannot be used.
You example is rather different as the 224.0.0.0/4 is a special range (Class D, or Multicast network) so ALL addresses will receive data if they subscribe using IGMP.
The IGMP is done on behalf of the application by the TCPIP stack. (Create a socket & bind... it to one of these addresses).
So all addresses are usable for this multicast network as each address is on its own a multicast address.
/5 case:
| netmask | netid
223 = 1101 1111 | 1111 1000 | 1101 0000 =216
224 = 1110 0000 | 1111 1000 | 1110 0000 =224
225 = 1110 0001 | 1111 1000 | 1110 0000 =224
226 = 1110 0010 | 1111 1000 | 1110 0000 =224
227 = 1110 0011 | 1111 1000 | 1110 0000 =224
228 = 1110 0100 | 1111 1000 | 1110 0000 =224
229 = 1110 0101 | 1111 1000 | 1110 0000 =224
230 = 1110 0110 | 1111 1000 | 1110 0000 =224
231 = 1110 0111 | 1111 1000 | 1110 0000 =224
232 = 1110 1000 | 1111 1000 | 1110 1000 =232
/6 case: | netmask | netid
223 = 1101 1111 | 1111 1100 | 1101 0000 =216
224 = 1110 0000 | 1111 1100 | 1110 0000 =224
225 = 1110 0001 | 1111 1100 | 1110 0000 =224
226 = 1110 0010 | 1111 1100 | 1110 0000 =224
227 = 1110 0011 | 1111 1100 | 1110 0000 =224
228 = 1110 0100 | 1111 1100 | 1110 0000 =228
229 = 1110 0101 | 1111 1100 | 1110 0000 =228
230 = 1110 0110 | 1111 1100 | 1110 0000 =228
231 = 1110 0111 | 1111 1100 | 1110 0000 =228
232 = 1110 1000 | 1111 1100 | 1110 1000 =232
The boundary value is the one still in the same net.... So for /5:
224 - 231 1110 0XXX where XXX is indifferent (see above table) then XXX = 000 is the lower bound and XXX=111 is the upper bound.
224 + 0 = 224, 224 + 7 = 231. ( the remainder of the address range also 0000 0000 = 0, until 1111 1111 = 255)
So for /6:
224 - 227 1110 00XX where XX is indifferent (see above table) then XX = 00 is the lower bound and XX=11 is the upper bound.
224 + 0 = 224, 224 + 3 = 227. ( the remainder of the address range also 0000 0000 = 0, until 1111 1111 = 255)
makes: 224.0.0.0 - 227.255.255.255
In Normal network ranges the IP with alle zeros is the ME host, and the the IP with all 1's is the everyone else IP, therefor the first and the last address cannot be used.
You example is rather different as the 224.0.0.0/4 is a special range (Class D, or Multicast network) so ALL addresses will receive data if they subscribe using IGMP.
The IGMP is done on behalf of the application by the TCPIP stack. (Create a socket & bind... it to one of these addresses).
So all addresses are usable for this multicast network as each address is on its own a multicast address.
ASKER
the way I see it , is the difference in Binary , I mean substract whatever number after the slash "/" from number 8
for instance 224.0.0.0/5
224=1110 0000
with /5 means substract 5 bits from 8 , we are left with 3 bits , and 2^3=8 , we know that 224+8=232 which is the next network , the last usable address is 231. 255.255.254
with /6 means substract 6bits from 8 ,we are left with 2 bits , and 2^2=4 , we know that 224+4=228 which is the next network, the last usable address is 227.255.255.254
with /7 means substract 7 bits from 8 , we are with 1 bit , 1^2 =2 we know that 224+2=226 which is the next network, the last usable address is 225.255.255.254
for instance 224.0.0.0/5
224=1110 0000
with /5 means substract 5 bits from 8 , we are left with 3 bits , and 2^3=8 , we know that 224+8=232 which is the next network , the last usable address is 231. 255.255.254
with /6 means substract 6bits from 8 ,we are left with 2 bits , and 2^2=4 , we know that 224+4=228 which is the next network, the last usable address is 227.255.255.254
with /7 means substract 7 bits from 8 , we are with 1 bit , 1^2 =2 we know that 224+2=226 which is the next network, the last usable address is 225.255.255.254
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thank you
$ ipcalc 224.0.0.0/4
Address: 224.0.0.0 1110 0000.00000000.00000000.000
Netmask: 240.0.0.0 = 4 1111 0000.00000000.00000000.000
Wildcard: 15.255.255.255 0000 1111.11111111.11111111.111
=>
Network: 224.0.0.0/4 1110 0000.00000000.00000000.000
HostMin: 224.0.0.1 1110 0000.00000000.00000000.000
HostMax: 239.255.255.254 1110 1111.11111111.11111111.111
Broadcast: 239.255.255.255 1110 1111.11111111.11111111.111
Hosts/Net: 268435454 Class D, Multicast
Be aware that this is a special case network part namely the multicast addresses.
Those are handled differently by the IP stack. (csee also IGMP)