TCP/IP stands for Transmission Control Protocol/Internet Protocol.
|
It was developed for the US Department of Defense to allow communication between different types of computers and networks.
|
Later, TCP/IP was included with the Berkeley software distribution of UNIX.
|
TCP/IP is a widely used networking protocol.
|
Most large networks rely on TCP/IP for much of their network traffic, and all modern network operating systems support it.
|
TCP and IP are the two best known protocols in the suite.
|
The Transmission Control Protocol (TCP) provides reliable sequence delivery of packets between clients.
|
The Internet Protocol (IP) provides packet delivery between hosts.
|
The Defense Advanced Research Project Agency (DARPA) developed the TCP/IP suite of protocols to allow communication between networks of different computers.
|
It implemented a network called the ARPAnet, which later evolved into the Internet.
|
You can use TCP/IP to build private and public internetworks.
|
Suppose your organization had several offices, each with a local area network (LAN).
|
You could use TCP/IP to build a private internetwork that connects all the LANs.
@@
TCP/IP has a number of features which make it a very robust protocol.
|
First, the network works even if part of the network fails.
|
A TCP/IP network can handle high error rates by retransmitting and rerouting lost or corrupted data.
|
TCP/IP is ^Rscalable^r, which means^R ^ryou can add new subnetworks, and you can do this without disrupting the existing network service.
|
TCP/IP network architecture works with most kinds of networks, making it independent of vendor or network type.
|
Its network protocols have as little data overhead as possible to ensure optimum performance.
|
TCP/IP is ^Rroutable^r.
|
A routable protocol gives the internetwork administrator greater flexibility, particularly when it comes to wide area networks.
|
Routability allows you to configure devices on an internetwork so that you can specify the routes that traffic flows along.
|
This provides extra security and allows available bandwidth to be used more efficiently.
@@
A network implemented with the TCP/IP suite of protocols is a packet-switched network.
|
A packet-switched network transmits information across the network in small segments, called packets.
|
The TCP/IP protocols define the format of packets.
|
The packet format specifies the

• origin and destination of the packet
|
• the type of packet
|
• the way packets are acted upon
@@
The protocols in the TCP/IP suite map closely to the OSI model.
|
The OSI model describes an ideal computer network.
|
In this network system communication takes place between processes at each layer of the model.
|
Applications developed for TCP/IP generally use several of the protocols in the suite.
|
The layers in the protocol suite are collectively known as the protocol stack.
|
Each protocol layer within the TCP/IP protocol stack performs certain functions, which are independent of the other layers.
|
Each layer expects services from the layer beneath it, and each layer provides services to the layer above it.
@@
The OSI network layer corresponds to TCP/IP's Internet layer.
|
This layer provides connectivity and path selection between interconnected networks.
|
Several TCP/IP protocols operate in this layer:

• IP
|
• ICMP
|
• ARP
|
• RARP
|
The Internet Protocol (IP) is the fundamental protocol in the suite.
|
IP provides no error checking or reliability, but simply transports data in packet format across the internetwork.
|
Reliability is provided by higher level protocols, such as the Transmission Control Protocol (TCP).
|
IP provides connectionless, best-effort delivery routing of datagrams.
|
A connectionless delivery service means that no physical wire or path connecting the source address and the destination address has been selected.

A connection-based delivery service requires a physical wire route, connecting the source address and the destination address, to be established before data is sent.

TCP provides a connection-based and therefore reliable delivery service.
|
In other words, IP packets are not guaranteed to arrive at their destination.
|
Nor are they guaranteed to be received in the sequence in which they were sent.
|
The integrity and sequence of the data contained within the IP packet can be ensured only by using higher-level protocols.
|
This is because the IP Checksum only checks the Header field for errors and not the Data field.
|
IP defines the form that packets must take and the ways to handle packets when they are transmitted or received.
|
The packet format is called an IP datagram.
|
An IP datagram is similar to a frame transmitted on a network.
|
A datagram has a header section, containing various fields, including the sender and receiver IP addresses, and a data section.
|
The fields on an IP datagram include a VERS or Version field which indicates the version of IP being used.
|
HLEN or IHL IP header length indicates the datagram header length in 32-bit words.
|
Type of Service specifies how a particular upper-layer protocol would like the current datagram to be handled.
|
Total Length specifies the length of the entire IP packet including data and header in bytes.
|
Identification contains an integer that identifies the sequential number of the current datagram.
|
This field is used to help receiving devices piece together datagram fragments.
|
Flags is a three-bit field of which the low order two bits control fragmentation.
|
Fragmentation occurs when data is too large for the underlying physical network to handle.

The IP protocol divides the data among several IP packets.

These packets are numbered in sequence, so they can be reassembled in their correct sequence when they arrive at their destination address.
|
One bit specifies whether the packet can be fragmented.
|
The second bit specifies whether the packet is the last fragment in a series of fragmented packets.
|
Time to Live (TTL) maintains a counter that gradually decrements down to zero, at which point the datagram is discarded.
|
This keeps packets from looping endlessly.
|
Protocol indicates which upper-layer protocol receives incoming packets after IP processing is complete.
|
These protocols are identified  by protocol numbers.
|
Header Checksum ensures IP header integrity.
|
The Header Checksum is used to perform a calculation on the packet, but it confirms only the IP packet header's integrity.
|
It does not check the data field for errors.
|
If data is lost or corrupted during transmission, the IP protocol has no way of indicating this.
|
Source address identifies the sending node.
|
Destination address identifies the receiving node.
|
Options allows IP to support various options such as security, network testing, debugging, and others.
|
Finally, the Data field contains upper layer information.
@@
The Internet Control Message Protocol is implemented by all TCP/IP hosts.
|
ICMP messages are carried in IP datagrams and are used to send error and control messages between hosts and routers.
|
ICMP performs a number of tasks within an IP network.
|
The principal reason it was created was to report routing failures back to the source.
|
ICMP messages are sent if the host

• needs to know if another host is
  available
|
• needs to determine which
  network it is attached to
|
• needs to determine a router
  address on a subnetwork
|
• needs to notify the internetwork
  of congested or failed links
|
For example, if a router receives a packet that it is unable to deliver to its ultimate destination, the router sends an ICMP Host Unreachable message to the source.
|
The reason might be that there is no known route to the destination.
|
The information provided by ICMP messages can be used by higher-level protocols to recover from transmission problems.
|
It can also be used by network administrators to detect network trouble.
|
For example, the ping utility makes use of the ICMP echo request and echo reply packets to determine whether a particular host on a network is functional.
|
So the ping utility is useful for diagnosing IP network or router failures.
|
ICMP provides 11 types of message including Redirect messages which provide more efficient routing.
|
Time Exceeded messages inform sources that a datagram has exceeded its allocated time to exist within an internetwork.
|
Router Advertisement and Router Solicitation messages determine the addresses of routers on directly attached subnetworks.
|
They enable new nodes to discover the subnet mask currently used in an internetwork.
@@
The Address Resolution Protocol (ARP) is used to map a known IP address to a physical or MAC address, and so allow communication on a multi-access media such as Ethernet.
|
This is accomplished by sending ARP request messages and checking an ARP cache for previously used addresses.
|
IP packets contain both source and destination host IP addresses.
|
But the hardware address of the destination host must also be known.
|
IP acquires a host's hardware address by broadcasting a special inquiry packet, an ARP request packet.
|
This contains the IP address of the host with which it is attempting to communicate.
|
All of the ARP-enabled hosts on the local network detect the broadcasts.
|
And the host that owns the IP address in question replies by sending its hardware address back to the source host in an ARP reply packet.
|
In effect, the ARP maps IP addresses to hardware addresses.
|
Each time a node broadcasts an ARP request and receives a response it creates an entry in its address resolution cache.
|
This entry maps the IP address to the physical address and reduces the number of broadcast requests which must be examined by every node on the network.
|
The term Local ARP is used to describe resolving an address when both the requesting host and the destination host share the same media or wire.
|
Here the IP subnet mask was consulted prior to issuing the ARP.
|
The mask determined that the nodes are on the same subnet.
|
Subnet masks will be explained later in this course.
|
Because the sending and receiving devices are on the same subnet they need to communicate with each other using their hardware addresses.
|
So the sender uses ARP to determine the recipient's hardware (in this instance Ethernet) address.
@@
The Reverse Address Resolution Protocol (RARP) in the TCP/IP stack maps physical or MAC addresses to IP addresses.
|
Both ARP and RARP are implemented directly on top of the data-link layer.
|
RARP, like ARP, uses broadcast messages to resolve addresses.
|
But as the word "Reverse" implies, a broadcast RARP request is replied to with the sender's IP, rather than MAC, address.
|
RARP is used by devices such as diskless computers at startup, that do not know their IP addresses when they boot.
|
RARP relies on the presence of a RARP server with a table entry or other means to respond to these requests.
@@
Two protocols are provided at the transport layer in the TCP/IP protocol stack:

• TCP
|
• UDP
|
The Transmission Control Protocol (TCP) is a connection-oriented transport layer protocol that provides reliable full-duplex data transmission.
|
While IP simply routes datagrams from one part of the network to another, TCP initiates handshaking, controls packet sequencing, flow control and handles errors.
|
TCP controls setting up the connection with the destination computer and guarantees delivery of packets.
|
It sequences packets in the correct order when they arrive at their destination.
|
TCP controls the flow of packets so that the receiving computer's buffers will be able to hold the data.
|
It provides a checksum field that validates both the packet header and its data for accuracy.
|
TCP does not acknowledge corrupted or lost data and this is the signal to the sender to retransmit the data.
|
So TCP/IP is the protocol of choice for session-based data transmission, client-server applications, and critical services, such as FTP the file transfer protocol.
|
The reliability of TCP is at the expense of overheads that reduce transmission performance.
|
Additional bits are required by TCP headers to provide proper sequencing of information.
|
The Checksum field needs extra bits to ensure the reliability of both the TCP header and the packet data.
|
Acknowledgements (or ACKs) generate additional network traffic.
|
The fields of the TCP packet include Source Port and Destination Port, which identify the points at which upper-layer source and destination processes receive TCP services.
|
The Source Port field identifies the source upper-layer protocol.
|
Many widely used upper-layer applications have specific port numbers associated with them.
|
The Destination Port field also identifies an upper-layer protocol, but this time it's the destination's upper-layer protocol.
|
For example, port number 21 is the destination port number for sending data using the File Transfer Protocol (FTP).
|
The Sequence Number field specifies the first byte of data in the current message.
|
Under certain circumstances it can be used to identify an initial sequence number to be used in the upcoming transmission.
|
<F>The Checksum field confirms the integrity of the Header and the transmitted data.
@@
To send data using TCP, the source computer makes a connection to the destination computer.
|
The destination computer must be ready to receive the data.
|
To facilitate this process, TCP uses a three way handshake/open connection sequence.
|
Exchanging sequence numbers during the connection sequence ensures that lost data can be recovered if problems occur later.
|
Here Host A wants to open a connection with Host B.
|
So Host A sends the first number in the sequence from A to B.
|
Host B receives the first number, increments it by one, and sends it back as an acknowledgement (ACK).
|
It also sends a sequence number of its own from B to A.
|
Host A receives a packet with an acknowledgement number equal to that of its last sequence number incremented by one.
|
The packet also contains a sequence number from B to A.
|
Upon receipt Host A sends back its own acknowledgement number (equal to host B's last sequence number incremented by one).
|
A connection is opened between Host A and Host B and data can now be exchanged.
|
Window size refers to the number of messages that can be transmitted while awaiting an acknowledgement.
|
After a host transmits the window size number of messages it must receive an acknowledgement before any more messages can be sent.
|
The window size can be negotiated dynamically during the TCP session.
|
This is known as a ^Rsliding window^r, and results in more efficient use of bandwidth by hosts.
|
A window size of one requires each segment or packet to be acknowledged before another is sent.
|
This results in inefficient use of bandwidth by hosts and generates additional network traffic.
|
A larger window size allows more data to be transmitted pending acknowledgements and improves performance.
|
TCP uses expectational acknowledgements, meaning that the acknowledgement number refers to the packet which is expected next.
|
As you can see here, the source computer has a window size of three.
|
So it can transmit three packets before receiving an acknowledgement to send the fourth packet.
|
If the source computer does not receive an ACK for the fourth packet within a given time, it automatically resends the first three packets again.
|
Packets that are not acknowledged within a given time are retransmitted.
@@
UDP is connectionless and "unreliable", meaning that it is a simple protocol that exchanges packets without acknowledgements or guaranteed delivery.
|
No software checking for datagram delivery is provided by UDP.
|
This means that error processing and retransmission are handled by other protocols at higher levels.
|
UDP is used where the reliability mechanisms of TCP are not needed, for example, when transmitting data over very reliable networks.
|
Both TCP and UDP use port or socket numbers to pass information to the upper layers in the protocol stack.
|
UDP defines a set of destinations as protocol ports.
|
Each application on a machine that wants to send or receive information is assigned a 16-bit number called the port of that program.
|
It defines two types of port:

• commonly used port assignments
|
• dynamically bound ports
|
Commonly used port numbers are assigned to certain widely used applications, for example, the File Transport Protocol (FTP) uses a TCP destination port number of 21.
|
Dynamically bound ports have no fixed port number.
|
Accordingly, processes requesting services from an application must identify the port that the process is using.
|
For example, a client PC requesting an FTP session may give its own port number as 1026.
|
The next time the PC requests an FTP session, it may give its port number as 1252.
|
UDP allows a number of client applications with different IP addresses to use the same port number.
|
UDP packets are delivered to the applications that matches both the port number and the IP address.
|
A UDP datagram is enclosed in one or more IP packets.
|
The IP address sends the IP packets to the correct node.
|
The IP software extracts the UDP packet and delivers it to the UDP layer software.
|
The UDP layer software in turn delivers the UDP data to the specified destination protocol port.
|
The UDP header has only four fields - Source Port, Destination Port, Length, and UDP Checksum.
|
The Source and Destination Port fields specify the source and destination port numbers.
|
The Length field specifies the length of the UDP header and data.
|
The UDP Checksum, which is optional, allows packet integrity checking.
|
When UDP checksums are used, they validate the integrity of both the header and data.
|
ACKs are not enforced by the UDP.
|
This is left to higher-level protocols.
|
UDP provides both a broadcast and multicast service.
|
So any one host can use it to reach multiple hosts.
@@
The application layer in the TCP/IP protocol stack manages the user interface and communication among applications.
|
The TCP/IP suite incorporates many upper-layer protocols representing a wide variety of applications.
|
These include network management, file transfer, distributed file services, terminal emulation, and electronic mail.
|
Futher information on the protocols mentioned in this course are covered in more detail in other CBT courses.
|
The File Transfer Protocol (FTP) provides a way to move files between computer systems.
|
FTP allows remote

• login
|
• directory inspection
|
• command execution
|
• file manipulation
|
However, FTP does not provide a transparent service.
|
When you FTP to another site you find files and directories organized in a UNIX tree structure.
|
You can move from one directory to another using the "get" command.
|
Trivial File Transfer Protocol (TFTP)is a simplified version of FTP that allows files to be transferred from one computer to another over a network.
|
Cisco routers can download operating systems and configuration information from TFTP servers.
|
For example, if the router's operating system, normally held in flash memory, becomes corrupted, then the router can download another copy from a TFTP server.
|
The Network File System (NFS) Protocol, is a distributed file system protocol suite developed by Sun Microsystems that allows remote file access across a network.
|
In reality, NFS is simply one of several protocols in the suite.
|
NFS protocols include RPC (Remote Procedure Call), XDR (External Data Representation), and others.
|
NFS protocols are part of a larger architecture that Sun refers to as ONC (Open Network Computing).
|
It uses UDP at the transport layer, and allows transparent access to remote network resources.
@@
The protocol that provides electronic mail with a transport mechanism is the Simple Mail Transfer Protocol (SMTP).
|
It uses the UDP and IP protocols for message exchange.
|
It does not provide a local mail user interface.
|
When you send mail using SMTP the entire message is transmitted from one node to the next, and is stored at each intermediate node until received by the next node.
@@
The Telnet terminal emulation protocol allows logins to remote systems.
|
Network administrators use the Telnet protocol to connect to other routers.
|
Telnet is used to access many specialized information services on the Internet.
|
You can use Telnet as a debugging tool as it can impersonate different applications such as FTP and electronic mail.
|
The rlogin command is similar to Telnet, and is offered in most UNIX implementations.
@@
The Simple Network Management Protocol (SNMP) is used almost exclusively in TCP/IP networks.
|
The Simple Network Management Protocol (SNMP) enables administrators to monitor a network from a single workstation.
|
This station is called the SNMP ^Rmanager^r and all other network devices are called SNMP ^Ragents^r.
|
Agents can be TCP/IP hosts, routers, terminal servers, or other SNMP managers.
|
Regardless of the type of agent being queried, it will return meaningful information to the SNMP manager.
|
For example, routers might provide information about their routing tables and about the amount of traffic they carry.
|
Mainframe hosts, on the other hand, will provide information about the services they support and about connections established with clients.
