The Prefix Length
Expressing network addresses and host addresses with the dotted decimal subnet mask address is very difficult. So there is an alternate method of identifying a subnet mask called the prefix length. The prefix length is the number of bits set to 1 in the subnet mask. It is written in “slash notation”, which is a “/” followed by the number of bits set to 1 in the subnet mask. Therefore, count the number of bits in the subnet mask and write slash followed by the number of bits set to 1.
The table in the figure illustrates the slash notation. The first column lists various subnet masks that can be used with a host address. The second column displays the converted 32-bit binary address. The last column displays the resulting prefix length.
The Subnet Mask | 32-bit address | Prefix-length |
255.0.0.0 | 11111111.00000000.00000000.00000000 | /8 |
255.128.0.0 | 11111111.10000000.00000000.00000000 | /9 |
255.192.0.0 | 11111111.11000000.00000000.00000000 | /10 |
255.224.0.0 | 11111111.1110000.00000000.00000000 | /11 |
255.240.0.0 | 11111111.11110000.00000000.00000000 | /12 |
255.248.0.0 | 11111111.11111000.00000000.00000000 | /13 |
255.252.0.0 | 11111111.11111100.00000000.00000000 | /14 |
255.254.0.0 | 11111111.11111110.00000000.00000000 | /15 |
255.255.0.0 | 11111111.11111111.00000000.00000000 | /16 |
255.255.128.0 | 11111111.11111111.10000000.00000000 | /17 |
255.255.192.0 | 11111111.11111111.11000000.00000000 | /18 |
255.255.224.0 | 11111111.11111111.11100000.00000000 | /19 |
255.255.240.0 | 11111111.11111111.11110000.00000000 | /20 |
255.255.248.0 | 11111111.11111111.11111000.00000000 | /21 |
255.255.252.0 | 11111111.11111111.11111100.00000000 | /22 |
255.255.254.0 | 11111111.11111111.11111110.00000000 | /23 |
255.255.255.0 | 11111111.11111111.11111111.00000000 | /24 |
255.255.255.128 | 11111111.11111111.11111111.00000000 | /25 |
255.255.255.192 | 11111111.11111111.11111111.11000000 | /26 |
255.255.255.224 | 11111111.11111111.11111111.11100000 | /27 |
255.255.255.240 | 11111111.11111111.11111111.11110000 | /28 |
255.255.255.248 | 11111111.11111111.11111111.11111000 | /29 |
255.255.255.252 | 11111111.11111111.11111111.11111100 | /30 |
Host Address
The host address is a unique IP addresses which is assigned to hosts and devices. The host portion always contains various 0s and 1s but never all 0s or all 1s.
First Host Address
The first available host IP address in that network which has all 0s and end with a 1 in the host portion. It is also called first usable IP address.
Example
Dotted Decimal Notation | Binary | |
Network IP Address | 172.16.16.0/20 | 10101100.00010000.00010000.00000000 |
First Usable IP address | 172.16.16.1 | 10101100.00010000.00010000.00000001 |
Last Host Address
The last available host IP address in that network which has 1s and ends with a 0 in the host portion.It is also called last usable IP address.
Example
Dotted Decimal Notation | Binary | |
Network IP Address | 172.16.16.0 | 10101100.00010000.00010000.00000000 |
Last Usable IP Address | 172.16.31.254 | 10101100.00010000.00011111.11111110 |
Broadcast Address
This is a special address that communicates with all hosts in a network. For example, when a host sends a packet to the network broadcast address, all hosts in the network will receive the packet. The broadcast address uses the highest address in the network range. The broadcast address has all 1s in the host portion.
Example
Dotted Decimal Notation | Binary | |
Network IP Address | 172.16.16.0 | 10101100.00010000.00010000.00000000 |
Broadcast IP address | 172.16.31.255 | 10101100.00010000.00011111.11111111 |
No comments:
Post a Comment