Upload
marcus-reeves
View
213
Download
0
Embed Size (px)
Citation preview
1
TCOM 509 – Internet Protocols (TCP/IP)
Lecture 02_b
Instructor: Dr. Li-Chuan ChenDate: 09/08/2003
Based in part upon slides of Prof. J. Kurose (U Mass), Prof. B. Yener (Rensselaer Polytechnic Institute)
2
Outline
Chapter 4 – Classful Internet Address Chapter 5 Chapter 6 Chapter 7
3
Flat vs. Hierarchical Addresses Flat addresses
• no structure in them to facilitate scalable routing.• e.g., Ethernet addresses
Hierarchical addresses• Network part (netid) and host part (hostid).• Helps identify direct or indirectly connected nodes.• Efficient for routers to send packets.
netid hostid
4
Internet Addresses
Classful Internet Address• Class A• Class B• Class C• Class D• Class E
Goal: Allows any computer to communicate with any other computer in a global communication network.
5
IP Address Formats
Class A netid hostid071 24 bits
netid hostid10142 16 bits
Class B:
netid hostid110213 8 bits
Class C:
Multicast Group addresses1110284 bits
Class D:
Class E: Reserved for future uses1111284 bits
6
IP Addresses IP Address
• 32-bit global internet address• Network part (netid) and host part (hostid)• Class D addresses are for multicasting (packet is
delivered to a subset of hosts).• Unicast: a packet is delivered to a single host.• Reserved addresses
– All 0 (binary 0000000) is reserved– All 1s broadcast address (limited broadcast) can be used in
start-up to get its IP address. – Loopback 127.x.x.x– hostid 0 refers to the network itself, not individual host.– hostid consist of all 1s is for directed broadcast to all hosts on
the network.
7
IP Addresses – Class A Class A – small networks with large number of
hosts.• Starts with binary 0, followed by 7-bit Network field, and
then 24-bit Host field• netid of 127 (binary 01111111) is reserved for loopback• Only 2 7 – 2 = 126 octets left, range 1.x.x.x to 126.x.x.x• Covers 50% (231) of the entire IP address space• 224 for each Class A network. Millions of Class A
addresses are wasted
netid hostid071 24 bits
8
IP Addresses - Class B
Class B – intermediate size networks.• Starts with 10, followed by 14-bit Network field, and
then 16-bit Host field• Range 128.x.x.x to 191.x.x.x• 214 = 16,384 class B addresses• Covers 25% (230) of the entire IP address space• 216 for each Class A network. Many of Class B
addresses are wasted
netid hostid10142 16 bits
9
IP Addresses - Class C Class C – large networks with small number of
hosts.• Starts with 110, followed by 21-bit Network field, and
then 8-bit Host field• Range 192.x.x.x to 223.x.x.x• 221 = 2,097,152 networks, 28 = 256 hosts in each
network• Covers 12.5% (229) of the entire IP address space
netid hostid110213 8 bits
10
IP Addresses - Class D, E Class D – Multicasting
• Starts with 1110, followed by 28-bit multicast group address.• 228 multicast groups• Covers 6.25% (228) of the entire IP address space
Multicast Group addresses1110284 bits
Class E – Reserved• Starts with 1111, followed by 28-bit multicast group address.• Covers 6.25% (228) of the entire IP address space
Reserved for future uses1111284 bits
11
Dotted Decimal Notation IP address (32 bits) can be written as four
decimal integers separated by decimal points.
IP address is divided into 4 parts, convert each part from binary to its equivalent decimal integer.
Example Binary: 10000000 000001010 00000010 00011110
Dotted Decimal: 128.10.2.30
12
IP Addressing 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
Hosts in the same network have same network ID
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.2223.1.3.1
223.1.3.27
223.1.1.1 = 11011111 00000001 00000001 00000001
223 1 11
13
IP Address
Class Range
A 0 - 127
B 128 - 191
C 192 - 223
D 224 - 239
E 240 - 255
Lowest Address
Highest Address
1.0.0.0 126.0.0.0
128.1.0.0 191.255.0.0
192.0.1.0 223.255.255.0
224.0.0.0 239.255.255.255
240.0.0.0 255.255.255.254
Some values are reserved.
14
Reserved Addresses Loopback: test for inter-process communication
on the local host. Hostid “this” (0s), “all” (1s)
All 0s Host
Network All 1s
All 0s
All 1s
127 anything
This host
Host on this network
Limited broadcast
Directed broadcast
Loopback
15
IP Addresses - ConsIP Address Cons: IP address is associated with network connection, not to
the host. Difficult and time consuming to change network
addresses. e.g., when class C network grows to > 255 (28) hosts.
If a host has multiple addresses (multi-homed host), knowing one address may not be sufficient to reach it when this particular path to that address is down.
Nearly all allocated• Need next-generation IP protocol - IPv6
16
Subnet and Supernet Extensions Classful addressing inefficient: Everyone wants
class B addresses Can we split class A, B addresses spaces and
accommodate more networks ?• Need another level of hierarchy. Defined by subnet
mask, specifies the sets of bits belonging to the network address and host address respectively .
Supernetting or classless addressing allows prefix and suffix to occur at an arbitrary point.
Network Host
Boundary is flexible, will cover in details later
17
Network Byte Order Use standard byte ordering (Big Endian) within protocol
fields so all hosts interpret the IP addresses the same way.
Big Endian: integers are sent with the most significant byte first.
Little Endian: integers are sent with the least significant byte first.
18
Chapter 4 Summary• IP address uses 32-bit binary number.• Unique IP address per interface.• Provision for broadcast, multicast, loopback
addresses.• Classful (A,B,C) address allocation not efficient.• Hierarchical addresses are more efficient with
smaller routing tables.• Extended address scheme: subnet and supernet
addressing improved address allocation efficiency (cover later).
19
Homework 1Chapters Problems
2 7
4 1, 7
Due Monday 09/15/2003