The Seven Layers

The OSI model categorizes the various processes needed in a communications session into seven distinct functional layers. The layers are organized based on the natural sequence of events that occur during a communications session.

Figure 1-1 illustrates the OSI reference model. Layers 1-3 provide network access, and Layers 4-7 are dedicated to the logistics of supporting end-to-end communications.

Figure 1-1: The OSI reference model.

Figure 1-1: The OSI reference model.

Layer 1: The Physical Layer

The bottom layer, or Layer 1, of the OSI reference model is called the physical layer. This layer is responsible for the transmission of the bit stream. It accepts frames of data from Layer 2, the data link layer, and transmits their structure and content serially, one bit at a time.

Layer 1 is also responsible for the reception of incoming streams of data, one bit at a time. These streams are then passed on to the data link layer.

The physical layer, quite literally, operates on only 1s and 0s. It has no mechanism for determining the significance of the bits it transmits or receives. It is solely concerned with the physical characteristics of electrical and/or optical signaling techniques. This includes the voltage of the electrical current used to transport the signal, the media type and impedance characteristics, and even the physical shape of the connector used to terminate the media.

Transmission media includes any means of actually transporting signals generated by the OSI's Layer 1 mechanisms. Some examples of transmission media are coaxial cabling, fiber-optic cabling, and

An Introduction to Internetworking twisted-pair wiring.

Layer 2: The Data Link Layer

Layer 2 of the OSI reference model is called the data link layer. As all the layers do, it has two sets of responsibilities: transmit and receive. It is responsible for providing end-to-end validity of the data being transmitted.

On the transmit side, the data link layer is responsible for packing instructions---data---into frames. A frame is a structure indigenous to the data link layer that contains enough information to make sure that the data can be successfully sent across a LAN to its destination. Implicit in this definition is that the data link layer contains its own address architecture. This addressing is only applicable to other networked devices that reside locally on the same data link layer domain.

Note A data link layer domain is all the network components that propagate a data link layer broadcast. Typically, a data link layer domain is regarded as a LAN segment. Not all LAN technologies adhere rigidly to the functionality specified for the data link layer in the OSI model. Some LAN architectures do not support reliable delivery, for example. Their data frames are transmitted, but their status is not tracked. Guaranteeing delivery would then be left to a Layer 4 protocol, such as Transmission Control Protocol (TCP).

Successful delivery means that the frame reaches its intended destination intact. Therefore, the frame must also contain a mechanism to verify the integrity of its contents on delivery.

Two things must happen for a successful delivery to occur:

• The destination node must verify the integrity of that frame's contents before it can acknowledge its receipt.

• The originating node must receive the recipient's acknowledgment that each frame transmitted was received intact by the destination node.

Numerous situations can result in transmitted frames either not reaching the destination or becoming damaged and unusable during transit. It is the data link layer's responsibility for detecting and correcting any and all such errors. The data link layer is also responsible for reassembling the binary streams that are received from the physical layer back into frames.

The physical and data link layers (1 and 2) are required for each and every type of communication regardless of whether the network is a LAN or wide-area network (WAN). Together, these two layers provide all the mechanisms that software applications need to contact and communicate with other devices connected to the same LAN. In Figure 1-2, all the user machines can directly access the local server. Consequently, they do not require the use of network layer protocols or addressing to communicate with each other.

Figure 1-2: The physical and data link layers are adequate for delivering datagrams locally.

Elhemel

These two layers are also highly interrelated and, consequently, come bundled together in products. When you purchase LAN hardware (Ethernet, Token Ring, FDDI, and so on), for example, you have simultaneously selected both a physical layer and a data link layer specification. Figure 1-3 uses the IEEE's reference model for Ethernet LANs to demonstrate the tight coupling between the first two layers of the OSI reference model.

Note The Institute of Electrical and Electronic Engineers (IEEE) is another standards-setting body. One of their more noteworthy efforts has been the standardization of LANs and metropolitan-area networks (MANs) through their Project 802. Project 802 contains hundreds of individual specifications for specific aspects of local and metropolitan-area networking. IEEE-compliant LANs include Ethernet (IEEE 802.3) and Token Ring (802.5). All the specifications in the 802 family of standards are limited to the physical and/or data link layer.

The IEEE's 802 reference model actually breaks the OSI model's data link layer into two separate components: Media Access Control (MAC) and Logical Link Control (LLC). The MAC sublayer is responsible for physically transmitting and receiving data via the transmission media. The LLC is the component that can provide reliable delivery of data frames. In practice, this function is frequently ceded to transport layer protocols rather than implemented in the data link layer.

Figure 1-3: Ethernet's physical and data link layers are tightly coupled.

OS ri".encs vcdel laver descnpiicn

OSI1 number

Ittt Pioiecl 302 relengn^e n^el

Service n&TFCo pçinis Inr h^hrr Inyiir pmkinnK

r>jl.i .ink

Logeai .m'. Co-viol

MgdiiJ Gr-ci::;.'-, Ccmtrql

Physical

is

Od s 2 ■=i

"J-

?

Selection of a LAN architecture, however, does not limit the choice of higher-level protocols. Instead, you should expect that a protocol stack that encompasses Layers 3 and 4 will interoperate with existing standardized data link layer protocols through well-defined open interfaces.

An Introduction to Internetworking

Layer 3: The Network Layer

The network layer enables internetworking. The protocols at this layer are responsible for establishing the route to be used between the source and destination computers. This layer lacks any native transmission error detection/correction mechanisms and, consequently, is forced to rely on the end-to-end reliable transmission service of either the data link layer or the transport layer. Although some data link layer technologies support reliable delivery, many others do not. Therefore, Layer 3 protocols (such as IP) assume that Layer 4 protocols (such as TCP) will provide this functionality rather than assume Layer 2 will take care of it.

Note It is important to note that the source and destination computers need not reside within the same data link layer domain. If they were attached to the same LAN, the data link layer mechanisms would be adequate to provide delivery. However, many applications require the services provided by TCP and/or IP to function properly. Therefore, even though a source and destination computer may be capable of communicating perfectly using just physical and data link layer protocols, their applications might require the use of network and transport protocols.

Figure 1-4 illustrates the same network as Figure 1-2. The only difference is that a second network has been connected to it via a router. The router effectively isolates the two data link layer domains. The only way to communicate between these two domains is through the use of network layer addressing.

Figure 1-4: The network layer is required for delivering packets between networks.

Figure 1-4: The network layer is required for delivering packets between networks.

In this situation, if a user on Network 1 needed to access information stored on the server of Network 2, network layer addressing would be needed. The network layer can perform this intermediary function because it has its own addressing architecture, which is separate and distinct from the data link layer machine addressing.

The network layer mechanisms have been implemented in a series of protocols that can transport application data across LAN segments, or even WANs. These protocols are called routable protocols because their datagrams can be forwarded by routers beyond the local network. Routable protocols include IP, Internetwork Packet Exchange (IPX), and AppleTalk. Each of these protocols, as well as the other routable protocols, has its own Layer 3 addressing architecture. This addressing architecture is used to identify machines that are connected to different networks. Routers are needed to calculate the routes and forward the data contained within the routable protocol packets to machines that lie beyond the local link of the transmitting machine.

IP has emerged as the dominant routable protocol. Consequently, this entire book reinforces the fundamentals of routing using only the IP protocol in the examples and illustrations.

Unlike the first two layers, the use of the network layer is optional in data communications. The network layer is required only if the computer systems reside on different networks, or if the communicating applications require its services. In the first case, the different LAN domains would have to be interconnected somehow (as illustrated in Figure 1-4); otherwise, the communications could not occur. Alternatively, application software could require the use of either network or transport layer mechanisms, regardless of how the communicating devices are interconnected.

Layer 4: The Transport Layer

Layer 4, the transport layer, provides a similar service to the data link layer, in that it is responsible for the end-to-end integrity of transmissions. Unlike the data link layer, the transport layer can provide this function beyond the local LAN segment. It can detect packets that were either damaged or lost in transit and can automatically generate a retransmit request.

Another significant function of the transport layer is the resequencing of packets that, for a variety of reasons, may have arrived out of order. The packets may have taken different paths through the network, for example, or some may have been damaged in transit. In any case, the transport layer can identify the original sequence of packets and put them back into that sequence before passing their contents up to the session layer.

Much like the interrelationship between the first and second layers, the third layer of the OSI reference model is usually tightly interrelated with the fourth layer. Two specific examples of routable protocol suites that tightly integrate these two layers are open standard TCP/IP and Novell's IPX/SPX (Internetwork Packet Exchange, Sequenced Packet Exchange). This interrelationship is illustrated in Figure 1-5, using the TCP/IP reference model. Together, these layers provide the mechanisms that enable the transfer of information between source and destination machines across a communications network that spans beyond a Layer 2 domain. These layers also provide other functions such as resequencing packets received out of order and retransmitting packets not received or received damaged.

Figure 1-5: The TCP/IP reference model demonstrates the tight coupling of the network and transport layers.

Oti fe^ierce nrodel laver 39icnpli:yi

OS layer number

rcp.'ip es'jivf.^nl layer desirphon

ApplteHlkyi

appliiaiiirt

fi

5

Htiet-t-n-hnei

~rMriK|j;>L

i-

\dl-Al3l h

3

Inlarnal

Neiwuk atcesa

Liate imfc

2

Physical

I

Layer 5: The Session Layer

Layer 5 of the OSI model is the session layer. Many protocols bundle this layer's functionality into their transport layers. Some specific examples of session layer services are Remote Procedure Calls (RPCs) and quality of service protocols such as RSVP---the bandwidth reservation protocol.

Layer 6: The Presentation Layer

Layer 6, the presentation layer, is responsible for managing the way that data is encoded. Not every computer system uses the same data encoding scheme, and the presentation layer is responsible for providing the translation between otherwise incompat- ible data encoding schemes, such as American Standard Code for Information Interchange (ASCII) and Extended Binary Coded Decimal Interchange Code (EBCDIC).

The presentation layer can be used to mediate differences in floating-point formats, as well as to provide encryption and decryption services.

Layer 7: The Application Layer

The top, or seventh, layer in the OSI reference model is the application layer. Despite its name, this layer does not include user applications. Instead, it provides the interface between those applications and the network's services.

This layer can be thought of as the reason for initiating the communications session. For example, an email client might generate a request to retrieve new messages from the email server. This client application automatically generates a request to the appropriate Layer 7 protocol(s) and launches a communications session to get the needed files.

Note Note that most of today's networking protocols use their own layered models. These models vary in the degree to which they adhere to the sepa- ration of functions demonstrated by the OSI reference model. It is quite common for these models to collapse the seven OSI layers into five or fewer layers. It is also common for higher layers to not correspond perfectly to their OSI-equivalent layers. Additionally, models may not even describe the full spectrum of the OSI's layered functions! The IEEE's layered functional model, for example, is just for LANs and MANs---it does not extend above the data link layer. Ethernet, Token Ring, and even FDDI are compliant with this model.

0 0

Post a comment