Page 169 - Computer_Science_F5
P. 169
Computer Science (d) Examples of subnetting
Example 3.1:
Imagine a ZCB group of companies Ltd have an IP address of 192.168.1.0/24
according to information from its IT department. The company needs to create
FOR ONLINE READING ONLY
four (4) subnets. As an IT Manager, perform this task.
Step 1: Determine the subnet mask
(i) The original default network mask is 255.255.255.0 (/24), which allows for
256 IP addresses (2^8).
(ii) To create four subnets, you need to borrow 2 bits from the Host ID part.
(iii) To calculate the number of subnets, use the formula, number of subnets=2
n
, where n is the borrowed bits. In this case, n=2, therefore 2 = 4 subnets.
2
(iv) Change the borrowed 2 bits from bit 0 to bit 1 in the host portion (add them
to the network ID portion of the mask). This is to say, the default mask for
class C 11111111 1111111 11111111 00000000 will now be come 11111111
1111111 11111111 11000000
(v) The resulting subnet mask is now 255.255.255.192 (/26).
(vi) From the remaining zeros of the subnet mask, calculate the number of
addresses per each subnet as allowed (2 ,where n is the number of zeros in
n
the host ID part of the subnet mask).
(vii) Taking the remaining 6 zeros in the host ID portion of the mask (2 ), which
6
allows for 64 IP addresses per subnet.
Step 2: Calculate subnet addresses
Each subnet has 64 address ranges, the granted address will be the first address
then add 63 to find the last address in each case. Remember the first address is the
subnet address and the last address is the broadcast address.
(i) Subnet 1: 192.168.1.0/26 (Range: 192.168.1.0 - 192.168.1.63)
(ii) Subnet 2: 192.168.1.64/26 (Range: 192.168.1.64 - 192.168.1.127)
(iii) Subnet 3: 192.168.1.128/26 (Range: 192.168.1.128 - 192.168.1.191)
(iv) Subnet 4: 192.168.1.192/26 (Range: 192.168.1.192 - 192.168.1.255)
Step 3: Assign addresses
Each subnet can accommodate up to 62 hosts (64 total addresses minus 2 for
network and broadcast addresses).
160
for Advanced Secondary Schools
Computer Science Form 5.indd 160 23/07/2024 12:33