Internet Protocol

Download Report

Transcript Internet Protocol

Internet Protocol
Internetworking Lab I
Internet Protocol - IP
• Internet
– Collection of networks
Internet
Slow speed
network
Receiving
Host
High speed
network
Sending
Host
Gateway
Congestion in Internet – Case 1
Internet Protocol - IP
• Internet
– Collection of networks
Token
Ring
Ethernet
Router
Router
Pt-to-pt
Star
Token
Ring
Ring
Star
Bus
Network
Ethernet
Internet Protocol - IP
• Mac Addresses are specific to Ethernet devices
• Other technologies use different kinds of physical
addresses
• As a result, MAC addresses do not suffice for
addressing on an internet
• ALSO
MAC addresses carry no information about the
location of a device
do not help in the routing of frames
Internet Protocol - IP
• Goal
– Single seamless communication system
– HIDE details of the physical network
• Required
– Layer providing transparency from underlying
• Network
• Protocols
– Forward packet from network to network
– Addressing to recognize location of network
Internet Protocol - IP
• Uniformity
– Across technologies
– Across different network topologies
• To communicate across networks
– without knowing hardware address
• Solution
– IP layer
– IP addressing
IP Addresses
32 bits or 4 bytes
dotted quad notation: 129.21.21.3
each number is in the range 0…255
each fits precisely into 1 byte (8 bits)
Two parts
network id and host id
two “dimensions” help in routing packets on the
network
Classes of IP Addresses
Class A
network id is 1st byte of the dotted quad
host id is the remaining 3 bytes
Class B
network id is 1st two bytes
host id is remaining two bytes
Class C
network id is 1st three bytes
host id is remaining byte
Classes D and E - special cases
Classes of IP Addresses
Classes of IP Addresses
CLASS
Range of Values
A
0-127
B
128-191
C
192-223
D
224-239
E
240-255
Classes of IP Addresses
Address Bits in Max # of Bits in Max # of
Class Prefix Networks Suffix Hosts/net
A
7
128
24
16777216
B
14
16384
16
65536
C
21
2097152
8
256
Classes of IP Addresses
Prefix
Suffix Type of Addr
Purpose
All-0s All-0s This computer Used during
Network All-0s Network
bootstrap
Identifies a network
Network All-1s Directed broadcast Broadcast to a
All-1s All-1s
127
Any
specific network
Limited broadcast Broadcast to local
net
Testing
Loopback
IP Addresses
The network mask (subnet mask)
where there are 1’s indicates the network ID
where there are 0’s indicates the host ID
Examples
for a class A address: 255.0.0.0
for a class B address: 255.255.0.0
for a class C address: 255.255.255.0
IP delivery
• Unreliable - delivery not guaranteed
• Connectionless -packet independence
• Best Effort Delivery - only discard for a
reason
• Fragmentation
IP delivery
• Unreliable - delivery not guaranteed
• Connectionless -packet independence
• Best Effort Delivery - only discard for a
reason
• Fragmentation
IP delivery
• Version field - 4bits
– the current version of IP is 4 (IPv4)
• Hlen field - 4bits
– specifies the length of the header
• TOS (type of service) field - 8 bits
– how packet should be handled
– not widely used
• Length field - 16 - measured in octets
– specifies the length of the datagram
IP delivery
• Identification
– used to determine which fragments belong to each other
• Flag
– indicates how the fragmentation process will be
handled
• Fragment offset
– indicates where a fragment belongs in the complete
message
IP delivery
• TTL (time to live) field
– more of a hop count rather than a timer
• Protocol field
– identifies the higher-level protocol
• Checksum field
– checks an error in the header
• Source and Destination addresses
IP delivery
• TTL (time to live) field
– more of a hop count rather than a timer
• Protocol field
– identifies the higher-level protocol
• Checksum field
– checks an error in the header
• Source and Destination addresses