Presentation is loading. Please wait.

Presentation is loading. Please wait.

CSE452:Computer Networks

Similar presentations


Presentation on theme: "CSE452:Computer Networks"— Presentation transcript:

1 CSE452:Computer Networks
4/17/2017 CSE452:Computer Networks The Internet Protocol(IP) IPv4 & IPv6 CIDR, Subnet

2 The Internet Network layer
4/17/2017 The Internet Network layer Host, router network layer functions: Transport layer: TCP, UDP IP protocol addressing conventions datagram format packet handling conventions Routing protocols path selection RIP, OSPF, BGP Network layer routing table ICMP protocol error reporting router “signaling” Link layer physical layer 4/17/2017

3 IP Addressing: introduction
IP address: 32-bit identifier for host, router interface interface: connection between host, router and physical link router’s typically have multiple interfaces host may have multiple interfaces IP addresses associated with interface, not host, router = 223 1 1 1 4/17/2017

4 IP Addressing IP address:
network part (high order bits) host part (low order bits) What’s a network ? (from IP address perspective) device interfaces with same network part of IP address can physically reach each other without intervening router LAN network consisting of 3 IP networks (for IP addresses starting with 223, first 24 bits are network address) 4/17/2017

5 IP Addressing How to find the networks?
Detach each interface from router, host create “islands of isolated networks Interconnected system consisting of six networks 4/17/2017

6 IP Addresses given notion of “network”, let’s re-examine IP addresses:
“class-full” addressing: class A to network host B to 10 network host to C 110 network host to D 1110 multicast address 32 bits 4/17/2017

7 IP Addressing An IP address is a 32-bit sequence of 1s and 0s.
To make the IP address easier to use, the address is usually written as four decimal numbers separated by periods. This way of writing the address is called the dotted decimal format. 4/17/2017

8 Decimal and Binary Conversion
4/17/2017

9 IPv4 Addressing 4/17/2017

10 Class A, B, C, D, and E IP Addresses
4/17/2017

11 4/17/2017

12 Reserved IP Addresses 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. 4/17/2017

13 Network Address 4/17/2017

14 Broadcast Address 4/17/2017

15 Public and Private IP Addresses
No two machines that connect to a public network can have the same IP address because public IP addresses are global and standardized. Procedure was needed to make sure that addresses were in fact unique. Originally, an organization known as the Internet Network Information Center (InterNIC) handled this procedure. InterNIC no longer exists and has been succeeded by the Internet Assigned Numbers Authority (IANA). IANA carefully manages the remaining supply of IP addresses to ensure that duplication of publicly used addresses does not occur. However, private networks that are not connected to the Internet may use any host addresses, as long as each host within the private network is unique. 4/17/2017

16 Public and Private IP Addresses
RFC 1918 sets aside three blocks of IP addresses for private, internal use. Addresses that fall in these ranges are not routed on the Internet backbone. Internet router immediately discard private addresses. Connecting a network using private addresses to the Internet requires translation of the private addresses to public addresses using Network Address Translation (NAT). 4/17/2017

17 IP addressing: CIDR Classful addressing:
inefficient use of address space, address space exhaustion e.g., class B net allocated enough addresses for 65K hosts, even if only 2K hosts in that network CIDR: Classless InterDomain Routing network portion of address of arbitrary length address format: a.b.c.d/x, where x is # bits in network portion of address network part host /23 4/17/2017

18 Why Subnet? Millions of Addresses Available Over 16,000,000 Efficiency
Non-subnetted networks are wasteful Division of networks not optimal Smaller Network Easier to manage Smaller broadcast domains So Make the network as small as possible Divide the network into subnetworks Borrow some bits from the host add. 4/17/2017

19 What You Need Understand Address System Understand Classes of Networks
“Two-Tums” Table Formulas Magic Numbers Subnet Mask “ANDing” Process 4/17/2017

20 Dissecting the Address > Classes <
CLASS RANGES: A: 0 – N . H . H . H B: 128 – 191 N . N . H . H C: 192 – 223 N . N . N . H Network HOST _ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ (Digital) (Decimal) CLASS B 4/17/2017

21 TWO-TUMS MAGIC NUMBERS: SUBNET MASK: 4/17/2017

22 Number of Usable Subnets Number of Usable Hosts/Subnet
Magic Formulas Number of Usable Subnets 2n – 2 = = -1 = = 0 = = 2 = = 6 Number of Usable Hosts/Subnet 2h-n – 2 = = 254 =? = ? =? n = # borrowed bits h = # bits available in host address 4/17/2017

23 Subnet Mask What is a Subnet Mask? Why is it needed? How?
“Extended Network Prefix” Indicates extent of the Network numbers _ _ _ _ _ _ _ _ Why is it needed? Used by router to determine Network Address How? Uses “ANDing” to compare Mask to IP Address 4/17/2017

24 ANDing Process MASK: IP: Network Address: 4/17/2017

25 How to Subnet? * Subnet: Borrow
_ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ ._ _ _ _ _ _ _ _ (Digital) (Decimal) Network 19 Host 13 4/17/2017

26 Easy Example 4/17/2017

27 Set Up Subnets 200.200.200.10 5 Subnets What is the Subnet Mask?
What are the Network Addresses? What is the Broadcast Domain What IP Addresses are available? 4/17/2017

28 Steps…. C [Range: 192 – 223]] What is the CLASS?
5 Subnets [23-2 = 6] Use Subnet Mask # Borrow 3 Bits 32 Wire Range BC What is the CLASS? How many BITS do we need to borrow? Determine Subnet Mask Determine “Magic Number” Set up Table for IP Address (“Wire”), Range & Broadcast Domain Fill in Table 4/17/2017

29 Table WIRE RANGE BC 4/17/2017

30 Table 200.200.200.10 WIRE RANGE BC Borrow 5 Bits Class C 200.200.200.0
4/17/2017

31 Table 200.200.200.10 WIRE RANGE BC +.32 +.32 Magic Number
+.32 +.32 Magic Number 4/17/2017

32 Table 200.200.200.10 WIRE RANGE BC Subnet Mask 200.200.200.0
Subnet Mask 4/17/2017

33 Table WIRE RANGE BC 4/17/2017

34 Table 200.200.200.10 WIRE RANGE BC Broadcast Domain 200.200.200.0
Broadcast Domain 4/17/2017

35 Table WIRE RANGE BC 4/17/2017

36 Table WIRE RANGE BC 4/17/2017

37 Table 200.200.200.10 WIRE RANGE BC Reserved for Network Addresses
Reserved for Network Addresses Reserved for Broadcast Addresses 4/17/2017

38 Table WIRE RANGE BC 4/17/2017

39 Set Up Subnets 4/17/2017

40 4/17/2017

41 Obtaining an Internet Address
Static addressing Each individual device must be configured with an IP address. Dynamic addressing Reverse Address Resolution Protocol (RARP) Bootstrap Protocol (BOOTP) Dynamic Host Configuration Protocol (DHCP) DHCP initialization sequence Function of the Address Resolution Protocol ARP operation within a subnet 4/17/2017

42 Obtaining an IP Address
A network host needs to obtain a globally unique address in order to function on the Internet. MAC has only significance only in LAN to identify host. Router does not use MAC address(?) to forward packets outside LAN. IP addresses are used for Internet communication. IP is hierarchical addressing Scheme that allows individual addresses to be associated together and treated together.

43 Obtaining an IP Address
Regardless of the method chosen no two interfaces can have the same IP address. 4/17/2017

44 Static Assignment of an IP Address
Static assignment works best on small, infrequently changing networks. The system administrator manually assigns and tracks IP addresses for each computer, printer, or server on the intranet. Servers should be assigned a static IP address so workstations and other devices will always know how to access needed services. Other devices that should be assigned static IP addresses are network printers, application servers, and routers. 4/17/2017

45 IP addresses: how to get one?
hard-coded by system admin in a file Wintel: control-panel->network->configuration->tcp/ip->properties UNIX: /etc/rc.config DHCP: Dynamic Host Configuration Protocol: dynamically get address: “plug-and-play” host broadcasts “DHCP discover” msg DHCP server responds with “DHCP offer” msg host requests IP address: “DHCP request” msg DHCP server sends address: “DHCP ack” msg 4/17/2017

46 DHCP client-server scenario
4/17/2017

47 DHCP client-server scenario
DHCP server: arriving client DHCP discover src : , dest.: ,67 DHCPDISCOVER yiaddr: transaction ID: 654 DHCP offer src: , dest: , 68 DHCPOFFER yiaddrr: transaction ID: 654 DHCP server ID: Lifetime: 3600 secs DHCP request src: , dest:: , 67 DHCPREQUEST yiaddrr: transaction ID: 655 DHCP server ID: Lifetime: 3600 secs time DHCP ACK src: , dest: , 68 DHCPACK yiaddrr: transaction ID: 655 DHCP server ID: Lifetime: 3600 secs 4/17/2017

48 DHCP IP Address Management
DHCP allows a host to obtain an IP address dynamically without the network administrator having to set up an individual profile for each device. All that is required when using DHCP is a defined range of IP addresses on a DHCP server. As hosts come online, they contact the DHCP server and request an address. The DHCP server chooses an address and leases it to that host. With DHCP, the entire network configuration of a computer can be obtained in one message. The major advantage that DHCP has over BOOTP is that it allows users to be mobile. This mobility allows the users to freely change network connections from location to location. The importance to this DHCP advancement is its ability to lease an IP address to a device and then reclaim that IP address for another user after the first user releases it. This means that DHCP offers a one to many ratio of IP addresses and that an address is available to anyone who connects to the network. 4/17/2017

49 IP addresses: how to get one?
Network (network portion): get allocated portion of ISP’s address space: ISP's block /20 Organization /23 Organization /23 Organization /23 … … …. Organization /23 4/17/2017

50 Hierarchical addressing: route aggregation
Hierarchical addressing allows efficient advertisement of routing information: Organization 0 /23 Organization 1 /23 “Send me anything with addresses beginning /20” Organization 2 /23 . Fly-By-Night-ISP . Internet Organization 7 /23 “Send me anything with addresses beginning /16” ISPs-R-Us 4/17/2017

51 Hierarchical addressing: more specific routes
ISPs-R-Us has a more specific route to Organization 1 Organization 0 /23 “Send me anything with addresses beginning /20” Organization 2 /23 . Fly-By-Night-ISP . Internet Organization 7 /23 “Send me anything with addresses beginning /16 or /23” ISPs-R-Us Organization 1 /23 4/17/2017

52 IP addressing: the last word...
Q: How does an ISP get block of addresses? A: ICANN: Internet Corporation for Assigned Names and Numbers allocates addresses manages DNS assigns domain names, resolves disputes 4/17/2017


Download ppt "CSE452:Computer Networks"

Similar presentations


Ads by Google