Chapter 5: Data-Link Layer Protocols continued
Estimated lesson time: 50 minutes
Around the same time that these standards were published, an international standards-making body called the Institute of Electrical and Electronic Engineers (IEEE) set about creating an international standard defining this type of network, which would not be held in private hands, as was the DIX Ethernet standard. In 1980, the IEEE assembled what they called a working group with the designation IEEE 802.3 that began the development of an Ethernet-like network standard. They couldn't call their network Ethernet because Xerox had trademarked the name, but in 1985, they published IEEE 802.3 Carrier Sense Multiple Access with Collision Detection (CSMA/CD) Access Method and Physical Layer Specifications. This document included specifications for networks using the same two coaxial cable options as DIX Ethernet and, after further development, added a specification for an unshielded twisted pair (UTP) cable option known as 10Base-T. Additional documents published by the IEEE 802.3 working group in later years include IEEE 802.3u in 1995, which defines the 100-Mbps Fast Ethernet specifications, and IEEE 802.3z and IEEE 802.3ab, which are the 1000-Mbps Gigabit Ethernet standards.
The IEEE 802.3 standard differs only slightly from the DIX Ethernet standard. The IEEE standard contains additional physical layer options, as already noted, and some differences in the frame format. Despite the continued use of the name Ethernet in the marketplace, however, the protocol that networks use today is actually IEEE 802.3, because this version provides the additional physical layer options and the Fast Ethernet and Gigabit Ethernet standards. Development of the DIX Ethernet standards ceased after Ethernet II, and coaxial cable Ethernet is all but obsolete. When people use the term Ethernet today, it is understood that they actually mean IEEE 802.3. The only element of the DIX Ethernet standard still in common use is the Ethernet II frame format, which contains the Ethertype field that is used to identify the network layer protocol that generated the data in each packet.
Both the IEEE 802.3 and DIX Ethernet standards consist of the following three basic components:
Table 5.1 Ethernet Physical Layer Specifications
The coaxial Ethernet standards (10Base5 and 10Base2) are the only ones that call for a bus topology. The maximum segment length indicates the length of the entire bus, from one terminator to the other, with all of the computers in between, as shown in Figure 5.1. A cable segment that connects more than two computers is called a mixing segment. The coaxial standards are no longer in use, except on a few older networks, because coaxial cable is more difficult to install and maintain than UTP and it is limited to a maximum speed of 10 Mbps.
Figure 5.1 Ethernet's coaxial cable specifications use a mixing segment to connect multiple computers to the network
All of the other Ethernet physical layer specifications use the star topology, in which a separate cable segment connects each computer to a hub. A cable segment that connects only two devices is called a link segment. UTP is the most popular type of cable used on Ethernet networks today because it is easy to install and it is upgradeable from 10 Mbps to 100 or even 1000 Mbps. 10Base-T Ethernet uses link segments up to 100 meters long to connect computers to a repeating hub, which enables the incoming signals to go out to a computer another 100 meters away, as shown in Figure 5.2. 10Base-T uses only two of the four wire pairs in the cable, one pair for transmitting data and one pair for receiving it.
Figure 5.2 UTP cables can connect Ethernet systems to a hub 100 meters away, and the hub repeats the signal to another hub or computer
The Fast Ethernet standard (IEEE 802.3u) includes two UTP cable specifications, known collectively as 100Base-T, both of which retain the 100-meter maximum segment length. 100Base-TX does this by requiring a higher grade of cable, Category 5 (the current industry standard), which provides better signal transmission capabilities. 100Base-T4, however, provides increased speed using the same Category 3 cable as older Ethernet and telephone networks. The difference between the two is that 100Base-TX uses only two pairs of wires, just like 10Base-T, whereas 100Base-T4 uses all four wire pairs. In addition to the transmit and receive pairs, 100Base-T4 uses the other two pairs for bidirectional communications.
Most of the physical layer specifications for Gigabit Ethernet defined in the IEEE 802.3z standard use fiber optic cable, but there is one UTP option, defined in a separate document called IEEE 802.3ab, that does not. The 1000Base-T standard, designed specifically as an upgrade for existing UTP networks with 100-meter cable segments, calls for Category 5 cable, but is better serviced by the higher performance cables now being marketed as Enhanced Category 5 or Category 5E. The Electronics Industry Association and Telecommunications Industry Association (EIA/TIA) have officially ratified the Category 5E cable rating, but the rating does not increase the performance of the cable substantially. The bandwidth of Category 5E is the same as that of Category 5, although its requirements for resistance to certain types of crosstalk are increased and some new performance parameters have been added. 1000Base-T achieves its great speed using all four wire pairs, like 100Base-T4, and by using a different signaling scheme called Pulse Amplitude Modulation-5 (PAM-5).
Fiber Optic Ethernet
Fiber optic cable has been an Ethernet physical layer option since its early days. The FOIRL was part of the DIX Ethernet II standard, and the IEEE 802.3 standards later included the 10Base-FL, 10Base-FB, and 10Base-FP specifications that were intended for various types of networks. None of these solutions were extremely popular because running a fiber optic network at 10 Mbps is a terrible waste of potential. Fiber Distributed Data Interface (FDDI, which is not a form of Ethernet) running at 100 Mbps soon became the fiber optic backbone protocol of choice. Later, Fast Ethernet arrived with its own 100 Mbps fiber optic option, 100Base-FX. 100Base-FX uses the same hardware as 10Base-FL, but it limits the length of a cable segment to 412 meters.
Gigabit Ethernet is the newest form of Ethernet, raising network transmission speed to 1000 Mbps. Gigabit Ethernet relies heavily on fiber optic cabling and provides a variety of physical layer options using different types of cable to achieve different segment lengths. Singlemode fiber cable is designed to span extremely long distances, making Gigabit Ethernet suitable for connecting distant networks or large campus backbones.
Repeating is an essential part of most Ethernet networks, and the standards include rules regarding the number of repeaters you can use on a single LAN. For the original 10-Mbps Ethernet standard, the use of repeaters is governed by the 5-4-3 rule, which states that you can have up to five cable segments, connected by four repeaters, with no more than three of these segments being mixing segments. In the days of coaxial cable networks, this meant that you could have up to three mixing segments of 500 or 185 meters each (for 10Base5 and 10Base2, respectively) populated with multiple computers and connected by two repeaters. You could also add two additional repeaters to extend the network with another two cable segments of 500 or 185 meters each, as long as these were link segments connected directly to the next repeater in line with no intervening computers, as shown in Figure 5.3. A 10Base2 network could therefore span up to 925 meters and a 10Base5 network up to 2500 meters.
Figure 5.3 Coaxial Ethernet networks consist of up to three mixing segments and two link segments, all connected by repeaters
On networks using the star topology, all of the segments are link segments, meaning that you can connect up to four repeating hubs using their uplink ports and still adhere to the 5-4-3 rule (see Figure 5.4). As long as the traffic between the two most distant computers doesn't pass through more than four hubs, the network is configured properly. Because the hubs function as repeaters, each 10Base-T cable segment can be up to 100 meters long, for a maximum network span of 500 meters.
Because Fast Ethernet networks run at higher speeds, they can't support as many hubs as 10-Mbps Ethernet. The Fast Ethernet standard defines two types of hubs, Class I and Class II, which must be marked with the appropriate Roman numeral in a circle. Class I hubs connect Fast Ethernet cable segments of different types, such as 100Base-TX to 100Base-T4 or UTP to fiber optic, whereas Class II hubs connect segments of the same type. You can have as many as two Class II hubs on a network, with a total cable length (for all three segments) of 205 meters when using UTP cable and 228 meters using fiber optic cable. Because Class I hubs must perform an additional signal translation, which slows down the transmission process, you can have only one hub on the network, with maximum cable lengths of 200 and 272 meters for UTP and fiber optic, respectively.
Figure 5.4 10Base-T Ethernet networks can have up to four repeating hubs connected together
The 1000Base-T cabling guidelines are simple. Because of the high transmission speed, only one repeater is permitted on the network. Although Gigabit Ethernet theoretically supports half-duplex operation with the use of hubs, there are no products like this on the market. All Gigabit Ethernet implementations are full-duplex and use switches to connect the network nodes together.
Figure 5.5 The Ethernet/IEEE 802.3 frame
The functions of the Ethernet frame fields are as follows:
The Destination Address and Source Address fields use the 6-byte hardware addresses coded into network interface adapters to identify systems on the network. Every network interface adapter has a unique hardware address (also called a MAC address), which consists of a 3-byte value called an organizationally unique identifier (OUI), which is assigned to the adapter's manufacturer by the IEEE, plus another 3-byte value assigned by the manufacturer itself.
Ethernet, like all data-link layer protocols, is concerned only with transmitting packets to another system on the local network. If the packet's final destination is another system on the LAN, the Destination Address field contains the address of that system's network adapter. If the packet is destined for a system on another network, the Destination Address field contains the address of a router on the local network that provides access to the destination network. It is then up to the network layer protocol to supply a different kind of address (such as an Internet Protocol [IP] address) for the system that is the packet's ultimate destination.
The 2-byte field after the Source Address field is the primary difference between the DIX Ethernet and IEEE 802.3 standards. For any network that uses multiple protocols at the network layer, it is essential for the Ethernet frame to somehow identify which network layer protocol has generated the data in a particular packet. The DIX Ethernet frame does this simply by specifying an Ethertype in this field, using values like those shown in Table 5.2. The IEEE 802.3 standard uses this field to specify the length of the data field.
Table 5.2 Common Ethertype Values, in Hexadecimal
IEEE 802.3 takes a different approach. In this frame, the field after the Source Address specifies the length of the data in the packet. The frame uses an additional component, the Logical Link Control (LLC), to identify the network layer protocol. The IEEE's 802 working group is not devoted solely to the development of Ethernet-like protocols. In fact, there are other protocols that fit into the IEEE 802 architecture, the most prominent of which (aside from IEEE 802.3) is IEEE 802.5, which is a Token Ring-like protocol. To make the IEEE 802 architecture adaptable to these various protocols, the data-link layer is split into two sublayers, as shown in Figure 5.6.
Figure 5.6 The IEEE 802 protocols split the data-link layer into two sublayers, the MAC layer and the LLC layer
The MAC sublayer is the part that contains the elements particular to the IEEE 802.3 specification, such as the Ethernet physical layer options, the frame, and the CSMA/CD MAC mechanism. The functions of the LLC sublayer are defined in a separate document, published as IEEE 802.2. This same LLC sublayer is also used with the MAC sublayers of other IEEE 802 protocols, such as 802.5.
The LLC standard defines an additional 3-byte or 4-byte subheader that is carried within the Data field, which contains service access points (SAPs) for the source and destination systems. These SAPs identify locations in memory where the source and destination systems store the packet data. To provide the same function as the Ethertype field, the LLC subheader can use a SAP value of 170, which indicates that the Data field also contains a second subheader called the Subnetwork Access Protocol (SNAP). The SNAP subheader is 5 bytes long and contains a 2-byte Local Code that performs the same function as the Ethertype field in the Ethernet II header.
It is typical for computers on a Transmission Control Protocol/Internet Protocol (TCP/IP) network to use the Ethernet II frame because the Ethertype field performs the same function as the LLC and SNAP subheaders and saves 8 to 9 bytes per packet. Microsoft Windows servers and clients automatically negotiate a common frame type when communicating, and when you install a Novell NetWare server, you can select the frame type you want to use. There are two crucial factors to be aware of when it comes to Ethernet frame types. First, computers must use the same frame type to communicate. Second, if you are using multiple network layer protocols on your network, such as TCP/IP for Windows networking and IPX for NetWare, you must use a frame type that contains an Ethertype or its functional equivalent, such as Ethernet II or Ethernet SNAP.
When an Ethernet system has data to transmit, it first listens to the network to see if it is in use by another system. This is the carrier sense phase. If the network is busy, the system does nothing for a given period and then checks again. If the network is free, the system transmits the data packet. This is called the multiple access phase because all of the systems on the network are contending for access to the same network medium.
Run the CSMA video located in the Demos folder on the CD-ROM accompanying this book for a demonstration of the carrier sense and multiple access phases.
Even though an initial check is performed during the carrier sense phase, it is still possible for two systems on the network to transmit at the same time, causing a collision. For example, when a system performs the carrier sense, another computer has already begun transmitting, but its signal has not yet reached the sensing system. The second computer then transmits and the two packets collide somewhere on the cable. When a collision occurs, both packets are discarded and the systems must retransmit them. These collisions are a normal and expected part of Ethernet networking, and they are not a problem unless there are too many of them or the computers are unable to detect them.
Run the Collision video located in the Demos folder on the CD-ROM accompanying this book for a demonstration of a collision.
The collision detection phase of the transmission process is the most important part of the operation. If the systems can't tell when their packets collide, corrupted data may reach the destination system and be treated as valid. Ethernet networks are designed so that packets are large enough to fill the entire network cable with signals before the last bit leaves the transmitting computer. This is why Ethernet packets must be at least 64 bytes long, systems pad out short packets to 64 bytes before transmission, and the Ethernet physical layer guidelines impose strict limitations on the lengths of cable segments.
As long as a computer is still in the process of transmitting, it is capable of detecting a collision on the network. On a UTP or fiber optic network, a computer assumes that a collision has occurred if it detects signals on both its transmit and receive wires at the same time. On a coaxial network, a voltage spike indicates the occurrence of a collision. If the network cable is too long or if the packet is too short, a system might finish transmitting before the collision occurs.
When a system detects a collision, it immediately stops transmitting data and starts sending a jam pattern instead. The jam pattern serves as a signal to each system on the network that a collision has taken place, that it should discard any partial packets it may have received, and that it should not attempt to transmit any data until the network has cleared. After transmitting the jam pattern, the system waits a specified period of time before attempting to transmit again. This is called the backoff period, and both of the systems involved in a collision compute the length of their own backoff periods using a randomized algorithm called truncated binary exponential backoff. They do this to try to avoid causing another collision by backing off for the same period of time.
Because of the way CSMA/CD works, the more systems you have on a network or the more data the systems transmit over the network, the more collisions there are. Collisions are a normal part of Ethernet operation, but they cause delays, because systems have to retransmit packets. When the number of collisions is minimal, the delays aren't noticeable, but when network traffic increases, the number of collisions increases, and the accumulated delays can begin to have a palpable effect on network performance. For this reason, it is not a good idea to run an Ethernet network at high traffic levels. You can reduce the traffic on the network by installing a bridge or switch or by splitting it into two LANs and connecting them with a router.
Using CSMA/CD may seem to be an inefficient way of controlling access to the network medium, but the process by which the systems contend for access to the network and recover from collision occurs many times per second, so rapidly that the delays caused by a moderate number of collisions are negligible.
Run the Contention video located in the Demos folder on the CD-ROM accompanying this book for a demonstration of how Ethernet systems contend for access to the network.