INTRODUCTION Network Layer is the third layer in the seven layer OSI model It provides logical addressing and routing The protocols in this layer are IPv4/IPv6,IPx,OSPF,RIP,ICMP IP is a communication protocol for relaying datagrams across networks IP transfers packets from source to destination based on IP address by adding header
INTRODUCTION CONT.... IP address is used for host/network interface identification and location addressing IP has two versions – IPv4, IPv6 IPv4 address is divided into five classes based on priority bit(s), they are 1 Class A 2 Class B 3 Class C 4 Class D 5 Class E
IP Addressing ClassIP RangeConfigurationUses A0-126N.H.H.H For government and large corporations B N.N.H.H Large and medium sized companies C N.N.N.H Other than Class A and Class B addresses D Multicast addressing E Research, testing and experimentation
8/6/15 Subnetting Subnetting requires a three step procedure: Determine the number of host bits to be used for the subnetting. Subnetting a Class B Network ID Required Number of Subnets Number of Subnet Bits Subnet MaskNumber of Hosts per Subnet or /98,388, or /14262,142 2,097,153-4,194, or /302
8/6/15 Enumerate the new subnetted network Ids. Based on the number of host bits we need for our subnetting, we list the new subnetted network IDs. There are two main approaches: Binary: Binary Subnetting Technique for Network ID / /19 Decimal: Decimal Subnetting Technique for Network ID /19 Enumerate the IP addresses for each new subnetted network ID. Based on the enumeration of the subnetted network IDs, we must list the valid IP addresses for new subnetted network IDs. There are two main approaches: Binary: the range of IP addresses for the 3 bit subnetting of is its ip range Decimal: – its ip range
8/6/15 Subnet Masks With the advent of subnetting, one can no longer rely on the definition of the IP address classes to determine the network ID in the IP address. A new value is needed to define which part of the IP address is the network ID and which part is the host ID regardless of whether class-based or subnetted network IDs are being used. RFC 950 defines the use of a subnet mask (also referred to as an address mask) as a 32-bit value that is used to distinguish the network ID from the host ID in an arbitrary IP address. The bits of the subnet mask are defined as follows: All bits that correspond to the network ID are set to 1. All bits that correspond to the host ID are set to 0. Address ClassBits for Subnet MaskNetwork Prefix Class A /8 Class B /16 Class C /24
Subnetting Example Host IP address: Network Mask: (or by /16) Subnet Mask: Major network Address: Major network broadcast Address: Total range of hosts if not subnetted: Step1: Convert the ip address and mask to binary Ip address: Mask : Step2: Finding the subnet address Simply performing bitwise and of ip address with its subnet mask: Ip address: Mask : Network : The network address is:
Subnetting Example contd Finding the subnet range/ host range Ip address: Mask : Network : using the network mask divide the subnet from the remaining address using the subnet mask divide the subnet from the hosts such that the hosts are chosen from last 1 and first 0 in the subnet mask. So the total number of subnet: 2^8=256 Subtract 2 if all 1's and all 0's cannot be used The total number of hosts=2^8-2=254 per subnet Subtraction of 2 because of the subnet address and broadcast address. SD GD subnet counting range Host counting range