Bumps in the Wire: NAT and DHCP Nick Feamster CS 4251 Computer Networking II Spring 2008.

Slides:



Advertisements
Similar presentations
Usage-Based DHCP Lease- Time Optmization Manas Khadilkar, Nick Feamster, Russ Clark, Matt Sanders Georgia Tech.
Advertisements

Fred P. Baker CCIE, CCIP(security), CCSA, MCSE+I, MCSE(2000)
Any Questions?.
© 2008 Cisco Systems, Inc. All rights reserved.Cisco ConfidentialPresentation_ID 1 Chapter 8: Subnetting IP Networks Network Fundamentals.
1 Network Address Translation (NAT) Relates to Lab 7. Module about private networks and NAT.
IP/MAC Address Translation
Ch. 23, 25 Q and A (NAT and UDP) Victor Norman IS333 Spring 2014.
CST Computer Networks NAT CST 415 4/10/2017 CST Computer Networks.
CPSC Network Layer4-1 IP addresses: how to get one? Q: How does a host get IP address? r hard-coded by system admin in a file m Windows: control-panel->network->configuration-
Transitioning to IPv6 April 15,2005 Presented By: Richard Moore PBS Enterprise Technology.
CMPE 150- Introduction to Computer Networks 1 CMPE 150 Fall 2005 Lecture 25 Introduction to Computer Networks.
Internet Control Protocols Savera Tanwir. Internet Control Protocols ICMP ARP RARP DHCP.
MCTS Guide to Microsoft Windows Server 2008 Network Infrastructure Configuration Chapter 4 Installing and Configuring the Dynamic Host Configuration Protocol.
System Configuration: DHCP and Autoconfiguration Chapter 6.
COS 420 Day 18. Agenda Assignment 4 Posted Chap Due April 6 Group project program requirements Submitted but Needs lots of work Individual Project.
NAT (Network Address Translator) Atif Karamat In the name of God the most merciful and the most compassionate.
Ch. 1 – Scaling IP Addresses NAT/PAT and DHCP CMPSC-358 (CCNA 4 ) Spring 2007.
DHCP and Network Settings What is DHCP and its function, what is a Gateway and why do we need one, what is DNS? Presentation written by Carol A. Hopkins.
BOOTP and DHCP Shivkumar Kalyanaraman Rensselaer Polytechnic Institute
Subnetting.
EEC-484/584 Computer Networks Lecture 14 Wenbing Zhao
Section 461.  ARP  Ghostbusters  Grew up in Lexington, KY  Enjoy stargazing, cycling, and mushroom hunting  Met Mario once (long time ago)
1 Dynamic Host Configuration Protocol (DHCP). 2 Dynamic Assignment of IP addresses Dynamic assignment of IP addresses is desirable for several reasons:
Managing DHCP. 2 DHCP Overview Is a protocol that allows client computers to automatically receive an IP address and TCP/IP settings from a Server Reduces.
70-291: MCSE Guide to Managing a Microsoft Windows Server 2003 Network Chapter 4: Dynamic Host Configuration Protocol.
Support Protocols and Technologies. Topics Filling in the gaps we need to make for IP forwarding work in practice – Getting IP addresses (DHCP) – Mapping.
Bootstrap and Autoconfiguration (DHCP)
Network Address Translation (NAT)
COMS W COMS W Lecture 8. NAT, DHCP & Firewalls.
1 Dynamic Host Configuration Protocol (DHCP) Relates to Lab 7. Module about dynamic assignment of IP addresses with DHCP.
1 IP: putting it all together Part 2 G53ACC Chris Greenhalgh.
© MMII JW RyderCS 428 Computer Networking1 Private Network Interconnection  VPN - Virtual Private Networks  NAT - Network Address Translation  Describe.
Common Devices Used In Computer Networks
Dynamic Host Configuration Protocol (DHCP). History Diskless workstations –needed to know configuration parameters like IP address, netmask, gateway address.
CIS 3360: Internet: Network Layer Introduction Cliff Zou Spring 2012.
Chapter 15 DHCP. Dynamic Host Configuration Protocol An Application Layer Protocol A client server protocol that automatically provides an IP host with.
1 CS 4396 Computer Networks Lab Dynamic Host Configuration Protocol (DHCP)
© 2007 Cisco Systems, Inc. All rights reserved. 1 Network Addressing Networking for Home and Small Businesses – Chapter 5 Darren Shaver – Modified Fall.
 An Internet Protocol address (IP address) is a numerical label assigned to each device (e.g., computer, printer) participating in a computer network.
MCTS Guide to Microsoft Windows Server 2008 Network Infrastructure Configuration Chapter 4 Installing and Configuring the Dynamic Host Configuration Protocol.
BAI513 - PROTOCOLS DHCP BAIST – Network Management.
DHCP/BOOTP Dynamic Host Configuration Protocol Dynamic Host Configuration Protocol (DHCP) is a network protocol that enables a server to automatically.
Networks and Protocols CE Week 3a. DHCP, ARP, DNS, TCP/UDP.
BZUPAGES.COM BOOTP and DHCP The Bootstrap Protocol (BOOTP) is a client/server protocol that configures a diskless computer or a computer that is booted.
Lectu re 1 Recap: “Operational” view of Internet r Internet: “network of networks” m Requires sending, receiving of messages r protocols control sending,
Chapter 18 Host Configuration : DHCP
Chapter 22 Bootstrap and Auto configuration (DHCP) History of Bootstrap -Bootstrap is used to assign IP address to the computer. -Constant changes in the.
1 Network Address Translation (NAT) and Dynamic Host Configuration Protocol (DHCP) Relates to Lab 7. Module about private networks and NAT.
CIS 856: TCP/IP and Upper Layer Protocols Karthik Ravindra Nov 11, 2008 Dynamic Host Configuration Protocol [DHCP] - RFC 2131.
Allocating IP Addressing by Using Dynamic Host Configuration Protocol.
Multicasting  A message can be unicast, multicast, or broadcast. Let us clarify these terms as they relate to the Internet.
Address Translation Outline Datalink layer intro ARP RARP DHCP.
DHCP Vrushali sonar. Outline DHCP DHCPv6 Comparison Security issues Summary.
Dynamic Host Configuration Protocol (DHCP) DHCP provides a temporary IP address for a limited period of time DHCP has two databases. First one has static.
BAI513 - PROTOCOLS DHCP BAIST – Network Management.
Chapter 5. An IP address is simply a series of binary bits (ones and zeros). How many binary bits are used? 32.
IPv6 Security Issues Georgios Koutepas, NTUA IPv6 Technology and Advanced Services Oct.19, 2004.
Configuring and Managing the DHCP Server Role. DHCP overview RARP – one of the first ways to assign addresses BOOTP – Another legacy way to assign addresses.
Scaling the Network: Subnetting and Other Protocols
Scaling the Network Chapters 3-4 Part 2
Introducing To Networking
Net 431 D: ADVANCED COMPUTER NETWORKS
Chapter 18 Host Configuration : DHCP
DHCP and NAT.
Scaling the Network: Subnetting and Other Protocols
Allocating IP Addressing by Using Dynamic Host Configuration Protocol
CS4470 Computer Networking Protocols
Chapter 18 Host Configuration : DHCP
Dynamic Host Configuration Protocol (DHCP)
Network Address Translation (NAT)
Presentation transcript:

Bumps in the Wire: NAT and DHCP Nick Feamster CS 4251 Computer Networking II Spring 2008

NATs and Tunnels NATs originally invented as a way to help migrate to a hybrid IPv4 IPv6 world –Took on a life of their own –May have substantially delayed IPv6 deployment by reducing address pressure! –You probably encounter them every day Tunnels: Coming up after NATs.

B IP Network Address Translation NAT maps (private source IP, source port) onto (public source IP, unique source port) –reverse mapping on the way back –destination host does not know that this process is happening Very simple working solution. –NAT functionality fits well with firewalls Publ A IP B IP A Port B Port Priv A IP B IP A Port B Port Publ A IP B Port B IP Priv A IP B Port A Port A B

Types of NATs Bi-directional NAT: 1 to 1 mapping between internal and external addresses. –E.g., /16 -> /16 –External hosts can directly contact internal hosts –Why use? Flexibility. Change providers, dont change internal addrs. Need as many external addresses as you have hosts - can use sparse address space internally. Traditional NAT: Unidirectional –Basic NAT: Pool of external addresses Translate source IP address (+checksum,etc) only – Network Address Port Translation (NAPT): What most of us use Also translate ports. –E.g., map ( port > port 22) to ( port > port 22) Lets you share a single IP address among multiple computers

NAT Considerations NAT has to be consistent during a session. –Set up mapping at the beginning of a session and maintain it during the session Recall 2 nd level goal 1 of Internet: Continue despite loss of networks or gateways What happens if your NAT reboots? –Recycle the mapping that the end of the session May be hard to detect NAT only works for certain applications. –Some applications (e.g. ftp) pass IP information in payload –Need application level gateways to do a matching translation –Breaks a lot of applications. Example: Lets look at FTP NAT is loved and hated - Breaks many apps (FTP) - Inhibits deployment of new applications like p2p (but so do firewalls!) + Little NAT boxes make home networking simple. + Saves addresses. Makes allocation simple.

Interconnection: Gateways Interconnect heterogeneous networks No state about ongoing connections –Stateless packet switches Generally, router == gateway But, we can think of your home router/NAT as also performing the function of a gateway Home Network Internet : :50879

Network Address Translation For outbound traffic, the gateway: –Creates a table entry for computer's local IP address and port number –Replaces the sending computer's non-routable IP address with the gateway IP address. –replaces the sending computer's source port For inbound traffic, the gateway: –checks the destination port on the packet –rewrites the destination address and destination port those in the table and forwards traffic to local machine

NAT Traversal Problem: Machines behind NAT not globally addressable or routable. Cant initiate inbound conenctions. One solution: Signalling and Tunneling through UDP- Enabled NAT Devices (STUN) –STUN client contacts STUN server –STUN server tells client which IP/Port the NAT mapped it to –STUN client uses that IP/Port for call establishment/incoming messages Home Network 1 Home Network 2 Relay node

DHCP DHCPOFFER –IP addressing information –Boot file/server information (for network booting) –DNS name servers –Lots of other stuff - protocol is extensible; half of the options reserved for local site definition and use. DHCPDISCOVER - broadcast DHCPOFFER DHCPREQUEST DHCPACK

DHCP Features Lease-based assignment –Clients can renew. Servers really should preserve this information across client & server reboots. Provide host configuration information –Not just IP address stuff. –NTP servers, IP config, link layer config, –X window font server (wow) Use: –Generic config for desktops/dialin/etc. Assign IP address/etc., from pool –Specific config for particular machines Central configuration management

Dynamic Host Configuration Protocol Commonly used to automatically –assign IP addresses to clients –set various configuration parameters Useful for managing IP address space where – the total number of users outstrips the total number of concurrent users Operators can –dynamically assign IP addresses to clients and –reclaim IP addresses when clients leave

DHCP: Operation and Lease Times Lease Time: the time interval after which a server can reclaim an IP address –Configurable at server (universal or per-client) DISCOVER OFFER REQUEST ACK REQUEST Renew at ½ the lease time

Lease-Time Optimization Tradeoff: Utilization vs. Scalability, Convenience –Too long: Address space can be exhausted –Too short: Clients must reauthenticate, increase in broadcast traffic Problem: Determine the appropriate lease time setting (and strategy) that –Minimizes inconvenience and unnecessary traffic –Avoids address-space exhaustion

Outline Measurement study of DHCP utilization on the Georgia Tech wireless network (LAWN) –Largest known public DHCP study: 6,000 users/day –Study of on-times and off-times Emulation tool for evaluating the effects of longer lease times on utilization Evaluation of alternative lease time strategies –Single adaptation –Exponential

Environment and Data Environment: Georgia Tech Local-Area Walkup/Wireless Network (LAWN) –6,000 unique users per day –2,500 concurrent users at peak –4,000 IP addresses –1,000 access points –2,800 network ports –Single VLAN Data: DHCP Server logs from Feb 12-17, 2007 –Used MAC addresses to identify individual clients –Current lease-time setting: 30 minutes

Estimating Duration of Client Activity Clients issue DHCP Renew messages –One message every half-lease-time interval Idea: Use DHCP messages to estimate client presence/departure –Estimate client departure at time of last-seen renew plus one-fourth the lease time

DHCP Utilization on GT LAWN Students returning to dorms Wired machines MondayTuesday Wednesday Thursday Friday Time Number of Active Leases

Individual Client Dynamics On-Time: The duration of time a client is active –(last request - first request) + ¼(lease time) –20% of sessions: 30 minutes or less –59% of sessions: 90 minutes or less –Implication: increasing lease time to 90 min could save renewals Off-time: Duration between a new lease and the time of the last expired lease –time of request – (time of last renew + lease time) –70% of off-times: less than 210 minutes –30% of off-times: less than 30 minutes

Emulating Longer Lease Times DISCOVER and RELEASE remain unchanged Some DISCOVER messages become renew REQUEST messages On-Time (22.5 min) Off-time (37.5 min) On-time (22.5 min) 30-min Lease 60-min Lease

Emulating Longer Lease Times Time (min) Number of active leases

Effects of Longer Lease Times Increased address space utilization –30-minute lease time: 67% utilization –90-minute lease time: 80% utilization –240-minute lease time: exhaustion Reduced renewals and expirations –90-minute lease time saves 70% of renewal messages 23% of expirations

Alternative Lease-Time Strategies Single adaptation: Set initial lease time, then smaller lease time upon renewal –Example: 90-minute initial lease time, 30-min renewal –Intuition: Optimize for class time interval Exponential: Exponentially increase lease time upon each renewal –Intuition: Clients that have been present on the network longer are likely to persist

Effects of Alternative Strategies 77% 71% 30% Renewals Saved Time (min) Number of active leases

Summary Measurement study of DHCP utilization on the Georgia Tech wireless network (LAWN) –Largest known public DHCP study: 6,000 users/day –Study of on-times and off-times Emulation tool for evaluating the effects of longer lease times on utilization Evaluation of alternative lease time strategies –Single adjustment –Exponential

IPv6 Autoconfiguration Serverless (Stateless). No manual config at all. –Only configures addressing items, NOT other host things If you want that, use DHCP. Link-local address – :: 64 bit interface ID (usually from Ethernet addr) (fe80::/64 prefix) –Uniqueness test (anyone using this address?) –Router contact (solicit, or wait for announcement) Contains globally unique prefix Usually: Concatenate this prefix with local ID -> globally unique IPv6 ID DHCP took some of the wind out of this, but nice for zero-conf (many OSes now do this for both v4 and v6)