OSI Reference Model 101

  • Identify the seven layers of the OSI model and their functions.

The OSI model consists of seven layers, which is why it is sometimes called the OSI seven-layer model. In diagram form, as shown in Figure 4.1, the model is drawn from bottom to top in the following order: physical, data-link, network, transport, session, presentation, and application layers. The physical layer is classified as Layer 1, and the application layer is classified as Layer 7. In many cases, devices are referred to in relationship to the numbered layers at which they operate. For example, a router is said to be a Layer 3 (network layer) device.

Figure 4.1. The OSI reference model.


The model is used to relate the transport of data from one host to another. If the data were being sent from an application, such as a Web browser, to a Web server, it would travel down through all the layers on the sending device, across the network media, and up through all the layers on the receiving device. Figure 4.2 shows a representation of how this works.

Figure 4.2. How data travels between two devices.


EXAM TIP

OSI Mnemonics Many people find it helps to use a mnemonic device to remember the order of the OSI model. There are plenty available and range from the surreal to the obscene. Two that we particularly like are Please Do Not Throw Sausage Pizza Away and All People Seem To Need Data Processing. If you prefer, you can make up your own or even search the Internet to find some of the alternatives. If a mnemonic device helps you remember the model and the appropriate functions at each layer, it is worth using.


As data is passed up or down through the OSI model structure, headers are added (going down) or removed (going up) at each layer—a process called encapsulation (addition) or decapsualtion (removal). Figure 4.3 shows how this works.

Figure 4.3. Encapsulation and decapsulation.


The information added by each device at the sending end is removed by the corresponding layer at the receiving end. Each layer defines a certain aspect of the communication process, and as data travels up and down the model, the information is sorted into logical groups of bits. The exact term used to refer to the logical group of bits depends on the layer. Table 4.1 contains the terminology used at each layer of the OSI model.

Table 4.1. Terminology Used for Logical Groups of Bits at the Layers of the OSI Model
Layer Terms Used
Application Packets and messages
Presentation Packets
Session Packets
Transport Packets, segments, and datagrams
Network Packets and Datagrams
Data-link Packets and frames
Physical Packets and bits

As you can see, at every layer the term packet is used, and in some cases, other terms are used as well. Each layer of the OSI model defines specific functionality. The following sections look at each of the layers separately and discuss the function of each.

Layer 1: The Physical Layer

The physical layer (sometimes referred to incorrectly as the hardware layer) is the layer of the OSI model that defines the physical characteristics of the network. The physical characteristics can include the cable and connector type, the format for pinouts for cables, and so on. It also defines how the data actually travels across the network.

The physical layer also defines the voltage that is used on the cable and the frequency at which the signals that carry the data are transitioned from one state to another. Such characteristics directly affect the speed (bandwidth) of a given media as well as the maximum distance over which a certain media type can be used.

NOTE

OSI Numbering Some discussions of the OSI model examine it from top to bottom, and others examine it in reverse. Both methods are valid, but remember that the numbering starts from the bottom and works up. Therefore, it seems most logical to us to explain the model starting at Layer 1 and working up.


Because the physical layer defines the physical connection to the network, it also defines the physical topology of the network. Recall that there are a number of common physical topologies, including star, ring, bus, mesh, and hybrid, with star being the most common.

Various standards are defined at the physical layer—for example, the Institute of Electrical and Electronics Engineers (IEEE) 802.3 Ethernet standard and the 802.5 Token Ring standard. If you think about it, this is very reasonable: An Ethernet network card has different physical characteristics than a Token Ring network card. However, you should know that some of these standards overlap more than one layer of the OSI model. For example, the Ethernet standard also defines the media access method, which is a function of the data-link layer.

Layer 2: The Data-Link Layer

The data-link layer is responsible for sending data to the physical layer so that it can be transmitted across the network. The data-link layer can perform checksums and error detection on the data to make sure that the data that was sent is the same as the data that is received.

The data-link layer is different from the other layers of the OSI model because it has two distinct sublayers—the Logical Link Control (LLC) sublayer and the Media Access Control (MAC) sublayer. Each has a very specific role:

  • LLC— The LLC sublayer, which is defined by the IEEE 802.2 standard, controls the access of the media, allowing multiple high-level protocols to use a single network link.

  • MAC— The MAC sublayer manages and controls access to the network media for the protocols that are trying to use it. The MAC address is defined at this layer.

As discussed in Chapter 1, “Introduction to Networking,” there is a difference between the physical topology (how a network looks) and the logical topology (how the network works). Whereas the physical layer sees it from a physical topology perspective, the data-link layer sees the network from a logical topology perspective.

Layer 3: The Network Layer

The network layer of the OSI model is primarily concerned with providing a mechanism by which data can be moved between two networks or systems. The network layer does not define how the data is moved; rather, it is concerned with providing the mechanism that can be used for that purpose. The mechanisms that can be used include defining network addressing and conducting route discovery and maintenance.

When a system attempts to communicate with another device on the network, network-layer protocols attempt to identify that device on the network. When the target system has been identified, it is then necessary to identify the service that is to be accessed. This is achieved by using a service identifier. On Transmission Control Protocol/Internet Protocol (TCP/IP) networks, service identifiers are commonly referred to as ports, and on Internetwork Packet Exchange/Sequenced Packet Exchange (IPX/SPX) networks they are called sockets, although technically the terms can be used interchangeably.

Switching Methods

An important concept related to the network layer is switching methods. The switching method describes how the data sent from one node reaches another. Three types of switching are used on networks:

  • Circuit switching— The best example of circuit switching is a telephone call. The link between caller and receiver is created, after which there is a dedicated communications link between the two points (hence the term circuit). The circuit cannot be broken, which is good because it means that no one else can use the line. In a data communications environment, however, this is a disadvantage because the data often originates from various sources.

  • Message switching— In a message-switching environment, transmissions are broken down into messages that can traverse the network by the fastest means available. It might be that all messages travel over the same path or it might be that messages travel on different paths. At each point in the journey, the message is stored by a node before it is forwarded to the next hop on the journey. Such a mechanism gives rise to the phrase store and forward. The message-switching system works well in environments in which the amount of data being moved around varies at different times, but it also causes problems such as where to store the data before it is forwarded.

  • Packet switching— Although both circuit switching and message switching can get the job done, both have some serious drawbacks that make them unsuitable for use in a modern network environment. Today, most networks use packet switching, which includes the good points of both circuit and message switching and does not include the bad points. In a packet-switched network, data is broken down into packets that can then be transported around the network. Most modern networks use packet switching as the switching method.

EXAM TIP

Know the Switching Methods Be prepared to identify switching methods on the Network+ exam.


NOTE

More on Switching A more comprehensive discussion of switching methods, in particular how they relate to wide area networks, is included in Chapter 7, “WAN Technologies.”


Network-Layer Addressing

From a network administrator's perspective, one of the most important aspects of the network layer is addressing. Network addresses allow a system to be identified on the network by a logically assigned address. This is in contrast to the physically assigned MAC addresses used on the data-link layer. The logical assignment of addresses means that schemes can be created that allow a more hierarchical approach to addressing than MAC addresses provide. By using a hierarchy, it is possible to assign a certain address to logical groups of systems as well as to the systems themselves. The result is that network addressing can be used to create portions of the network called subnets.

Hierarchical addressing systems are possible only with routable network protocols. The most common routable protocol in use today is TCP/IP, although IPX/SPX can still be found on many networks. Other routable protocols, such as AppleTalk, have all but been replaced with TCP/IP.

Of course, you don't have to use a routable protocol. Other nonroutable protocols, such as NetBEUI, can be used, although they are of limited use in today's modern networking environments, where routable protocols are the order of the day. A more detailed discussion of networking protocols is included in Chapter 5, “Overview of Network Protocols.”

Another function of the network layer is route selection, which refers to determining the best path for the data to take throughout the network. Recall from Chapter 3 that there are two ways in which routes can be configured: statically and dynamically. In a static routing environment, the network administrator must manually add routes to the routing tables. In a dynamic routing environment, routing protocols such as Routing Information Protocol (RIP) and Open Shortest Path First (OSPF) are used. These protocols work by automatically communicating routing information between devices on the network.

Layer 4: The Transport Layer

The basic function of the transport layer is, as its name suggests, to transport data from one host to another. The transport layer handles the actual processing of data between devices. This includes functions such as segmenting data so that it can be sent over the network and then reassembling the segmented data on the receiving end. The transport layer also deals with some of the errors that can occur in a stream of data, such as dropped and duplicated packets. In addition, the transport layer deals with some of the problems that can be produced by the fragmentation and reassembly process performed by the network layer.

The protocols that operate at the transport layer are those that are directly concerned with the transporting of data across the network. The following are some of the most commonly used transport-layer protocols:

  • TCP— Part of the TCP/IP protocol suite, TCP provides a connection-oriented transport mechanism.

  • User Datagram Protocol (UDP)— Part of the TCP/IP protocol suite, UDP provides a connectionless transport mechanism.

  • IPX Part of Novell's IPX/SPX protocol suite, IPX provides a connectionless transport mechanism

  • SPX— Part of Novell's IPX/SPX protocol suite, SPX provides a connection-oriented transport mechanism.

Connection-Oriented Protocols

As you can see from the descriptions of the protocols in the preceding section, some are connection oriented and others are connectionless. In a connection-oriented session, the communication dialog between two systems is established, maintained, and then broken when the communication is complete. In technical jargon, this is often referred to as the setting up and tearing down of a session. While we are on the subject of sessions, we should make something clear: The session layer is also responsible for setting up, maintaining, and closing sessions with other hosts, but it does so at the application level rather than the network level. TCP and other transport-layer protocols maintain the sessions at the network level.

Connection-oriented protocols, such as TCP, enable the delivery of data to be guaranteed because the receipt of each packet that is sent must be acknowledged by the receiving system. Any packet that is not received is re-sent. This makes for a very reliable communication system, though the additional steps necessary to guarantee delivery mean that connection-oriented protocols have higher overhead than do connectionless protocols.

EXAM TIP

Connection-Oriented Protocols Connection-oriented protocols are able to accommodate lost or dropped packets by asking the sending device to retransmit. You should note this for the exam.


Connectionless Protocols

In contrast to connection-oriented communication, connectionless protocols offer only a best-effort delivery mechanism. A connectionless communication is a “fire and forget” mechanism in which data is sent but no acknowledgments of receipt are sent. This mechanism has a far lower overhead than the connection-oriented method, and it places the onus of ensuring complete delivery on a higher layer, such as the session layer.

EXAM TIP

Know the Protocols Be prepared to identify both connection-oriented and connectionless protocols on the Network+ exam.


Flow Control

Flow control also occurs at the transport layer. As the name suggests, flow control deals with the acceptance of data. It controls the data flow in such a way that the receiving system is able to accept the data at an adequate rate. Two methods of flow control are commonly used:

  • Buffering— In a buffering system, data is stored in a holding area and waits for the destination device to become available. A system that uses this strategy encounters problems if the sending device is able to send data much faster than the receiving device is able to accept it.

  • Windowing— Windowing is a more sophisticated approach to flow control than buffering. In a windowing environment, data is sent in groups of segments that require only one acknowledgment. The size of the window (that is, how many segments can be sent for one acknowledgment) is defined at the time the session between the two devices is established. As you can imagine, the need to have only one acknowledgment for every, say, five segments can greatly reduce overhead.

Layer 5: The Session Layer

The session layer is responsible for managing and controlling the synchronization of data between applications on two devices. It does this by establishing, maintaining, and breaking sessions. Whereas the transport layer is responsible for setting up and maintaining the connection between the two devices, the session layer performs much the same function on behalf of the application.

EXAM TIP

About the OSI Layers The Network+ exam touches very lightly on the upper layers of the OSI model; therefore, only a very basic explanation of them is provided here.


Layer 6: The Presentation Layer

The presentation layer's basic function is to convert the data intended for or received from the application layer into another format. Such conversion is necessary because the way in which data is formatted so it can be transported across the network is not necessarily readable by applications. Some common data formats handled by the presentation layer include the following:

  • Graphics files— JPEG, TIFF, GIF, and so on are graphics file formats that require the data be formatted in a certain way.

  • Text and data— The presentation layer is able to translate data into different formats such as American Standard Code for Information Interchange (ASCII) and Extended Binary Code Decimal Interchange Code (EBCDIC).

  • Sound/video— MPEGs, QuickTime video, and MIDI files all have their own data formats to and from which data must be converted.

Another very important function of the presentation layer is encryption. Encryption is the scrambling of data so that it cannot be read by anything or anyone other than the intended destination. Data encryption is performed at the sending system, and decryption (that is, the unscrambling of data at the receiving end) is performed at the destination. Given the basic role of the presentation layer—that of data format translator—it is the obvious place for encryption and decryption to take place.

Layer 7: The Application Layer

The most common misconception about the application layer, the topmost layer of the OSI model, is that it represents applications that are used on a system such as a word processor or a spreadsheet. This is not correct. Instead, the application layer defines the processes that allow applications to use network services. For example, if an application needs to open a file from a network drive, the functionality is provided by components that reside at the application layer. However, some applications, such as email clients and Web browsers, do in fact reside at the application layer.

In simple terms, the function of the application layer is to take requests and data from the user and pass them to the lower layers of the OSI model. Incoming information is passed to the application layer, which then displays the information to the user. Some of the most basic application-layer services include file and print capabilities.

REVIEW BREAK: OSI Model Summary

Now that we have discussed the functions of each layer of the OSI model, it's time for a quick review. Table 4.2 lists the seven layers of the OSI model and describes some of the most significant points of each layer.

EXAM TIP

Know Table 4.2 For the Network+ exam, as well as for your real-world experience, the information supplied in Table 4.2 should be sufficient.


Table 4.2. OSI Model Summary
OSI Layer Major Functions
Application Provides access to the network for applications and certain end user functions.
 Displays incoming information and prepares outgoing information for network access.
Presentation Converts data from the application layer into a format that can be sent over the network.
 Converts data from the session layer into a format that can be understood by the application layer.
 Handles encryption and decryption of data. Provides compression and decompression functionality.
Session Synchronizes the data exchange between applications on separate devices.
 Handles error detection and notification to the peer layer on the other device.
Transport Establishes, maintains, and breaks connections between two devices.
 Determines the ordering and priorities of data.
 Performs error checking and verification and handles retransmissions if necessary.
Network Provides mechanisms for the routing of data between devices across single or multiple network segments.
 Handles the discovery of destination systems and addressing.
Data-link Has two distinct sublayers: LLC and MAC.
 Performs error detection and handling for the transmitted signals.
 Defines the method by which the media is accessed.
 Defines hardware addressing through the MAC sublayer.
Physical Defines the physical structure of the network.
 Defines voltage/signal rates and the physical connection methods.
 Defines the physical topology.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
3.147.238.70