Chapter 2 Easy Subnetting Instructor: Mr. Malik Zaib Alam
Chapter 3 Objectives The CCENT Topics Covered in this chapter include: IP addressing (IPv4 / IPv6) Describe the operation and necessity of using private and public IP addresses for IPv4 addressing 2
Subnetting To break up a giant network into a bunch of smaller ones is called subnetting. Creating subnetworks is essentially the act of taking bits from the host portion of the address and reserving them to define the subnet address instead. It will result in fewer bits being available for defining your hosts. To create a subnet, fulfil these three steps: 1. Determine the number of required network IDs: - One for each LAN subnet -One for each wide area network connection 2. Determine the number of required host IDs per subnet: -One for each TCP/IP host -One for each router interface 3. Based on the above requirements, create the following: - A unique subnet mask for your entire network -A unique subnet ID for each physical segment -A range of host IDs for each subnet
Subnet Masks A subnet mask is a 32-bit value that allows the device that’s receiving IP packets to distinguish the network ID portion from the host ID portion of the IP address. This 32-bit subnet mask is composed of 1s and 0s, where the 1s represent the positions that refer to the network subnet addresses.
Power of 2
Decimal values in a mask and their binary equivalents 00000000 128 10000000 192 11000000 224 11100000 240 11110000 248 11111000 252 11111100 254 11111110 255 11111111
Classless Inter-Domain Routing (CIDR) It’s basically the method that Internet service providers (ISPs) use to allocate a number of addresses to a companies. It uses the slash notation that represents the number of 1s in the subnet mask. 192.168.10.32/28. This is telling you what your subnet mask is. The slash notation (/) means how many bits are turned on (1s). Subnet Mask CIDR representation 255.0.0.0 /8 255.255.0.0 /16 255.255.128.0 /17 255.255.192.0 /18 255.255.224.0 /19 255.255.240.0 /20 255.255.248.0 /21 255.255.252.0 /22 255.255.254.0 /23 255.255.255.0 /24
Subnetting Class C Addresses In a Class C address, only 8 bits are available for defining the hosts. Remember that subnet bits start at the left and move to the right, without skipping bits. This means that the only Class C subnet masks can be the following: Binary Decimal CIDR 00000000= 0 /24 10000000= 128 /25 11000000= 192 /26 11100000= 224 /27 11110000= 240 /28 11111000= 248 /29 11111100= 252 /30
Subnetting Formulas How many subnets? 2x = number of subnets. x is the number of masked bits. How many hosts per subnet? 2y – 2 = number of hosts per subnet. y is the number of unmasked bits, or the 0s. What are the valid subnets? 256 – subnet mask = block size, or increment number.
Subnetting class C address 1. Address: 192.168.10.0/25 Subnet Mask: 255.255.255.128 No. Of subnets= , Here n is bits for subnetting which is 1, = 2 No of hosts= -2= 128-2= 126 Block Size= 256-128= 128, Subnets: 0,128 No. Network Address First IP Last IP Broadcast 1. 192.168.10.0 192.168.10.1 192.168.10.126 192.168.10.127 2. 192.168.10.128 192.168.10.129 192.168.10.254 192.168.10.255
Subnetting class C address Address: 192.168.10.0/28 Subnet Mask: 255.255.255.240 No. Of subnets= =16 , Bits taken for subnetting = 4 No of hosts= -2= 16-2= 14, Host bits=4 Block Size= 256-240=16 Subnets: 0, 16, 32, 48, 64, 80, 96, … No. Network Address First IP Last IP Broadcast 1. 192.168.10.0 192.168.10.1 192.168.10.14 192.168.10.15 2. 192.168.10.16 192.168.10.17 192.168.10.30 192.168.10.31 3. 192.168.10.32 192.168.10.33 192.168.10.46 192.168.10.47
Subnetting class C address Address: 192.168.10.0/29 Subnet Mask: 255.255.255.248 No. Of subnets= =32 , Bits taken for subnetting = 5 No of hosts= -2= 8-2= 6, Host bits=3 Block Size= 256-248=8 Subnets: 0, 8,16,24, 32, 40, 48, … No. Network Address First IP Last IP Broadcast 1. 192.168.10.0 192.168.10.1 192.168.10.6 192.168.10.7 2. 192.168.10.8 192.168.10.9 192.168.10.14 192.168.10.15 3. 192.168.10.16 192.168.10.17 192.168.10.22 192.168.10.23
Subnetting class C address Address: 192.168.10.0/30 Subnet Mask: 255.255.255.252 No. Of subnets= =64 , Bits taken for subnetting = 6 No of hosts= -2= 4-2= 2, Host bits=2 Block Size= 256-252=4 Subnets: 0, 4, 8, 12, 16, 20, 24, 28, 32, 36, 40,…..… No. Network Address First IP Last IP Broadcast 1. 192.168.10.0 192.168.10.1 192.168.10.2 192.168.10.3 2. 192.168.10.4 192.168.10.5 192.168.10.6 192.168.10.7 3. 192.168.10.8 192.168.10.9 192.168.10.10 192.168.10.11
Subnetting Practice class B Address: 172.16.0.0/17 Subnet Mask: 255.255.128.0 No. Of subnets= =2 , Here n=1 , No of hosts= -2= 32,766 (7+8bits) Block Size= 256-128= 128 Subnets: 0.0, 128.0 No. Network Address First IP Last IP Broadcast 1. 172.16.0.0 172.16.0.1 172.16.127.254 172.16.127.255 2. 172.16.128.0 172.16.128.1 172.16.255.254 172.16.255.255 3.
Subnetting Practice class B Address: 172.16.0.0/19 Subnet Mask: 255.255.224.0 No. Of subnets= =8 , Here n=3 , No of hosts= -2= 8192-2= 8,190 (5+8bits) Block Size= 256-224=32 Subnets: 0.0, 32.0,64.0,96.0, 128.0, 160.0,192.0,224.0 No. Network Address First IP Last IP Broadcast 1. 172.16.0.0 172.16.0.1 172.16.31.254 172.16.31.255 2. 172.16.32.0 172.16.32.1 172.16.63.254 172.16.63.255 3. 172.16.64.0 172.16.64.1 172.16.95.254 172.16.95.255
Subnetting Practice class B Address: 172.16.0.0/24 Subnet Mask: 255.255.255.0 No. Of subnets= =256 , Here n=8 , No of hosts= -2= 256-2= 254 (8bits) Block Size= 256-255=1 Subnets: 0.0, 1.0,2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0, ………… No. Network Address First IP Last IP Broadcast 1. 172.16.0.0 172.16.0.1 172.16.0.254 172.16.0.255 2. 172.16.1.0 172.16.1.1 172.16.1.254 172.16.1.255 3. 172.16.2.0 172.16.2.1 172.16.2.254 172.16.2.255
Subnetting Practice class B Address: 172.16.0.0/28 Subnet Mask: 255.255.255.240 No. Of subnets= =4096 , Here n=12 , No of hosts= -2= 16-2= 14 (4bits) Block Size= 256-240=16 Subnets: 0.0, 0.16,0.32,0.48,0.64,0.80,0.96 ………… No. Network Address First IP Last IP Broadcast 1. 172.16.0.0 172.16.0.1 172.16.0.14 172.16.0.15 2. 172.16.0.16 172.16.0.17 172.16.0.30 172.16.0.31 3. 172.16.0.32 172.16.0.33 172.16.0.46 172.16.0.47
Subnetting Practice class B Address: 172.16.0.0/30 Subnet Mask: 255.255.255.252 No. Of subnets= =16384 , Here n=14 , No of hosts= -2= 4-2= 2 (2bits) Block Size= 256-252=4 Subnets: 0.0, 0.4, 0.8, 0.12, 0.16, 0.20, 0.24, ………… No. Network Address First IP Last IP Broadcast 1. 172.16.0.0 172.16.0.1 172.16.0.2 172.16.0.3 2. 172.16.0.4 172.16.0.5 172.16.0.6 172.16.0.7 3. 172.16.0.8 172.16.0.9 172.16.0.10 172.16.0.11
Subnetting Practice class A Address: 10.0.0.0/10 Subnet Mask: 255.192.0.0 No. Of subnets= =4 , Here n=2 , No of hosts= -2= 4,194,304 (6+8+8bits) Block Size= 256-192= 64 Subnets: 0.0.0, 64.0.0,128.0.0,192.0.0,……… No. Network Address First IP Last IP Broadcast 1. 10.0.0.0 10.0.0.1 10.63.255.254 10.63.255.255 2. 10.64.0.0 10.64.0.1 10.127.255.254 10.127.255.255 3. 10.128.0.0 10.128.0.1 10.191.255.254 10.191.255.255
Subnetting Practice class A Address: 10.0.0.0/16 Subnet Mask: 255.255.0.0 No. Of subnets= =256 , Here n=8 , No of hosts= -2= 65536-2= 65,534(8+8bits) Block Size= 256-255= 1 (2nd Octet) Subnets: 0.0.0, 1.0.0,2.0.0, 3.0.0, 4.0.0, ……… No. Network Address First IP Last IP Broadcast 1. 10.0.0.0 10.0.0.1 10.0.255.254 10.0.255.255 2. 10.1.0.0 10.1.0.1 10.1.255.254 10.1.255.255 3. 10.2.0.0 10.2.0.1 10.2.255.254 10.2.255.255
Subnetting Practice class A Address: 10.0.0.0/24 Subnet Mask: 255.255.255.0 No. Of subnets= =65,536, Here n=16 , No of hosts= -2= 256-2=254 (8bits) Block Size= 256-255= 1 (3rd Octet) Subnets: 0.0.0, 0.1.0, 0.2.0, 0.3.0, 0.4.0,…… No. Network Address First IP Last IP Broadcast 1. 10.0.0.0 10.0.0.1 10.0.0.254 10.0.0.255 2. 10.0.1.0 10.0.1.1 10.0.1.254 10.0.1.255 3. 10.0.2.0 10.0.2.1 10.0.2.255
Subnetting Practice class A Address: 10.0.0.0/30 Subnet Mask: 255.255.255.252 No. Of subnets= = 4,194,304 Here n=22, No of hosts= -2= 4-2=2 (2 bits) Block Size= 256-252= 4 (4th Octet) Subnets: 0.0.0, 0.0.4, 0.0.8, 0.0.12, 0.0.16,…… No. Network Address First IP Last IP Broadcast 1. 10.0.0.0 10.0.0.1 10.0.0.2 10.0.0.3 2. 10.0.0.4 10.0.0.5 10.0.0.6 10.0.0.7 3. 10.0.0.8 10.0.0.9 10.0.0.10 10.0.0.11