1 Chapter Overview Subnet
What is a subnet When you break a network into a few smaller networks, you have created several subnets Like IP address where we have network addresses and host IDs, we now have subnet addresses and host IDs 2
3 What Is a Subnet Mask? A subnet mask is a 32-bit binary number that indicates which bits of an IP address identify the network and which bits identify the host. The 1 bits are the network identifier bits and the 0 bits are the host identifier bits. A subnet mask is typically expressed in dotted decimal notation.
4 Subnet Masks for IP Address Classes ClassSubnet Mask A B C
5 Creating Subnets Borrow bits from the host identifier and use them as a subnet identifier. Convert the binary values to decimals.
6 Subnetting a Class B Address
Classless Inter-Domain Routing (CIDR) (CIDR) is an Internet Protocol (IP) address allocation and route aggregation methodology used within the Internet addressing architecture that replaced the IPv4 classful network organization of the IP address space. 7
CIDR notation In the CIDR notation, the IP address is expressed according to the standards of IPv4 or IPv6, followed by the separator character which is a slash (/), followed by the prefix size as a decimal number. the address specification /24 represents the given IPv4 address and its associated routing prefix or, equivalently, its subnet mask, IPv4 8
CIDR notation (2) You cannot have /31 because the hosts need to have at least two bits 9
The five key questions of a subnet mask How many subnets does a subnet mask produce? Number of valid hosts per subnet What are the valid subnets What are the broadcast address of each subnet What are the valid hosts in a subnebt 10
How many subnets 2 x where x is the number of 1s in the subnet mask after the 1s for the traditional class (8 for A, 16 for B, and 24 for C) For example, the subnet mask would have 2 2 =4 subnet for a class C network. 11
Number of valid hosts per subnet 2 y -2, where y is the number of zeros in a subnet mask, is the number of hosts The -2 are for all 0s and all 1s. For , the number of hosts are = 62 12
What are the valid subnets For on a class C network they are 0, ( to ) 64, ( to ) 128, ( to ) and 192, ( to ) 13
What are the broadcast address For they are 0
What are the valid hosts For they are 0, ( to ) 64, ( to ) 128, ( to ) and 192, ( to ) 15
Example #1C (Page 219) On mask of /25 # of subnet 2 Hosts in each subnet 126 The two subnets are 0 and 128, which broadcast address be 127 and 255 respectively Valid host addresses 16
Assigning IP addresses Note, this ~ are class C private IP addresses 17
Troubleshooting 1. Ping (or ::1) If cannot connect, host problems NIC, TCP/IP, subnet mask, etc Ping IP address of the host If works, NIC is working Ping the default gateway If works, connected to LAN If not, most likely physical layer issues Ping server If working, the server is working, so is IP If not, server could be down, or others 18
What’s wrong here (pp. 237) 19 It is a broadcast address
Tools Ping (Packet Internet groper) Traceroute/tracert Arp –a Ipconfig 20
Network Address Translation (NAT) Access the Internet with private IP address Change ISP without renumbering computer’s IP addresses Merge two networks with some duplicated IP addresses 21
NAT where? 22
Good and bad 23
Three types of translations Static – allow one to one mapping of local and global address, use to hide internal addresses Dynamic – doing the same as Static, just need a pool of real IP addresses Overloading – most interesting, used by home Internet routers – using ports 24
Example of overloading 25