1 / 69

Understanding IP Addressing and Subnetting: A Comprehensive Guide

Learn about IP address structure, classes, reserved and private addresses, subnetting, network masks, and broadcast addresses. Suitable for both beginners and advanced users.

beebej
Télécharger la présentation

Understanding IP Addressing and Subnetting: A Comprehensive Guide

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 4-2 IP address

  2. Chapter 4: Network Layer 4. 1 Introduction 4.2 Virtual circuit and datagram networks 4.3 What’s inside a router 4.4 IP: Internet Protocol Datagram format IPv4 addressing ICMP IPv6 4.5 Routing algorithms Link state Distance Vector Hierarchical routing 4.6 Routing in the Internet RIP OSPF BGP 4.7 Broadcast and multicast routing IP address

  3. The Internet Network layer Host, router network layer functions: • ICMP protocol • error reporting • router “signaling” • IP protocol • addressing conventions • datagram format • packet handling conventions • Routing protocols • path selection • RIP, OSPF, BGP forwarding table Transport layer: TCP, UDP Network layer Link layer physical layer IP address Computer network-Link Layer and LANs

  4. Objectives • Concept of IP Address • Class of IP Address • Reserved and Private IP Address • Network Mask and Subnetting • VLSM and CIDR IP address

  5. IP Address • Each computer in a TCP/IP network must be given a unique identifier, or IP address. An IP address is a 32-bit sequence of 1s and 0s. IP address

  6. Representation of IP Address • To make the IP address easier to use, the address is usually written as four decimal numbers separated by periods 192 . 168 . 123 . 2 IP address

  7. Structure of IP Address IP address

  8. IP地址的类别(Class of IP Address) IP address

  9. Class A • Address Range:1-126(127 Reserved) IP address

  10. Class B • Address Range:128-191 IP address

  11. Class C • Address Range:192-223 IP address

  12. Address Allocating • Allocate A class IP:(国际网络信息中心NIC) • Allocate B class IP :InterNIC、APNIC、ENIC • Allocate C class IP (国家或地区的NIC) IP address

  13. Reserved Address • Certain host addresses are reserved and cannot be assigned to • devices on a network. • An IP address that has binary 0s in all host bit positions is reserved • for the network address. • An IP address that has binary 1s in all host bit positions is reserved • for the broadcast address. • 0.0.0.0 • An IP address that has binary 0s in all bit positions is reserved for default • route • 255.255.255.255, • An IP address that has binary 1s in all bit positions is reserved for flood broadcast IP address

  14. Private IP Address • Private IP addresses are another solution to the problem of the impending exhaustion of public IP addresses. • Private IP addresses are not routed on the Internet backbone. IP address

  15. Exercise: IP Address Classes Address Class Network Host 10.2.1.1 128.63.2.100 201.222.5.64 192.6.141.2 130.113.64.16 256.241.201.10 IP address

  16. IP Address Classes Exercise Answers Address Class Network Host 10.2.1.1 A 10.0.0.0 0.2.1.1 128.63.2.100 B 128.63.0.0 0.0.2.100 201.222.5.64 C 201.222.5.0 0.0.0.64 192.6.141.2 C 192.6.141.0 0.0.0.2 130.113.64.16 B 130.113.0.0 0.0.64.16 256.241.201.10 Nonexistent IP address

  17. Network Mask Class A:255.0.0.0 classB:255.255.0.0 class C:255.255.255.0 IP address

  18. 10101100 00010000 00000010 10100000 172.16.2.160  11111111 11111111 00000000 00000000 255.255.0.0 10101100 00010000 00000000 00000000 172.16.0.0 Function of Network Mask Network ID IP address

  19. Subnetting • To efficiently manage a limited supply of IP addresses, all classes can be subdivided into smaller subnetworks. IP address

  20. Reasons for Subnetting • Provides addressing flexibility Provides • Broadcast Containment • Low-level security on the LAN IP address

  21. Introduction to Subnetting • Host bits must are reassigned (or “borrowed”) as network bits. 3 bits borrowed allows 23-2 or 6 subnets 5 bits borrowed allows 25-2 or 30 subnets IP address 12 bits borrowed allows 212-2 or 4094 subnets

  22. Introduction toSubnetting 不考虑子网 Net id Host id Net mask Net id Host id 考虑子网化 Net mask Net id Subnet id Host id Extended net id IP address

  23. Comparison between decimal and binary IP address

  24. E.g1 Two BitsSubnetting for Class C • Subnetrange • 00 000000 0 00000001~00111111 1~62 • 01 000000 64 01000001~01111111 65~127 • 10 000000 128 10000001~10111111 129~191 • 11 000000 192 11000001~11111111 193~255 IP address

  25. Number of Usable Subnets and Hosts • usable subnets= • (2 power of borrowed bits)–2 • usable hosts= • (2 power of remaining host bits)–2 IP address

  26. Summary of Class C Subnetting IP address

  27. Written Exercise: Subnet Masks Address Subnet Mask Class Subnet 172.16.2.10 255.255.255.0 10.6.24.20 255.255.0.0 172.30.36.12 255.255.255.0 202.30.36.82 255.255.255.192 IP address

  28. Subnet Mask Exercise Answers Address Subnet Mask Class Subnet 172.16.2.10 255.255.255.0 B 172.16.2.0 10.6.24.20 255.255.240.0 A 10.6.16.0 10.30.36.12 255.255.255.0 A 10.30.36.0 IP address

  29. Broadcast Addresses Broadcast Subnet Subnet Mask Class Address 201.222.10.60 255.255.255.248 15.16.193.6 255.255.248.0 128.16.32.13 255.255.255.252 153.50.6.27 255.255.255.128 IP address

  30. Broadcast Addresses Exercise Answers Address Subnet Mask Class Subnet Broadcast 201.222.10.60 255.255.255.248 C 201.222.10.56 201.222.10.63 15.16.193.6 255.255.248.0 A 15.16.192.0 15.16.199.255 128.16.32.13 255.255.255.252 B 128.16.32.12 128.16.32.15 153.50.6.27 255.255.255.128 B 153.50.6.0 153.50.6.127 IP address

  31. Subnets IP address: subnet part (high order bits) host part (low order bits) What’s a subnet ? device interfaces with same subnet part of IP address can physically reach each other without intervening router 223.1.1.1 223.1.2.1 223.1.1.2 223.1.2.9 223.1.1.4 223.1.2.2 223.1.1.3 223.1.3.27 subnet 223.1.3.2 223.1.3.1 network consisting of 3 subnets IP address

  32. Subnets Recipe To determine the subnets, detach each interface from its host or router, creating islands of isolated networks. Each isolated network is called a subnet. 223.1.1.0/24 223.1.2.0/24 223.1.3.0/24 Subnet mask: /24 IP address

  33. Subnets How many? 223.1.1.2 223.1.1.1 223.1.1.4 223.1.1.3 223.1.7.0 223.1.9.2 223.1.9.1 223.1.7.1 223.1.8.1 223.1.8.0 223.1.2.6 223.1.3.27 223.1.2.1 223.1.2.2 223.1.3.1 223.1.3.2 IP address

  34. IP addressing: CIDR CIDR:Classless InterDomain Routing subnet portion of address of arbitrary length address format: a.b.c.d/x, where x is # bits in subnet portion of address host part subnet part 11001000 0001011100010000 00000000 200.23.16.0/23 IP address

  35. 30 hosts per subnet Class C address: 201.222.5.0 Other subnets Subnet Programming IP address

  36. Variable-Length Subnet Mask 172.16.0.0/16 HQ IP address

  37. Variable-Length Subnet Mask 172.16.1.0/24 172.16.0.0/16 HQ HQ 172.16.2.0/24 IP address

  38. Variable-Length Subnet Mask 172.16.14.32/27 A 172.16.1.0/24 172.16.14. 64/27 B 172.16.0.0/16 HQ HQ 172.16.2.0/24 172.16.14.96/27 C • Subnet 172.16.14.0/24 is divided into smaller subnets: • Subnet with one mask at first (/27) IP address

  39. Variable-Length Subnet Mask 172.16.14.32/27 172.16.14.132/30 A 172.16.1.0/24 172.16.14. 64/27 172.16.14.136/30 B 172.16.0.0/16 • Subnet with one mask at first (/27) • Further subnet one of these subnets not used elsewhere (/30) HQ HQ 172.16.14.96/27 172.16.2.0/24 C 172.16.14.140/30 IP address

  40. Calculating VLSMs Subnetted Address: 172.16.32.0/20In Binary 10101100. 00010000.00100000.00000000 IP address

  41. Calculating VLSMs Subnetted Address: 172.16.32.0/20In Binary 10101100. 00010000.00100000.00000000 VLSM Address: 172.16.32.0/26In Binary 10101100. 00010000.00100000.00000000 IP address

  42. Calculating VLSMs Subnetted Address: 172.16.32.0/20In Binary 10101100. 00010000.00100000.00000000 VLSM Address: 172.16.32.0/26In Binary 10101100. 00010000.00100000.00000000 1 0 1 0 1 1 0 0 . 0 0 0 1 0 0 0 0 . 0 0 1 0 0 0 0 0 . 0 0 0 0 0 0 0 0 = 172.16.32.0/26 1st subnet: Network Subnet VLSM subnet Host IP address

  43. Calculating VLSMs Subnetted Address: 172.16.32.0/20In Binary 10101100. 00010000.00100000.00000000 VLSM Address: 172.16.32.0/26In Binary 10101100. 00010000.00100000.00000000 1st subnet: 1 0 1 0 1 1 0 0 . 0 0 0 1 0 0 0 0 . 0 0 1 0 0 0 0 0 . 0 0 0 0 0 0 0 0 = 172.16.32.0/26 2nd subnet: 1 7 2 . 16 . 0 0 1 0 0 0 0 0 . 0 1 0 0 0 0 0 0 = 172.16.32.64/26 3rd subnet: 1 7 2 . 16 . 0 0 1 0 0 0 0 0 . 1 0 0 0 0 0 0 0 = 172.16.32.128/26 1 7 2 . 16 . 0 0 1 0 0 0 0 0 . 1 0 0 0 0 0 0 = 172.16.32.192/26 4th subnet: 1 1 7 2 . 16 . 0 0 1 0 0 0 0 1 . 0 0 0 0 0 0 0 0 = 172.16.33.0/26 5th subnet: Network Subnet VLSM Subnet Host IP address

  44. Derived from the 172.16.32.0/20 Subnet Exercise:Design Network Using VLSM (62 Hosts) (62 Hosts) (62 Hosts) (62 Hosts) IP address

  45. Derived from the 172.16.33.0/26 Subnet Derived from the 172.16.32.0/20 Subnet Exercise Answer 172.16.32.0/26 172.16.33.0/30 172.16.32.64/26 172.16.33.4/30 172.16.33.8/30 172.16.32.128/26 172.16.33.12/30 172.16.32.192/26 30-Bit Mask (2 Hosts) 26-Bit Mask (62 Hosts) IP address

  46. Again IP address

  47. Net-id and host-id 0 A class net-id 8 bit host-id 24 bit 1 0 B class net-id 16 bit host-id 16 bit C class 1 1 0 net-id 24 bit host-id 8 bit 1110 D class Multicast address 11110 E class reserved IP address

  48. range Class network No.s from to hostnumber A 126 (27 – 2) 1 126 16,777,214 B 16,384 (214)-2 128.0 191.255 65,534 C 2,097,152 (221)-2 192.0.0 223.255.255 254 IP address

  49. Five classes IP address 1/2 6 1/4 1/8 1/16 1/32 IP address IP地址与网络层

  50. Some special IP address IP address

More Related