CS470 Computer Networking Protocols

Slides:



Advertisements
Similar presentations
© N. Ganesan, All rights reserved. Chapter IP Addressing Format.
Advertisements

IPv4 Addresses. Internet Protocol: Which version? There are currently two versions of the Internet Protocol in use for the Internet IPv4 (IP Version 4)
CECS 474 Computer Network Interoperability Notes for Douglas E. Comer, Computer Networks and Internets (5 th Edition) Tracy Bradley Maples, Ph.D. Computer.
IP Addressing and Subnetting
Chapter 18. IP: Internet Protocol Addresses
© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
CSCI 4550/8556 Computer Networks Comer, Chapter 18: IP: Internet Protocol Addresses.
© 2007 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets with Internet Applications, 4e By Douglas.
1 IP: Internet Protocol Addresses. 2 Internet Protocol (IP) Only protocol at Layer 3 Fundamental in suite Defines –Internet addressing –Internet packet.
IP Addressing. TCP/IP addresses -Addressing in TCP/IP is specified by the Internet Protocol (IP) -Each host is assigned a 32-bit number -Called the IP.
1 Spring Semester 2007, Dept. of Computer Science, Technion Internet Networking recitation #1 Subnet + CIDR.
© 2009 Pearson Education Inc., Upper Saddle River, NJ. All rights reserved.1 Computer Networks and Internets, 5e By Douglas E. Comer Lecture PowerPoints.
IP Addressing Pertemuan 18 Matakuliah: H0484/Jaringan Komputer Tahun: 2007.
1 IP Addressing (IPv4 ADDRESSES). 2 Universal Service Concept Any computer can communicate with any other computer in the world. Multiple independently.
Q and A, Ch. 21 IS333, Spring 2015 Victor Norman.
Chapter 21 IP Addressing “If we all did the things we are capable of doing, we would literally astound ourselves” - Thomas Alva Edison,
CS 6401 Efficient Addressing Outline Addressing Subnetting Supernetting.
Layering and the TCP/IP protocol Suite  The TCP/IP Protocol only contains 5 Layers in its networking Model  The Layers Are 1.Physical -> 1 in OSI 2.Network.
1 TCOM 509 – Internet Protocols (TCP/IP) Lecture 02_b Instructor: Dr. Li-Chuan Chen Date: 09/08/2003 Based in part upon slides of Prof. J. Kurose (U Mass),
21-IP addressing Dr. John P. Abraham Professor UTPA.
IP Addressing. Dotted Decimal Notation IP addresses are written in a so-called dotted decimal notation Each byte is identified by a decimal number in.
Spring Ch 18 IP Addresses. 2 Internet Protocol  Only protocol at Layer 3  Defines Internet addressing Internet packet format Internet routing.
Types of Addresses in IPv4 Network Range
Subnet & Classless Address Extensions Linda Wu (CMPT )
ECE 4110 – Internetwork Programming Subnetting, Supernetting, and Classless Addressing.
1 Internet Addresses (You should read Chapter 4 in Forouzan) IP Address is 32 Bits Long Conceptually the address is the pair ( NETID, HOSTID ) Addresses.
Classless and Subnet Address Extensions (CIDR)
IP Addressing Introductory material. An entire module devoted to IP addresses.
G64INC Introduction to Network Communications Ho Sooi Hock Internet Protocol.
IPv4 Addresses. Internet Protocol: Which version? There are currently two versions of the Internet Protocol in use for the Internet IPv4 (IP Version 4)
IP ADDRESSES. C ONTENTS Objectives Introduction IP Versions IPv4 Addressing Classful Addressing Class A Class B Class C Other Classes Dotted Decimal Notation.
ES 101. Module 2 IP Addressing & Routing. Last Lecture Wide area networking Definition of “packets”
Efficient Addressing Outline Addressing Subnetting Supernetting CS 640.
Chapter 18 IP: Internet Protocol Addresses
Chapter 4, slide: 1 CS 372 – introduction to computer networks* Friday July 23, 2010 Announcements: r Midterms are graded. r Lab 4 is posted. Acknowledgement:
19.1 Chapter 19 Network Layer: Logical Addressing Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display.
IP ADDRESSING, SUBNETTING & VLSM 1. Decimal vs. Binary Numbers – Decimal numbers are represented by the numbers 0 through 9. – Binary numbers are represented.
Universal Identifier UNIVERSAL IDENTIFIER Universal network = globally accepted method for identifying each computer. Host identifier = host is identify.
1 Network Layer Lecture 15 Imran Ahmed University of Management & Technology.
Chapter 4 Objectives Upon completion you will be able to: Classful Internet Addressing Understand IPv4 addresses and classes Identify the class of an.
Layer 3: Internet Protocol.  Content IP Address within the IP Header. IP Address Classes. Subnetting and Creating a Subnet. Network Layer and Path Determination.
IP1 The Underlying Technologies. What is inside the Internet? Or What are the key underlying technologies that make it work so successfully? –Packet Switching.
Routing and Addressing
Classful Internet Addresses Chapter 4. Universal Identifiers Designers of TCP/IP determined that each host on the internet would have a 32-bit identifier.
21-IP addressing Dr. John P. Abraham Professor UTPA.
Data Communications and Computer Networks Chapter 4 CS 3830 Lecture 19 Omar Meqdadi Department of Computer Science and Software Engineering University.
CCNA Discovery Semester 3 Addressing in an Enterprise Network Chapter 4 K. Martin.
Chapter 8: IP Addressing
Q and A, Ch. 21 IS333, Spring 2016 Victor Norman.
Introduction to Internetworking. 2 The IP Addressing Scheme (IPv4) (psu.edu) Dotted Decimal Notation: A notation more convenient for humans.
COMPUTER NETWORKS CS610 Lecture-26 Hammad Khalid Khan.
TCP/IP Addressing and Subnetting. IP Addressing Roadmap Format of IP Addresses Traditional Class Networks Network Masks Subnetting Supernetting Special.
IP Addressing. A 32-bit logical naming convention A dotted-decimal notation is used: – –Each number represents 8 bits. Number is Part.
IP – Subnetting and CIDR
IP Addressing and Subnetting
LESSON Networking Fundamentals Understand IPv4.
Scaling the Network: Subnetting and Other Protocols
Network Layer: IP Addressing
Internet Networking recitation #1
4 Network Layer Part I Computer Networks Tutun Juhana
CS4470 Computer Networking Protocols
CS4470 Computer Networking Protocols
Objective: Classful Internet Addressing
IPv4 Addresses.
Dr. John P. Abraham Professor UTPA
Dr. John P. Abraham Professor UTRGV
Scaling the Network: Subnetting and Other Protocols
Dr. John P. Abraham Professor UTPA
Layering and the TCP/IP protocol Suite
Presentation transcript:

CS470 Computer Networking Protocols 4/26/2017 CS470 Computer Networking Protocols 6. IP Addressing Huiping Guo Department of Computer Science California State University, Los Angeles

Outline IP addresses Subnetting 5. IP addressing CS470_W12

TCP/IP Addresses Addressing in TCP/IP is specified by the Internet Protocol (IP) Each host is assigned a 32-bit number Called the IP address or Internet address Unique across entire Internet Each IP address is divided into a prefix and a suffix Prefix identifies network to which computer is attached No two networks can be assigned the same network number Suffix identifies computer within that network No two computers on the same network can have the same suffix, but computers on different networks can have the same suffix Address format makes routing efficient 5. IP addressing CS470_W12

Properties of IP Addresses Network numbers (prefix) are unique Assignment of network numbers must be coordinated globally to ensure uniqueness Assigned by ICANN: Internet Corporation of Assigned Names and Numbers Host addresses (suffix) may be reused on different networks combination of network number prefix and host address suffix will be unique assignment of host addresses can be managed locally 5. IP addressing CS470_W12

Designing IP IP designers chose 32-bit addresses Still 32 bits in IP version 4 used today May cause a problem soon, not a large enough address space! Allocate some bits for prefix, some for suffix Large prefix, small suffix - many networks, few hosts per network Small prefix, large suffix - few networks, many hosts per network Because of variety of technologies, need to allow for both large and small networks 5. IP addressing CS470_W12

Classful Addressing Designers chose a compromise - multiple address formats that allow both large and small prefixes Each format is called an address class Class of an address is identified by first four bits 5. IP addressing CS470_W12

Address Classes Class A, B and C are primary classes Used for ordinary host addressing Owner of a class is assigned a prefix, gets to pick what machines they want in the suffix Classes A and B are all allocated! Class D is used for multicast, a limited form of broadcast Class E is reserved for future use 5. IP addressing CS470_W12

Compute the Class of an Address IP needs to separate the destination address into a prefix and suffix when it handles a packet Look at first dotted decimal number, and use this table: Just a little binary number conversion based on first 4 bits 5. IP addressing CS470_W12

Division of the Address Space Classing scheme does not yield equal number of networks in each class Class A: First bit must be 0 7 remaining bits identify Class A net 27 (= 128) possible class A nets For the rest: 5. IP addressing CS470_W12

Classful Addressing Example Organization with four networks, completely private network Assign Class A,B,C addresses as appropriate for number of hosts on each network 5. IP addressing CS470_W12

Limitations of the classful addressing scheme The IP address space is being exhausted All networks had to choose one of the three possible sizes, many addresses were wasted. Ex. A company requests a network address with a block of 1000 host address Has to get a class B address 216-1000 addresses are unused 5. IP addressing CS470_W12

Subnet and Classless Addressing Mechanisms to overcome the limitations Subnetting and Classless Addressing Take a single IP network number and allocate the IP addresses with that network number to several physical networks, which are referred to as subnets The postfix of the IP address is further divided into two parts: subnet id and host address Each subnet is assigned a subnet number All host in the same subnet share the same subnet number The network number and the subnet number now become the new network prefix 5. IP addressing CS470_W12

Subnet masks Classless and subnet addressing requires an additional piece of information stored with each address Known as address masks or subnet masks Used to specify the boundary between the network prefix and the host prefix 1 bits mark the network prefix 0 bits mark the host portion Default subnet mask: Class A: 255.0.0.0 Class B: 255.255.0.0 Class C: 255.255.255.0 5. IP addressing CS470_W12

Example We want to share a single class B address among several physical networks (subnets) We can use a subnet mask of 255.255.255.0 Top 24 bits are now defined to be the network number Lower 8 bits are the host number Since the top 16 bits identify the network in a class B address, there are 3 parts in the IP address: a network part, a subnet part and a host part 5. IP addressing CS470_W12

Subnetting example 5. IP addressing CS470_W12

Subnets and Subnet Masks Each host is configured with both an IP address and a subnet mask for the subnet to which it’s attached The bitwise AND of the two numbers defines the subnet number of the host and of all other hosts on the same subnet Eg: At H1, 128.96.34.15 AND 255.255.255.128 = 128.96.34.0 How will hosts use the subnet mask? A host: decides whether a destinations address in a packet is local or not When sending to a destination IP address, perform bitwise AND between the destination IP address and its own subnet mask If the result equals the subnet number of the sender, then it knows that the destination host is on the same subnet Otherwise, the packet needs to be sent to a router to be forwarded to another subnet. 5. IP addressing CS470_W12

Routers and subnets For simple IP, a router has a forwarding table that consists of entries of the form (networkNumber, NextHop) To support subnetting, the table now hold entries of the form Subnet number Subnet mask Next hop 128.96.34.0 255.255.255.128 Interface 0 128.96.34.128 Interface 1 128.96.33.0 255.255.255.0 Interface 2 5. IP addressing CS470_W12

Data forwarding algorithm D = destination IP address For each forwarding table entry(subnetNumber, subnetMask, nextHop) D1 = SubnetMask & D If D1 = subnetNumber, deliver datagram to nextHop (a router or a network) 5. IP addressing CS470_W12

What’s a subnet ? Another name of physical network 223.1.1.1 223.1.1.2 223.1.1.3 223.1.1.4 223.1.2.9 223.1.2.2 223.1.2.1 223.1.3.2 223.1.3.1 223.1.3.27 network consisting of 3 subnets subnet Another name of physical network A subnet is a collection of machines that can communicate with each other without the need for routing Every subnet has at least one router/gateway. If it didn’t, then the subnet couldn’t talk to any machines outside of its network. 5. IP addressing CS470_W12

Subnets Recipe To determine the subnets, detach each interface from its router, creating islands of isolated networks. Each isolated network is a subnet. 5. IP addressing CS470_W12

Subnets How many subnets? 6! 223.1.2.1 223.1.1.2 223.1.1.1 223.1.1.3 223.1.1.4 223.1.2.2 223.1.2.6 223.1.3.2 223.1.3.1 223.1.3.27 223.1.7.0 223.1.7.1 223.1.8.0 223.1.8.1 223.1.9.1 223.1.9.2 Subnets How many subnets? 6! 5. IP addressing CS470_W12

CIDR Notation CIDR = Classless Inter-Domain Routing Notation for classless addresses Specifies the mask associated with an address Appends a slash to the address with the size of the mask in decimal Examples: 128.10.0.0/16 says 16 bit prefix, 16 bit suffix (Class B) 128.211.0.16/28 28 bit prefix, 4 bit suffix 5. IP addressing CS470_W12

CIDR Example 1 5. IP addressing CS470_W12

Reserved Addresses RFC 1597 – Address Allocation for Private networks The following blocks are reserved for private networks 10.0.0.0 - 10.255.255.255 Class A 172.16.0.0 - 172.31.255.255 Class B 192.168.0.0 - 192.168.255.255 Class C We’ll need a gateway to translate from these addresses to the Internet addresses Network Address Translation We should never see a machine on the Internet with one of these network prefixes (hopefully) 5. IP addressing CS470_W12

Special IP Addresses Network Address Directed Broadcast Address The network itself is assigned an address So no host can have all zero’s as its IP address suffix Prefix is the network prefix, suffix is all zero’s Eg. 128.211.0.0/16 Directed Broadcast Address Broadcast message to a network Prefix is the network prefix, suffix is all one’s So no host can have all one’s as its IP address suffix Limited Broadcast Address Broadcast on the local LAN Entire address is all 1’s, i.e. 255.255.255.255 5. IP addressing CS470_W12

More Special IP Addresses This Computer Address To obtain an address automatically when booting, we may use IP to communicate… but we don’t have a correct IP address yet Use an address of all zero’s to indicate “this computer” Loopback Address Any address beginning with 127 indicates the local computer E.g. 127.0.0.1 most common, but could be 127.0.44.53 Use for testing network applications, no packets leave the computer 5. IP addressing CS470_W12

Special Address Summary 5. IP addressing CS470_W12

Subnetting Subnetting is the division of a single network into smaller subnets. Each subnet functions as if it were an independent network As far as entries in the routing table are concerned All subnets of a given network number use the same network-prefix but different subnet numbers. 5. IP addressing CS470_W12

Why are subnets created? Provides greater organization of large networks. Remember: a Class A network can have up to 16 million hosts. It allows you to have additional networks without applying for more IP addresses. Decreases broadcast traffic by reducing broadcast domain size. Broadcasts are not forwarded out of a subnet. 5. IP addressing CS470_W12

How to subnet a network? Borrow bits from the host field of an IP address. All the subnets have the same network prefix Subnets are only visible to routers inside the network Netid subnetid hostid 16 24 31 5. IP addressing CS470_W12

Subnet a network: steps Determine the number of subnets How many bits to be borrowed? For each subnet, determine The network address subnet bits cannot be all on or off at the same time The host address range The broadcast address Determine the number of required host per subnet: One for each host One for each router interface 5. IP addressing CS470_W12

Subnetting example 1: You are assigned a network address 214.97.254/23. You want to create 2 subnets. What are the network addresses and broadcast addresses of the 2 subnets? What are the address range in the 2 subnets? 5. IP addressing CS470_W12

Subnetting example 1: 11010110 01100001 11111110 0 000 0000 Subnet 1: 23 Subnet bits 11010110 01100001   11111110  0 000 0000 Subnet 1: Network address: 11010110 01100001   11111110  1000 0000/25 Broadcast address: 11010110 01100001   11111110  1111 1111/25 Address range: 11010110 01100001   11111110  1000 0001/25 11010110 01100001   11111110  1111 1110/25 126 IP addresses 5. IP addressing CS470_W12

Subnetting example 1: Subnet 2: Network address: 11010110 01100001   11111111  0000 0000/25 Broadcast address: 11010110 01100001   11111111  0111 1111/25 Address range: 11010110 01100001   11111111  0000 0001/25 11010110 01100001   11111111  0111 1110/25 126 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: You are assigned a network address 214.97.254/23. If you assign 3 bits to the subnets. How many subnets can be created What are the network addresses and broadcast addresses of the subnets? What are the address range of the subnets? 5. IP addressing CS470_W12

Subnetting example 2: 23 Subnet bits 11010110 01100001   11111110  0000 0000 The number of subnets: 23-2=6 Subnet 1: Network address: 11010110 01100001   11111110  0100 0000/26 Broadcast address: 11010110 01100001   11111110 0111 1111/26 Address range: 11010110 01100001   11111110  0100 0001/26 11010110 01100001   11111110  0111 1110/26 26-2=62 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: Subnet 2: Network address: 11010110 01100001   11111110  1000 0000/26 Broadcast address: 11010110 01100001   11111110 1011 1111 Address range: 11010110 01100001   11111110  1000 0001 11010110 01100001   11111110  1011 1110 26-2=62 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: Subnet 3: Network address: 11010110 01100001   11111110  1100 0000/26 Broadcast address: 11010110 01100001   11111110 1111 1111 Address range: 11010110 01100001   11111110  1100 0001 11010110 01100001   11111110  1111 1110 26-2=62 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: Subnet 4: Network address: 11010110 01100001   11111111  0000 0000/26 Broadcast address: 11010110 01100001   11111111  0011 1111 Address range: 11010110 01100001   11111111  0000 0001 11010110 01100001   11111111  0011 1110 26-2=62 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: Subnet 5: Network address: 11010110 01100001   11111111  0100 0000/26 Broadcast address: 11010110 01100001   11111111  0111 1111 Address range: 11010110 01100001   11111111  0100 0001 11010110 01100001   11111111  0111 1110 26-2=62 IP addresses 5. IP addressing CS470_W12

Subnetting example 2: Subnet 6: Network address: 11010110 01100001   11111111  1000 0000/26 Broadcast address: 11010110 01100001   11111111  1011 1111 Address range: 11010110 01100001   11111111  1000 0001 11010110 01100001   11111111  1011 1110 26-2=62 IP addresses 5. IP addressing CS470_W12