6.7 Ipv4 Datagram: Presented By: Shubhangi Desai
6.7 Ipv4 Datagram: Presented By: Shubhangi Desai
7 IPv4 DATAGRAM
Datagram
Data in the Datagram
Header
IP Datagram
Frame
Complete Datagram treated as data
Header
MAC Frame
Datagram Format
Version
Size : 4 bits
Identifies the version of IP used to generate the
datagram
For IPv4, this is of course the number 4
The purpose of this field is to ensure compatibility
between devices that may be running different versions
of IP
A device running an older version of IP will reject
datagram created by newer implementations,
Header Length
Size : 4 bits
Specifies the length of the IP header, in 32-bit words
Includes the length of any options fields and padding.
The normal value of this field when no options are
used is 5 (5 32-bit words = 5*4 = 20 bytes or octats)
Type of Service (TOS)
TOS describes how the packet should be handled in
transit in terms of speed v/s reliability v/s throughput
Precedence : Specifies
importance of datagram
(also known as code points)
0 1 2 3 4 5 6
7
Delay : Set to 1 – low delay
Throughput: Set to 1 – high throughput
Reliability: Set to 1 – high reliability
Total Length
Size: 16 bits (2 bytes)
Specifies the total length of the IP datagram, in bytes
This field is 16 bits wide, the maximum length of an IP
datagram is 65,535 bytes
Identification
Size: 16 bits (2 bytes)
Uniquely identifies the datagram
Usually incremented by 1 each time a datagram is sent.
All fragments of a datagram contain the same
identification value.
This allows the destination host to determine which
fragment belongs to which datagram
IP Fragmentation - Encapsulation
When a host or router handles a datagram, the IP software
determines the next hop to which the datagram should be sent.