You are on page 1of 12

TCP/IP Suite Overview

Issue 01
Date 2019-06-20

HUAWEI TECHNOLOGIES CO., LTD.


Copyright © Huawei Technologies Co., Ltd. 2019. All rights reserved.
No part of this document may be reproduced or transmitted in any form or by any means without prior written
consent of Huawei Technologies Co., Ltd.

Trademarks and Permissions

and other Huawei trademarks are trademarks of Huawei Technologies Co., Ltd.
All other trademarks and trade names mentioned in this document are the property of their respective
holders.

Notice
The purchased products, services and features are stipulated by the contract made between Huawei and the
customer. All or part of the products, services and features described in this document may not be within the
purchase scope or the usage scope. Unless otherwise specified in the contract, all statements, information,
and recommendations in this document are provided "AS IS" without warranties, guarantees or
representations of any kind, either express or implied.

The information in this document is subject to change without notice. Every effort has been made in the
preparation of this document to ensure accuracy of the contents, but all statements, information, and
recommendations in this document do not constitute a warranty of any kind, express or implied.

Huawei Technologies Co., Ltd.


Address: Huawei Industrial Base
Bantian, Longgang
Shenzhen 518129
People's Republic of China

Website: http://e.huawei.com

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. i


TCP/IP Suite Overview Contents

Contents

1 Introduction.................................................................................................................................... 1
2 Overview of Network Protocols................................................................................................. 2
3 TCP/IP Protocol Suite................................................................................................................... 3
3.1 TCP................................................................................................................................................................................. 4
3.2 IP.....................................................................................................................................................................................4
3.3 IP Routing.......................................................................................................................................................................5

4 Interior Routing Protocols........................................................................................................... 7


4.1 RIP.................................................................................................................................................................................. 7
4.2 OSPF...............................................................................................................................................................................7
4.3 IS-IS................................................................................................................................................................................8

5 Exterior Routing Protocols........................................................................................................... 9


5.1 EGP.................................................................................................................................................................................9
5.2 BGP................................................................................................................................................................................ 9

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. ii


TCP/IP Suite Overview 1 Introduction

1 Introduction

This document describes the concepts and fundamentals of the TCP/IP protocol suite.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 1


TCP/IP Suite Overview 2 Overview of Network Protocols

2 Overview of Network Protocols

Computer networks have grown rapidly since the 1960s. To dominate the data
communications network, major vendors have launched their own network architecture
systems and standards, and produced different hardware and software for their own protocols.
The joint efforts of various vendors promoted the rapid development of network technologies
and the rapid growth of network device types. However, due to the coexistence of multiple
protocols, networks became more and more complicated, and most network devices of
different vendors were incompatible and difficult to communicate with each other.
To resolve network compatibility issues and help vendors produce compatible network
devices, the International Organization for Standardization (ISO) proposed the Open System
Interconnection (OSI) reference model in 1984. The OSI reference model was designed based
on the following principles: There are clear boundaries between layers to implement specific
functions. The division of layers is beneficial to the formalization of international standard
protocols. The number of layers are sufficient to avoid duplication of functions at each layer.
Figure 2-1 shows the seven-layer of the OSI reference model.

Figure 2-1 Seven-layer of the OSI reference model

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 2


TCP/IP Suite Overview 3 TCP/IP Protocol Suite

3 TCP/IP Protocol Suite

The OSI reference model and protocols are complex and so have not been widely used. The
Transmission Control Protocol/Internet Protocol (TCP/IP) model has been widely used in
practice because of its openness and ease of use. The TCP/IP protocol suite also becomes the
mainstream protocols of the Internet.
The hierarchical structure of the TCP/IP protocol suite cannot exactly correspond to the OSI
reference model. The TCP/IP protocol suite was originally defined as a hardware-based four-
layer architecture: including the application layer, transport layer, Internet layer, and link
layer. A five-layer protocol model is adopted to combine the characteristics of the OSI and
TCP/IP, as shown in Figure 3-1.

Figure 3-1 Computer network system

3.1 TCP
3.2 IP
3.3 IP Routing

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 3


TCP/IP Suite Overview 3 TCP/IP Protocol Suite

3.1 TCP
TCP is a connection-oriented transport protocol. Applications must establish a TCP
connection before using the TCP protocol. After data transmission is complete, the
established TCP connection must be released. Communication between application programs
is like making a call. You need to dial up to establish a connection before a call, and hang up
to release the connection after the call ends.
TCP provides end-to-end reliable services. Each TCP connection has only two endpoints.
The data transmitted over a TCP connection is error-free, not lost, not duplicated, and arrives
in order. TCP provides functions such as timeout and retransmission management, window
management, traffic control, and congestion control to ensure that TCP provides reliable
services.
TCP provides full-duplex communication. TCP allows application processes of both
communication parties to send data at any time. Both ends of a TCP connection are provided
with a send buffer and a receive buffer to temporarily store data transmitted between the two
parties. Application programs just need to transmit data to the TCP buffer, and TCP sends the
data at a proper time. TCP stores the received data in the buffer. Upper-layer application
processes read the data in the buffer at a proper time.
TCP provides stream-oriented services. A stream in TCP refers to a sequence of bytes
flowing into or out of a process. The meaning of stream-oriented stream is that although the
interaction between an application and TCP is one data block at a time (the size is not equal),
TCP regards the data handed over by the application as a series of unstructured byte streams.
TCP does not know the meaning of the transmitted byte streams.

3.2 IP
To connect a PC to the Internet, you need to apply an IP address from an Internet Service
Provider (ISP). An IP address is a numerical label assigned to each device on a computer
network. An IPv4 address is a 32-bit binary number, and it is expressed in dotted decimal
notation, which helps you memorize and identify it. In dotted decimal notation, an IPv4
address is written as four decimal numbers, one for each byte of the address. For example, the
binary IPv4 address 00001010 00000001 00000001 00000010 is written as 10.1.1.2 in dotted
decimal notation.
An IPv4 address is divided into two parts:
1. Network ID (Net-id): identifies a network.
2. Host ID (Host-id): identifies a host on a network. Network devices with the same
network ID are located on the same network, regardless of their physical locations.
IPv4 addresses have the following characteristics:
1. IP addresses do not reflect any geographical information of hosts. The network ID
specifies the network to which a host belongs.
2. When a host connects to two networks simultaneously, it must have two IP addresses
with different network IDs. In this case, the host is called a multihomed host.
3. Networks allocated with network IDs are in the same class.
IP addresses are classified into five classes to facilitate IP address management and
networking, as shown in Figure 3-2.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 4


TCP/IP Suite Overview 3 TCP/IP Protocol Suite

Figure 3-2 IP addresses of five classes

At present, most IP addresses in use belong to Class A, Class B, or Class C. Class D addresses
are multicast addresses and Class E addresses are reserved. The easiest way to determine the
class of an IP address is to check the first bits in its network ID. The class fields of Class A,
Class B, Class C, Class D, and Class E are binary digits 0, 10, 110, 1110, and 1111
respectively. For details about IP address classification, see RFC 1166.

3.3 IP Routing
Routing is a basic concept in an IP network. The basic function of a network is to enable two
IP nodes in the network to communicate with each other. The communication is actually a
data exchange process. Data exchange requires network devices to help transmit data between
two communication nodes. When a router (or another Layer 3 device) receives an IP packet,
the router finds the destination IP address in the IP header of the packet, and searches its
routing table for a route based on the destination IP address. After it finds an exact matching
routing entry, it forwards the packet using the outbound interface or next-hop IP address
indicated by the routing entry. This process is called routing.
Each router maintains a routing table locally. The routing table contains the routing entries
obtained by the router using various methods. Each routing entry consists of the route prefix
(destination network ID of the route), route origin, outbound interface or next-hop IP address,
priority, and cost. Routers obtain routing entries through direct, static, or dynamic routing
protocols and maintain their own routing tables. Routing tables are the basis for data
forwarding of each routing-supporting device.
Routing protocols are classified into interior routing protocol and exterior routing protocol
based on where the protocols are running, as shown in Figure 3-3:
l Interior routing protocol: runs within an AS.
l Exterior routing protocol: runs between different ASs.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 5


TCP/IP Suite Overview 3 TCP/IP Protocol Suite

Figure 3-3 Interior routing protocols and exterior routing protocols

Routing protocols are classified into distance-vector routing protocol and link-state routing
protocol based on the routing algorithms, as shown in Figure 3-4:
l Distance-vector routing protocol: includes RIP and Border Gateway Protocol (BGP).
BGP is also called a path-vector protocol.
l Link-state routing protocol: includes Open Shortest Path First (OSPF) and Intermediate
System-to-Intermediate System (IS-IS).

Figure 3-4 Distance-vector routing protocols and link-state routing protocols

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 6


TCP/IP Suite Overview 4 Interior Routing Protocols

4 Interior Routing Protocols

4.1 RIP
4.2 OSPF
4.3 IS-IS

4.1 RIP
RIP is a distance-vector algorithm that measures the distance to a destination network based
on the hop count. It is a simple Interior Gateway Protocol (IGP). RIP exchanges routing
information using User Datagram Protocol (UDP) packets through UDP port 520. Two RIP
versions are used in IPv4 networks: RIP version 1 (RIP-1) and RIP version 2 (RIP-2). RIP-2
is an extension to RIP-1.

RIP has been widely used on small-sized networks to discover routes and generate routing
information. It is easier to configure, maintain, and implement than OSPF and IS-IS. RIP has
a limit of 15 hops and is not suitable for complex or large networks.

4.2 OSPF
OSPF is a link-state IGP that works within a single AS. OSPF Version 2, as defined in RFC
2328, is designed for IPv4. OSPF Version 3, as defined in RFC 2740, is designed for IPv6.

In an OSPF network, each router generates link state advertisements (LSAs) based on its
surrounding network topology and transmits the LSAs in update packets to other routers in
the network. RIP devices exchange routes, whereas OSPF devices exchange link state
information. That is, in RIP, routers select routes based on routing information of neighbors,
without checking whether the information transmitted by neighbors is correct. In OSPF,
routers calculate routes by themselves and select routes based on LSAs.

Each router learns about the whole network topology based on its link state database (LSDB).
Each router collects LSAs sent from other routers, and all LSAs form the LSDB of this router.
An LSA describes the surrounding network topology of a router, whereas an LSDB describes
the network topology of the entire AS. A router transforms its LSDB into a weighted and
directed graph, which reflects the topology of the entire AS. When the network topology is
stable, all routers in the same area have the same graph.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 7


TCP/IP Suite Overview 4 Interior Routing Protocols

4.3 IS-IS
IS-IS is an IGP that runs within an AS. It is also a link-state routing protocol, using the
shortest path first (SPF) algorithm to calculate routes.
IS-IS is a dynamic routing protocol initially designed by the ISO for its Connectionless
Network Protocol (CLNP).
To support IP routing, the Internet Engineering Task Force (IETF) extended and modified IS-
IS in RFC 1195. This modification enables IS-IS to apply to TCP/IP and OSI environments.
This type of IS-IS is called Integrated IS-IS or Dual IS-IS.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 8


TCP/IP Suite Overview 5 Exterior Routing Protocols

5 Exterior Routing Protocols

5.1 EGP
5.2 BGP

5.1 EGP
A network is divided into different ASs to facilitate network management. In 1982, the
Exterior Gateway Protocol (EGP) was defined to dynamically exchange routing information
between ASs. EGP advertises only reachable routes and does not select optimal routes or
prevent routing loops. Therefore, EGP cannot meet network management requirements.

5.2 BGP
BGP is a path-vector routing protocol that allows devices between ASs to communicate with
each other and selects optimal routes. BGP-1 (defined in RFC 1105), BGP-2 (defined in RFC
1163), and BGP-3 (defined in RFC 1267) are three earlier versions of BGP. BGP-4 (defined in
RFC 1771) has been used since 1994. Since 2006, unicast IPv4 networks have been using
BGP-4 defined in RFC 4271, and other networks (such as IPv6 networks) have been using
Multiprotocol BGP (MP-BGP) defined in RFC 4760.
MP-BGP is an extension of BGP-4 and applies to different networks, but the original message
exchange and routing mechanisms of BGP-4 remain unchanged. MP-BGP applications on
IPv6 unicast and IPv4 multicast networks are called BGP4+ and Multicast BGP (MBGP)
respectively.

Issue 01 (2019-06-20) Copyright © Huawei Technologies Co., Ltd. 9

You might also like