IP Networking Part 3IP Address Management “A webinar to help you prepare for the CBNE™ Certification” Wayne M. Pecena, CPBE, CBNE Texas A&M Information Technology Educational Broadcast Services IP Networking, Part 3 - IP Address Management “A webinar to help you prepare for the CBNE™ Certification” Advertised Presentation Scope: IP Networking Fundamentals for Broadcast Engineers is an intensive instructorlead workshop focused on major IP networking topics. The goal is to equip the broadcast engineer with the knowledge and understanding of IP networking fundamentals and the ability to apply conceptual theory in a practical manner. The workshop will focus upon the principals of IP Addressing and application of best practices in the design of an IP network address plan. My Goals & Deliverables for This Afternoon: - Provide an Awareness of Major IP Networking Topics (broadcast application focused) Provide an Understanding of IP Addressing Fundamentals Provide a Foundation for SBE CBNT & CBNE Certification Exams Provide Reference Material & Resources to Obtain Further Knowledge 2 A Poll ? • My Familiarity & Conformability with IP Addressing is: Not at All Somewhat Familiar, But I Struggle At Times Very Comfortable, I Am Here for the Free Lunch 3 IP Networking, Part 3 - IP Address Management “A webinar to help you prepare for the CBNE™ Certification” • • • • • • IP Address Basics (IPv4) IP Addressing Rules IP Address Classes IP Subnetting Fundamentals The IPv6 Address Practical Exercises: – Reverse Engineering an IP Address Plan – Developing an IP Addressing Plan 4 REVIEW - Physical & Virtual Addressing • Each Host on an Ethernet Based IP Network Has: • An Unique MAC Address – Layer 2 Physical Address (local network segment) • An Unique IP Address – Layer 3 Logical Address (global routed) Simplified Representation FF:FF:FF:FF:FF:FF Destination MAC 00:12:3F:8D:4D:A7 Source MAC 172.15.1.1 172.15.2.2 Source IP Destination IP DATA Trailer IP Packet Ethernet Frame 5 The IP Address: • Is a “Logical Address” – OSI Model Layer 3 Function – Allows Hierarchical Network Addressing Structure • Creates Boundaries Between Networks – Allows Routing Packets Between Networks • Must Have a Subnet Mask: – Implied – Explicit • Address & Mask Defines: – Unique Network ID – Unique Host ID 6 The IP Address (IPv4) 32 Bit Address Yields 4,294,967,296 IPv4 Addresses Expressed in Decimal as (4) 8-bit Octets using “Doted Decimal Notation” 192.168.10.1 11000000.10101000.00001010.00000001 128 64 32 16 8 4 2 1 1 1 0 0 0 0 0 0 128 64 32 16 8 4 2 1 0 0 0 0 0 0 0 1 7 The IP Address Subnet Mask Each IP Address Must Have a Subnet Mask 32 Bit Subnet Mask Expressed in Decimal as (4) 8-bit Octets using “Doted Decimal Notation” 255.255.255.192 11111111.11111111.11111111.11000000 128 64 32 16 8 4 2 1 1 1 1 1 1 1 1 1 128 64 32 16 8 4 2 1 1 1 0 0 0 0 0 0 8 Purpose of the Subnet Mask • Identifies the Network Portion and the Host Portion of the IP Address – Classful Addressing – Mask is Implied Based Upon Class – Classless Addressing – Mask Must Be Specified Octet 1 Class A Class B Octet 2 Octet 4 NET ID HOST ID 8 Bits 24 Bits NET ID HOST ID 16 Bits 16 Bits Class C Octet 3 NET ID HOST ID 24 Bits 8 Bits 9 The Subnet Mask: • Rules: – If Mask Bit =1 – If Mask Bit=0 Identifies the Network Identifies the Host 192.168.10.1 255.255.255.192 11000000.10101000.00001010.00000001 Address 11111111.11111111.11111111.11000000 Mask Network Host Class Octet 1 Octet 2 Octet 3 Octet 4 A Network Host Host Host B Network Network Host Host C Network Network Network Host 10 IP Address Classes Used to Set Different Network Sizes • The 1st Octet of an IP Address Determines It’s Class: Class A First Octet Subnet Mask (implied) CIDR Maximum # of Networks # Host Bits # of Hosts / Network 1 - 127 255.0.0.0 /8 127 24 16,777,214 /16 16,384 16 65,534 2,097,152 8 254 B 128 - 191 255.255.0.0 C 192 - 223 255.255.255.0 /24 The 1st Octet of an IP Address Dictates the Class 11 The 1st Octet of an IP Address Determines It’s Class: • • • • • If First Bit = 0 If First 2 Bits = 10 If First 3 Bits – 110 If First 4 Bits = 1110 If First 4 Bits = 1111 Class A Class B Class C Class D Class E • Recognize Class D & E Are “Special”: – Class D – Class E Reserved for Multicast Reserved for Experimental 12 A Quiz! • What Class Are the Following IP Addresses? 169.254.0.100 127.10.0.10 Class A Class B Class C Class D Class A Class B Class C Class D 223.127.169.254 Class A Class B Class C Class E 13 The Network & Broadcast Addresses • These Addresses Cannot Be Assigned to a Host! – Network (subnet) Address • ALL HOST BITS = 0 – Broadcast Address • ALL HOST BITS = 1 • Network Example: • Broadcast Example: 00000000 192.168.1.0 /24 192.168.1.255 /24 11111111 14 Private vs Public IP Addresses • RFC 1918 Established “Private” Address Space – Class A: 10.0.0.0 to 10.255.255.255 – Class B: 172.16.0.0 to 172.31.255.255 – Class C: 192.168.0.0 to 192.168.255.255 /8 /16 /24 • Key Points: – Private IP Addresses Are NOT Routable Outside the Local Network or to the Internet – Widely Used in Home & Industry Networks – May Be Translated With NAT At An Edge Router • Map Private Address Space to Public Address Space 15 CIDR RFC 1517, 1518, 1519, 1520 • Classless Inter-Domain Routing (CIDR) – Simplified Approach to Stating the Subnet Mask – / Notation (slanted notation) Utilized = # Bits That Are 1 Mask: 255.255.255.240 Expressed in Binary: 11111111.11111111.11111111.11110000 24 Bits Mask (CIDR): /28 16 IP Address & Subnet Mask Formats Classful Addressing: 165.95.240.136 (Implied Mask 255.255.0.0) VLSM Addressing: 165.95.240.136 255.255.255.192 CIDR Notation : 165.95.240.136 /26 Implied Mask Of a Class B Network Explicit Mask Must Be Stated Mask Stated as Number of Subnet Bits 17 Special Use IP Addresses RFC 5735 • • • • • • • • 0.0.0.0/8 Network Address “Wire Address” 10.0.0.0/8 Private IP Address Space (RFC 1918) 127.0.0.0/8 Loopback Address 169.254.0.0/16 IETF Zero Configuration Address Space (RFC 3927) 172.16.0.0/16 Private IP Address Space (RFC 1918) 192.168.0.0/16 Private IP Address Space (RFC 1918) 224.0.0.0/4 Multicast Address Space 255.255.255.255/32 Broadcast Address And more special use cases………..yields a little over 3.7m “Useable IPv4 Addresses” (3,706,650,624 out of 4,294,967,296 possible IPv4 addresses or 86%) 18 IP Address Trivia • What is Special About 127.0.0.1 ? – Actually Any 127.0.0.0/8 Address Works OR the Range of 127.0.0.1 to 127.255.255.255 • Known as a “Loop-Back” Address • Useful For: – Test Local IP Stack and Network Adapter Test 19 IP Address Subnetting • What is a Subnet? – Logical Subdivision of a Larger Network – Creates New Networks From A Larger Network – Bits Are “Stolen” From the Host Portion • Each Newer Network Created Has Less Hosts • 2n-2 New Networks Created where n=number of host bits stolen • Why Do We Subnet? Efficient Use of IP Address Space (“Right Size” the Network) Increase Performance (smaller Broadcast domain) Enhance Routing Efficiency (reduce Routing Table size) Network Management Policy and Segmentation (function, ownership, geo location) – Job Security for Network Engineers! – – – – 20 Subnetting Simply Moves the Boundary between the Network and Host Moves Boundary to the Right Boundary Position Determined by the Subnet “Netmask” Provided IP Address Space: 200.25.0.0/16 Represents 4,096 IP Addresses Or 256 /24 Class “C” Blocks 200.25.31.0/24 200.25.30.0/24 Provided IP Address Space: 200.25.0.0/16 Represents 4,096 IP Addresses 200.25.16.0/24 16 200.25.17.0/24 1 200.25.30.0/23 2 15 D 200.25.18.0/24 200.25.29.0/24 3 14 200.25.28.0/23 13 4 12 5 C A 200.25.16.0/21 6 11 B 7 10 9 8 200.25.24.0/22 200.25.24.0/24 200.25.23.0/24 21 Subnetting Basics • Identifies the Boundary Between Network and Hosts • “Subnetting” Simply Moves the Boundary! – Moves Boundary to the Right – IP Address Subnetting Applies to All Classes – Boundary Position Determined by the Subnet “Netmask” • Expressed in Several Forms: – Doted Decimal Notation (same as IP address) – Slash Notation (also known as CIDR notation) IP Address 165.95.240.100 with Netmask of 255.255.255.0 OR 165.95.240.100 /24 22 Required Host IP Configuration Information • • • • IP Address Address Mask Gateway Address DNS Server Address(s) Where Do We Get This Information? 23 24 Network Questions to Answer • • • • • How Many Subnets Are Available? How May Hosts per Subnet Are Available? What Are the Subnets? What is the Broadcast Address of Each Subnet? What Are the Valid Hosts in Each Subnet? 25 What Must Be Known About a Network? IP Address and Mask Provides: First Network Address First Network Address Assignable to a Host Last Network Address Assignable to a Host Broadcast Address 192.168.1.0 /24 Provides: 254 useable IP addresses Mask: 255.255.255.0 Network Address (Wire Address) First Network Address Assignable to a Host Last Network Address Assignable to a Host Broadcast Address 192.168.1.0 192.168.1.1 192.168.1.254 192.168.1.255 26 Subnet Calculation Examples 192.168.1.0 /20 Provides: 4094 useable IP addresses Mask: 255.255.240.0 Network Address (Wire Address) 192.168.0.0 First Network Address Assignable to a Host 192.168.0.1 Last Network Address Assignable to a Host 192.168.15.254 Broadcast Address 192.168.15.255 192.168.1.0 /28 Provides: 14 useable IP addresses Mask: 255.255.255.240 Network Address (Wire Address) First Network Address Assignable to a Host Last Network Address Assignable to a Host Broadcast Address 192.168.1.0 192.168.1.1 192.168.1.14 192.168.1.15 27 An Exercise? • Is 204.56.198.31 mask 255.255.255.224 a Valid Host IP Address? Yes No It Depends 28 Lets See! 204.56.198.31 mask 255.255.255.224 1. Convert Mask to Binary – 255.255.255.224: 11111111.11111111.11111111.11100000 2. Convert Mask to Inverse Mask: subtract from all 1's 11111111.11111111.11111111.11111111 11111111.11111111.11111111.11100000 00000000.00000000.00000000.00011111 3. AND IP Address & Mask: 204.56.198.31 255.255.255.224 00100100.00111000.11000110.00001111 11111111.11111111.11111111.11100000 00100100.00111000.11000110.00000000 Yields the Network Address: 204.56.198.0 4. OR Inverse Mask to Network Address: 00100100.00111000.11000110.00000000 00000000.00000000.00000000.00011111 00100100.00111000.11000110.00011111 Yields the Broadcast Address: 204.56.198.31 5. Thus: Network: 1st Host: Last Host: Broadcast: 204.56.198.0 204.56.198.1 204.56.198.30 204.56.198.31 The Answer Is NO 204.56.198.31 is Not a Valid Host Address (It’s the Broadcast Address) 29 IPv6 Address Space IETF - RFC 2460 IPv6 Provides Expanded IP Address Space 2128 = 340,282,366,920,938,463,463,374,607,431,768,211,456 (three hundred forty UNDECILLION addresses) 3.4 x 1038 • But, IPv6 is More Than Expanded Address Space: – An Opportunity to Re-Engineer IPv4 • • • • • • Improved Support for Multicasting, Security, & Mobile Aps Multiple Addresses per Interface Host Auto-Configuration Capability Security Incorporated MTU Discovery Incorporated Traffic Engineering Provisions Incorporate The IPv6 Address 128-Bit Address Binary Format: 001001100000011110111000000000001111101010100000000000110010000110010101100110001000011110111100010010000010100011110001 Subdivide Into Eight (8) 16-bit Groups: 0010011000000111 1011100000000000 0000111110101010 0000000000000011 0010000110010101 1001100010000111 1011110001001000 0010100011110001 Convert Each 16-bit Group to Hexadecimal: (separate with a colon) 2607:b800:0faa:0003:2195:9887:bc48:28f1 2607:b800:faa:3:2195:9887:bc48:28f1 Address Summarization 128-Bit Address Represented as a 32 Hexadecimal Digits Subdivided Into Eight Groups (Chunks, Quads, Quartets) of Four Hexadecimal Digits (separated by colon) 2001:0000:0000:0000:0DB8:8000:200C:417A or 2001:0:0:0:DB8:8000:200C:417A or 2001::DB8:8000:200C:417A Address Summarization 128-Bit Address Represented as a 32 Hexadecimal Digits Subdivided Into Eight Groups (Chunks, Quads, Quartets) of Four Hexadecimal Digits (separated by colon) 2001:0000:0000:0000:0DB8:8000:200C:417A or 2001:0:0:0:DB8:8000:200C:417A or 2001::DB8:8000:200C:417A 33 33 An Ipv6 Address You Can Remember The IPv6 Loopback Address ::1 Summarized from: 0:0:0:0:0:0:0:1 IP Addressing Reverse Engineering “A Useful Troubleshooting Tool” • Verifying Proper Subnet Configuration When Given an IP Address and Subnet Mask – Determine Subnet Address Range – Determine “Assignable” IP Addresses – Determine Broadcast Address • Subnetting When Given A Network Requirement • Subnetting When Given A Host Requirement You Are Provided: IP Address / IP Mask 35 IP Address Subnetting Charts 36 Subnet Calculation Tools 37 Hints for Subnetting VLSM Mask 128 192 224 240 248 252 254 255 128 64 32 16 8 4 2 1 /25 /26 /27 /28 /29 /30 /31 /32 CIDR 4th Octect OR AND Remember George Boole Block Size 0 0 0 0 0 0 0 1 0 0 1 1 1 0 0 1 0 1 1 1 1 1 1 1 38 Practical Exercise Reverse Engineering an IP Address Plan Refer to Exercise Handout 39 40 Practical Exercise #2 Developing an IP Addressing Plan Refer to Exercise Handout 41 64 32 32 42 Subnet Number: Subnet Mask: 192.168.100.0 255.255.255.192 First IP Address: 192.168.100.1 Broadcast IP Address: 192.168.100.63 Last IP Address: 192.168.100.62 Subnet Number: 192.168.100.64 Subnet Mask: 255.255.255.224 First IP Address: 192.168.100.65 Broadcast IP Address: 192.168.100.95 Last IP Address: 192.168.100.94 Subnet Number: 192.168.100.96 Subnet Mask: 255.255.255.224 First IP Address: 192.168.100.97 Broadcast IP Address: 192.168.100.127 Last IP Address: 192.168.100.126 What additional IP configuration information is required to configure hosts on this network? Default Gateway 43 The Calculator Approach! 44 45 Web Reference Sources: • Subnet Calculation Tools: www.subnet-calculator.com www.solarwinds.com/products/freetools/free_subnet_calculator.aspx http://www.pkostov.com/wordpress/?p=66 iOS App $: https://itunes.apple.com/us/app/mask-ipv4-ipv6calculator/id329508400?mt=8 • RFC Documents: www.rfc-editor.org • IP Address Subnet Block Size Chart: http://img.docstoccdn.com/thumb/orig/14990233.png 46 Web Reference Sources continued……. • IP Subnetting – Cisco Networkers “Magic Box” Tutorial: https://learningnetwork.cisco.com/docs/DOC-5893 – Cisco IP Subnetting Game: https://learningnetwork.cisco.com/docs/DOC-1802 47 CBNE Recommended Study: 48 My Favorites: 49 ? Questions ? Thank You for Attending! Wayne M. Pecena Texas A&M University w-pecena@tamu.edu 979.845.5662 50