Efficient Addressing. Outline. Addressing Subnetting Supernetting CS 640 1

Similar documents
Internetworking and Internet-1. Global Addresses

Dynamic Host Configuration Protocol (DHCP) 02 NAT and DHCP Tópicos Avançados de Redes

HOST AUTO CONFIGURATION (BOOTP, DHCP)

Internet Control Protocols Reading: Chapter 3

Scaling the Network: Subnetting and Other Protocols. Networking CS 3470, Section 1

COMP 631: COMPUTER NETWORKS. IP Addressing. Jasleen Kaur. Fall How to Deal With Heterogeneity & Scale?

Internetworking. Problem: There is more than one network (heterogeneity & scale)

Application Protocols for TCP/IP Administration

Internet Protocols Fall Lectures 7-8 Andreas Terzis

8.2 The Internet Protocol

Internet Protocol Address

ICS 351: Today's plan

How To Make A Network Address Prefix Smaller

IP addressing. Interface: Connection between host, router and physical link. IP address: 32-bit identifier for host, router interface

A DHCP Primer. Dario Laverde, 2002 Dario Laverde

CS 348: Computer Networks. - IP addressing; 21 st Aug Instructor: Sridhar Iyer IIT Bombay

IP Addressing Introductory material.

Transport and Network Layer

Internetworking and IP Address

Introduction to LAN/WAN. Network Layer (part II)

Internet Protocol (IP) IP - Network Layer. IP Routing. Advantages of Connectionless. CSCE 515: Computer Network Programming IP routing

Computer Networks. Lecture 3: IP Protocol. Marcin Bieńkowski. Institute of Computer Science University of Wrocław

Binding IP Addresses To Physical Hardware Addresses

IP Addressing. IP Addresses. Introductory material.

Investigation of DHCP Packets using Wireshark

IP Subnetting and Addressing

Computer Network Foundation. Chun-Jen (James) Chung. Arizona State University

Network layer: Overview. Network layer functions IP Routing and forwarding

IP address format: Dotted decimal notation:

1. How many unique network IDs are there in class A addresses? # of unique hosts?

PART IV. Network Layer

Classful IP Addressing (cont.)

Savera Tanwir. Internet Protocol

Internet Protocols Fall Outline

RARP: Reverse Address Resolution Protocol

How To Plan Out Your Own Version Of Hpl (Dhcp) On A Network With A Network (Dns) On Your Network (Dhpl) On An Ipad Or Ipad On A Pc Or Ipa On A Server On A

More Internet Support Protocols

Tutorial (03) IP addresses & Sub netting

SUPPORT DE COURS. Dr. Omari Mohammed Maître de Conférences Classe A Université d Adrar Courriel : omarinmt@gmail.com

DHCP Server. Heng Sovannarith

5. Classless and Subnet Address Extensions 최 양 희 서울대학교 컴퓨터공학부

TCP/IP Basis. OSI Model

Chapter 4 Network Layer

Mobile IP. Bheemarjuna Reddy Tamma IIT Hyderabad. Source: Slides of Charlie Perkins and Geert Heijenk on Mobile IP

SUBNETS, CIDR, AND CLASSLESS ADDRESSING

Chapter 3: Review of Important Networking Concepts. Magda El Zarki Dept. of CS UC Irvine

1 Data information is sent onto the network cable using which of the following? A Communication protocol B Data packet

Lecture Computer Networks

Chapter 12 Supporting Network Address Translation (NAT)

Variable length subnetting

03 Internet Addressing

AS/400e. TCP/IP routing and workload balancing

Course Overview: Learn the essential skills needed to set up, configure, support, and troubleshoot your TCP/IP-based network.

Technical Support Information Belkin internal use only

Lehrstuhl für Informatik 4 Kommunikation und verteilte Systeme. Auxiliary Protocols

How To Write A Boot(Ing) Protocol On A Microsoft Ipnet (Net) (Netnet) On A Network (Ipnet) With A Network Address) (Ip Address) On An Ip Address (Ipaddress) On Your Ip

This tutorial will help you in understanding IPv4 and its associated terminologies along with appropriate references and examples.

CCNA Tutorial Series SUBNETTING

CSC458 Lecture 6. Homework #1 Grades. Inter-domain Routing IP Addressing. Administrivia. Midterm will Cover Following Topics

Internet Working 5 th lecture. Chair of Communication Systems Department of Applied Sciences University of Freiburg 2004

IP Addressing. -Internetworking (with TCP/IP) -Classful addressing -Subnetting and Supernetting -Classless addressing

Networking Test 4 Study Guide

Ch 6: Networking Services: NAT, DHCP, DNS, Multicasting

CS 43: Computer Networks IP. Kevin Webb Swarthmore College November 5, 2013

Internet Protocols. Addressing & Services. Updated:

Internetworking Microsoft TCP/IP on Microsoft Windows NT 4.0

Date 07/05/ :20:22. CENTREL Solutions. Author. Version Product XIA Configuration Server [ ]

CE363 Data Communications & Networking. Chapter 6 Network Layer: Logical Addressing

Networking TCP/IP routing and workload balancing

Internet Protocol: IP packet headers. vendredi 18 octobre 13

Lab 5-5 Configuring the Cisco IOS DHCP Server

Unix System Administration

What is VLAN Routing?

Network-Oriented Software Development. Course: CSc4360/CSc6360 Instructor: Dr. Beyah Sessions: M-W, 3:00 4:40pm Lecture 2

Lecture 8. IP Fundamentals

Computer Networks 1 (Mạng Máy Tính 1) Lectured by: Dr. Phạm Trần Vũ

Introduction to Network Operating Systems

Chapter 19 Network Layer: Logical Addressing 19.1

ERserver. iseries. TCP/IP routing and workload balancing

Configuring DHCP. DHCP Server Overview

CompTIA Exam N CompTIA Network+ certification Version: 5.1 [ Total Questions: 1146 ]

Guide to Network Defense and Countermeasures Third Edition. Chapter 2 TCP/IP

Ch 6: Networking Services: NAT, DHCP, DNS, Multicasting, NTP

Lecture 15. IP address space managed by Internet Assigned Numbers Authority (IANA)

IP Addressing A Simplified Tutorial

Network layer" 1DT066! Distributed Information Systems!! Chapter 4" Network Layer!! goals: "

Internet Addresses (You should read Chapter 4 in Forouzan)

Module 2: Assigning IP Addresses in a Multiple Subnet Network

Basic IPv6 WAN and LAN Configuration

(Refer Slide Time: 02:17)

IP addresses have hierarchy (network & subnet) Internet names (FQDNs) also have hierarchy. and of course there can be sub-sub-!!

Mobile IP Network Layer Lesson 02 TCP/IP Suite and IP Protocol

Guide to TCP/IP, Third Edition. Chapter 3: Data Link and Network Layer TCP/IP Protocols

Subnetting/Supernetting and Classless Addressing

DG Forwarding Algorithm

Computer Networks. Introduc)on to Naming, Addressing, and Rou)ng. Week 09. College of Information Science and Engineering Ritsumeikan University

iseries TCP/IP routing and workload balancing

IP addressing and forwarding Network layer

LAN TCP/IP and DHCP Setup

Transcription:

Efficient Addressing Outline Addressing Subnetting Supernetting CS 640 1

IPV4 Global Addresses Properties IPv4 uses 32 bit address space globally unique hierarchical: network + host 7 24 Dot Notation 10.3.2.4 128.96.33.81 192.12.69.77 A: B: 0 Network Host 14 16 1 0 Network Host 21 8 C: 1 1 0 Network Host CS 640 2

How to Make Routing Scale Flat (Ethernet) versus Hierarchical (Internet) Addresses All hosts attached to same network have same network address Problem: inefficient use of Hierarchical Address Space class C with 2 hosts (2/255 = 0.78% efficient) class B with 256 hosts (256/65535 = 0.39% efficient) Problem: still Too Many Networks routing tables do not scale Big tables make routers expensive route propagation protocols do not scale CS 640 3

Subnetting - 1985 Original intent was for network to identify one physical network Lots of small networks are what we actually have how do we handle this? Solution: add another level to address/routing hierarchy: subnet Allocate addresses to several physical networks Routers in other ASs (networks) route all traffic to network as if it is a single physical network Subnet masks define variable partition of host part 1 s identify subnet, 0 s identify hosts within the subnet Mechanism for sharing a single network number among multiple networks Subnets visible only within a site Network number Host number Class B address 111111111111111111111111 00000000 Subnet mask (255.255.255.0) Network number Subnet ID Host ID Subnetted address CS 640 4

Subnet Example Subnet mask: 255.255.255.128 Subnet number: 128.96.34.0 128.96.34.15 128.96.34.1 H1 R1 128.96.34.130 Subnet mask: 255.255.255.128 Subnet number: 128.96.34.128 H3 128.96.33.14 128.96.34.129 R2 Subnet mask: 255.255.255.0 Subnet number: 128.96.33.0 128.96.33.1 128.96.34.139 H2 Forwarding table at router R1 Subnet Number Subnet Mask Next Hop 128.96.34.0 255.255.255.128 interface 0 128.96.34.128 255.255.255.128 interface 1 128.96.33.0 255.255.255.0 R2 CS 640 5

Forwarding Algorithm D = destination IP address for each entry (SubnetNum, SubnetMask, NextHop) D1 = SubnetMask & D if D1 = SubnetNum if NextHop is an interface deliver datagram directly to D else deliver datagram to NextHop Use a default router if nothing matches Not necessary for all 1s in subnet mask to be contiguous Can put multiple subnets on one physical network Subnets not visible from the rest of the Internet This is a simple, toy example!! CS 640 6

Subnets contd. Subnetting is not the only way to solve scalability problems Additional router support is necessary to include netmask and forwarding functionality Non-contiguous netmask numbers can be used They make administration more difficult Multiple subnets can reside on a single network Requires routers within the network Subnets help solve scalability problems Do not require us to use class B or C address for each physical network Help us to aggrigate information Chief advantage of IP addresses: routers could keep one entry per network instead of one per destination host CS 640 7

Continued Problems with IPv4 Addresses Problem: Potential exhaustion of IPv4 address space (due to inefficiency) Class B network numbers are highly prized Not everyone needs one Lots of class C addresses but no one wants them Growth of back bone routing tables We don t want lots of small networks since this causes large routing tables Route calculation and management requires high computational overhead Solution: Allow addresses assigned to a single entity to span multiple classed prefixes Enhance route aggregation CS 640 8

Supernetting Assign block of contiguous network numbers to nearby networks Called CIDR: Classless Inter-Domain Routing Breaks rigid boundries between address classes If ISP needs 16 class C addresses, make them contiguous Eg.192.4.16 to 192.4.31 enables a 20-bit network number Idea is to enable network number to be any length Collapse multiple addresses assigned to a single AS to one address Represent blocks (number of class C networks) with a single pair (first_network_address, count) Restrict block sizes to powers of 2 Use a bit mask (CIDR mask) to identify block size All routers must understand CIDR addressing CS 640 9

CIDR Addresses Identifying a CIDR block requires both an address and a mask Slash notation 128.211.168.0/21 for addresses 128.211.168.0 128.211.175.255 Here the /21 indicates a 21 bit mask All possible CIDR masks can easily be generated /8, /16, /24 correspond to traditional class A, B, C categories IP addresses are now arbitrary integers, not classes Raises interesting questions about lookups Routers cannot determine the division between prefix and suffix just by looking at the address Hashing does not work well Interesting lookup algorithms have been developed and analyzed CS 640 10

CIDR Address Assignment 201.10.0.0/20 Provider 201.10.0.0/22 201.10.4.0/24 201.10.5.0/24 201.10.6.0/23 11

CIDR Implications Longest prefix match 7 contiguous Class C s given to network A: 200.10.0.0 200.10.6.255 N/w number 200.10.0.0/21 8th class C given to network B: 200.10.7.0 200.10.7.255 N/w number 200.10.7.0/24 Packet with destination address 200.10.7.1 matches both networks Must pick the most specific match! 12

IP/MAC Address Translation Outline ARP RARP DHCP

Transition from Network to Datalink How do we get datagrams to the right physical host? Tricky part comes when a router is forwarding to a LAN with multiple hosts (which is typically the case) IP datagrams contain an IP address Configured in OS NIC s only understand addressing of their particular network Ethernet s 48 bit MAC addresses 14

Address Translation Problem We need a means for mapping IP addresses into MAC (physical) addresses Destination host Next hop router We can then encapsulate (surpirse!) IP datagrams inside a frame with link level address Possible mapping techniques Encode physical address in host part of IP address Make physical address the same as the host portion of IP address Obviously not possible using IPv4 and Ethernet Build a table of IP/MAC pairs How is it maintained? 15

Address Resolution Protocol (ARP) ARP is part of the TCP/IP specification Enable each host to build table of IP to physical address bindings Dynamic binding protocol no static entries in table Allows new nodes to be easily added to broadcast network Simple idea: broadcast request if an IP address not in table Supported by link level technology Determine host B s physical address P B from it IP address I B 1. Host A broadcasts an ARP request containing I B to all hosts on LAN 2. Host B responds with an ARP reply containing the pair (I B,P B ) 16

ARP Implementation ARP Packet Details HardwareType: type of physical network (e.g., Ethernet) ProtocolType: type of higher layer protocol (e.g., IP) HLEN & PLEN: length of physical and protocol addresses Provides for flexibility to handle a variety of network technologies Operation: request or response Source/Target-Physical/Protocol addresses Notes Table entries timeout in about 10 minutes (caching is important) Update table with source when you are the target Update table even if there is already an entry Do not refresh table entries upon reference IP addresses are assigned independently of a systems HW addresses 17

ARP Packet Format 0 8 16 31 Hardware type = 1 ProtocolT ype = 0x0800 HLen = 48 PLen = 32 Operation SourceHardwareAddr (bytes 0 3) SourceHardwareAddr (bytes 4 5) SourceProtocolAddr (bytes 2 3) SourceProtocolAddr (bytes 0 1) TargetHardwareAddr (bytes 0 1) TargetHardwareAddr (bytes 2 5) TargetProtocolAddr (bytes 0 3) 18

Determining an IP Address at Startup How does a machine without permanent storage determine its IP address? OS images with specific IP s cannot be used on multiple machines Critical for network appliances or embedded systems Use the network to obtain an IP from a remote server System must use its physical address to to communicate Requests address from server which maintains table of IP s System doesn t know the server - sends broadcast request for address 19

Dynamic Configuration BOOTP was designed for relatively static environment where each host has a permanent network connection Net manager creates a BOOTP config file with parameters for each host file is typically stable for long periods Wireless networking enables environments much more dynamic BOOTP does not provide for dynamic address assignment Dynamic configuration is the primary method for IP address allocation used today Not only facilitates mobility but also efficient use of IPs 20

Dynamic Host Configuration DHCP extends BOOTP Protocol Still supports static allocation Supports automatic configuration where addresses are permanent but assigned by DHCP Supports temporary allocation Relies on existence of a DHCP server Repository for host configuration information Maintains a pool of available IP s for use on demand Considerably reduces administration overhead Autoconfiguration of course depends on administrative policy Uses UDP to send messages Uses a relay agent to communicate with servers off LAN (same as BOOTP) Relay agent is statically configured with DHCP server address 21

DHCP Implementation State machine (6 states) which determines DHCP operation Host boots into INITIALIZE state To contact the DHCP server(s) a client sends DHCPDISCOVER message to IP broadcast address and moves to SELECT state Unique header format with variable length options field UDP packet sent to well known BOOTP port 67 Server(s) respond with DHCPOFFER message Client can receive 0 or more responses and responds to one Client moves to REQUEST state to negotiate IP lease with 1 server Sends DHCPREQUEST message to server which responds with DHCPACK Client is then in BOUND (normal) state 22

DHCP Implementation contd. From BOUND, client can issue DHCPRELEASE and return to INITIALIZE state This is simply client deciding it no longer needs the IP When lease reaches 50% of lease expiration time, it issues DHCPREQUEST to extend lease of current IP with server and moves to RENEW state Receipt of DHCPACK moves client back to BOUND state Receipt of DHCPNACK moves client back to INITIALIZE state If no response is received by 87.5% of lease expiration time, the client resends the DHCPREQUEST and moves to REBIND state Receipt of DHCPACK moves client back to BOUND state Receipt of DHCPNACK or timeout moves client back to INITIALIZE state 23

DHCP Details Without relay agent, DHCP would not scale since it would require large number of servers (one per LAN) Addresses which are leased over a given period of time and must be updated This means that DHCP requests might have to be made multiple times by the same system (RENEW requests) DHCP does not interact with DNS Binding between IP assigned by DHCP and host name must be made independently Possible result 1: No host name given Possible result 2: Host is automatically assigned a preallocated domain name with its IP Possible results 3: Hosts are assigned permanent names Requires additional mechanisms which do not yet exist 24