Data Communications (SEE5523) - Chap.8a1/24 SET5534 Data Communication and Switching System Chapter 8 IP Addressing Alias Mohd FKE, UTM
Data Communications (SEE5523) - Chap.8a2/24 Objectives Understand the concept of IP addressing. Understand how to create subnet.
Data Communications (SEE5523) - Chap.8a3/24 Host, IP and MAC Address Host name – IP address – (32 bits) MAC address (physical address)-NIC address –00:02:a5:b7:66:ec (48 bits)
Data Communications (SEE5523) - Chap.8a4/24 Level of Addressesing DNS (domain name system) Address Resolution Protocol (ARP) RARP 00:02:a5:b7:66:ec
Data Communications (SEE5523) - Chap.8a5/24 IP addresses in a network IP addresses are associated with interface –Each interface has its own address –A station can has more IP addresses –e.g router, server, etc.
Data Communications (SEE5523) - Chap.8a6/24 IP addressing concept Partitioned into 2 parts –Network address –Node address NetworkNode ,2, ,2, ,2
Data Communications (SEE5523) - Chap.8a7/24 IP addresssing NetworkHost 8 bits 32 bits
Data Communications (SEE5523) - Chap.8a8/24 IP address class 32 bits –Network identifier –Node identifier Class A Class B Class C Class D Class E 0 Network ID Host ID 110Network IDHost ID 10Network IDHost ID 1110Multicast Address 11110Unused
Data Communications (SEE5523) - Chap.8a9/24 IP Address Table classInitial bits # bits for net # bits for host rangeAddress spaces usable A – ^24 = B – ^16 = C – ^8= D – E –
Data Communications (SEE5523) - Chap.8a10/24 Special Address Host ID with all 0s is referred to a network number – , Host ID with all 1 is reserved to broadcast address – , is reserved and means ‘this host on this network” –Used to boot diskless WS is reserved to broadcast to every host in the local network 127.x.x.x means ‘this node’ (local loopback).
Data Communications (SEE5523) - Chap.8a11/24 Problem with class assignment Class A takes 50% range Class B takes 25% Class C takes 12.5% These lead to: –Address wasteful (especially in class A) –Not enough IP addresses
How many nets and hosts?
Data Communications (SEE5523) - Chap.8a13/24 Problem with large network Class B flat network will have mre tha hosts –How to manage? –Performance? Subdivide class B network into smaller group (subnetwork) with router
Data Communications (SEE5523) - Chap.8a14/24 Subnetwork benefits Ease the network manager control over the address space Easy to allocate the addresses Better network performance Hide routing structure from remote routers, thus reducing routes in their routing tables
Subnets 65,534 hosts … … 254 hosts … 254 subnets one class B address
Data Communications (SEE5523) - Chap.8a16/24 Assigning Subnetwork (Subnet) Divide host ID into 2 –Subnet address & host address Class B address ( ) can use its 3 rd byte to identify subnet –Subnet #1 – x –Subnet #2 – x –x is host ID from Network IDSubnet addr.Host addr. Host ID
Data Communications (SEE5523) - Chap.8a17/24 Subnet Mask (1/2) 32 bit number –Tells router to recognize the subnet field The bits covering network and subnet part of an address are set to ‘1’ –E.g. class B with 24 bit mask –Subnet mask = Zero bits are used to mask ot the host number resulting only the network address
Data Communications (SEE5523) - Chap.8a18/24 Subnet Mask (2/2) Subnet mask of for a class B tells: –Network has been partition to 254 subnets e.g x to x –Logical AND between IP address with mask yields network address AND = (network address) AND = (network address)
Data Communications (SEE5523) - Chap.8a19/24 Subnet Mask bits #
Network prefix The class ID plus network ID portions of the IP address are known as the network prefix –class A: an 8-bit network prefix (/8) –class B: a 16-bit network prefix (/16) –class C: a 24-bit network prefix (/24)
Data Communications (SEE5523) - Chap.8a21/24 Subnetting Class B ( ) –0 subnet with hosts (default subnet) ( ) –4 subnets with hosts each ( ) –64 subnets with 1022 hosts each ( ) –256 subnets with 254 hosts each ( ) –16384 subnets with 2 hosts each
Data Communications (SEE5523) - Chap.8a22/24 Example (1/2) Given IP address x.x, find out the following to have at least 500 hosts per subnet –Subnet mask –Start network ID –End network ID –Number of subnet possible
Data Communications (SEE5523) - Chap.8a23/24 Example (2/2) Given IP address x, find out the following to have at least 5 subnet –Subnet mask –Start network ID –End network ID –Number of subnet possible
Data Communications (SEE5523) - Chap.8a24/24 Subnetting Class C ( ) –0 subnet with 254 hosts (default subnet) ( ) –4 subnets with 62 hosts each ( ) –8 subnets with 30 hosts each ( ) –16 subnets with 14 hosts each
Data Communications (SEE5523) - Chap.8a25/24 Class B Subnet with router
Data Communications (SEE5523) - Chap.8a26/24 Subnet Routing Traffic is routed by looking at ‘bit-wise AND’ results { if dest IP addr & subnet mask==my IP addr & subnet mask send packet to local network else send packet to router%dest IP is on different subnet }
Data Communications (SEE5523) - Chap.8a27/28 Subnet Results IP address Subnet maskResult host 71 on subnet host 3 on subnet host 4 on subnet host 2 on subnet
Private addressing (1/2) IP address depletion has resulted –from the explosion of the Internet –the inefficient use of existing IP addresses One way to cope with the depletion of IP addresses is through the use of private addressing –IP addresses used on the Internet must be globally unique, usually specified by an Internet service provider. –However, traffic that remains only on an organization's private network does not need to be globally unique just unique across that organization's private network.
Private addressing (2/2) In support of this, the Internet Assigned Numbers Authority (IANA) has set aside the following three ranges of private IP addresses: – through (equal to a single Class A Network ID) – through (equal to 16 contiguous Class B Network IDs) – through (equal to 256 contiguous Class C Network IDs) Traffic using any of these address ranges must remain on the organization's private network and cannot be forwarded on the Internet
DHCP DHCP works by providing a process for a server to allocate the IP information to clients. Clients lease the information from the server for an administratively defined period.
31 DHCP (cont…) Runs over UDP using port 67 (client) and 68 (server) Provides automatic configuration of the host connected to network or booted Provides hosts with initial configuration information upon boot-up: –IP address with subnet mask, –default gateway, –IP address of the DNS server.
The Order of DHCP Message Transmission
DHCP Interaction Automatic Allocation Manual Allocation Dynamic Allocation
34 DHCP Interaction (simplified)
IP address assigned by DHCP Data Communications (SEE5523) - Chap.8a35/24
Thursday, May 17, Design Goals of DHCP Eliminate manual configuration of hosts Prevent use of any IP address by more than one host Provide the same configuration - including IP address, subnet mask - to a host whenever possible Move desktop PCs between offices/location Mobile IP - laptop