DOC HOME SITE MAP MAN PAGES GNU INFO SEARCH PRINT BOOK
 
Introducing the Internet protocols

Internet Protocol version 4 (IPv4)

The Internet Protocol (IP) provides unreliable, connectionless packet delivery. IP is connectionless because it treats each packet of information independently. It is unreliable because it does not guarantee delivery. That is, it does not require acknowledgments from the sending host, the receiving host, or intermediate hosts.

An IP datagram consists of a header to which is appended a segment or packet from a higher layer transport protocol. The format of an IPv4 header is illustrated in ``IPv4 header format''.

IPv4 header format

An IPv4 header contains the following fields:


version
The IP version number, 4.

length
The length of the datagram header in 32-bit words.

type of service
Contains five subfields that specify the precedence, delay, throughput, reliability, and cost desired for a packet. (The Internet does not guarantee this request.) This field is not widely used on the Internet.

total length
The length of the datagram in bytes including the header, options, and the appended transport protocol segment or packet.

identification
An integer that identifies the datagram.

flags
Controls datagram fragmentation together with the identification field. The flags indicate whether the datagram may be fragmented, whether the datagram is fragmented, and whether the current fragment is the final one.

fragment offset
The relative position of this fragment measured from the beginning of the original datagram in units of 8 bytes.

time to live
How many routers a datagram can pass through. Each router decrements this value by 1 until it reaches 0 when the datagram is discarded. This keeps misrouted datagrams from remaining on the Internet forever.

protocol
The high-level protocol type.

header checksum
A number that is computed to ensure the integrity of the header values.

source address
The 32-bit IPv4 address of the sending host.

destination address
The 32-bit IPv4 address of the receiving host.

options
A list of optional specifications for security restrictions, route recording, and source routing. Not every datagram specifies an options field.

padding
Null bytes which are added to make the header length an integral multiple of 32 bytes as required by the header length field.

IPv4 address notation

A TCP/IP network routes a packet according to the destination IP address, an address provided by the IP protocol on the sending host. IPv4 addresses are 32-bit numbers that uniquely identify every host computer connected to the Internet. This 32-bit address is typically represented as four decimal numbers separated by dots, for example:

   202.16.208.51
The network address (the part of the address that identifies your network) and the host address (the part that identifies an individual host on your network) must all fit into this 32-bit number. The number of hosts you can configure for your network decreases as the length of the portion occupied by the network address increases.

Network address

The network address is the leading portion of the IPv4 address for every host in the network you manage. The network address identifies part of a total IPv4 address as the network, and leaves the rest of the IPv4 address to identify a particular host on that network.

The Network Information Centers or NICs (including the original InterNIC) assign network addresses for the IPv4-based Internet. As different organizations usually manage different numbers of hosts, an NIC traditionally assigned a network ID belonging to one of the three classes, A, B or C, based on how many hosts were expected to be connected to the network. Each class uses progressively more of the IPv4 address to identify the network, and therefore leaves you with fewer numbers to uniquely identify your hosts. See ``IP address'' for a table of the address classes and reserved address ranges.

Unless your organization has many host systems and needs a large address space, you will usually obtain your network address indirectly from an Internet Service Provider (ISP) or from an Internet Registry (IR) rather than directly from an NIC. The extent of the network address space that you are assigned is now specified by a CIDR-style prefix followed by a trailing slash (/) and number of bits. For example, the network address ``202.16.208/24'' would allow space for up to 254 hosts on what would traditionally have been termed a class C network. See ``Subnetting and Classless Interdomain Routing'' for more information.

Host address

The host address is the trailing portion of an IPv4 address that uniquely identifies a host within your network. A host address cannot be all binary 0's or 1's. The numbers available to use as host addresses depend on the class of your network (see ``Network address'') or the length of its CIDR prefix (see ``Subnetting and Classless Interdomain Routing''), and whether you are further subnetting the network (see ``Subnet address'').

Subnet address

If you have more than one physical network within your organization but only one network address, you can turn part of the host portion of your address space into several subnet addresses. This is usually called ``subnetworking'' or ``subnetting''.


NOTE: You have complete control over how you assign subnet addresses to your networks and how you handle routing between them, in much the same way as you are wholly responsible for any subdomains that you create below your registered DNS domain name. The NICs and other registration bodies have no authority over such matters.

See ``Setting up subnets'' for more information about subnetting. You can also use the Subnet Calculator to work out how to partition your network into subnets.


© 2002 Caldera International, Inc. All rights reserved.
UnixWare 7 Release 7.1.3 - 30 October 2002