CH-6: Local and Wide Area Networks

Download as pdf or txt
Download as pdf or txt
You are on page 1of 10

Chapter 6: Local and Wide Area Networks

6.1. LAN Technologies


A local area network (LAN) is a computer network that is designed for a limited geographic area such
as a building or a campus. Although a LAN can be used as an isolated network to connect computers in
an organization for the sole purpose of sharing resources, most LANs today are also linked to a wide
area network (WA N) or the Internet.

LAN market has seen several technologies such as Ethernet, token ring, token bus, FDDI, and ATM
LAN. Some of these technologies survived for a while, but Ethernet is by far the dominant technology.

In this section, we first briefly discuss the IEEE Standard Project 802, designed to regulate the
manufacturing and interconnectivity between different LANs. We then concentrate on the Ethernet
LANs. Although Ethernet has gone through a four-generation evolution during the last few decades, the
main concept has remained the same. Ethernet has changed to meet the market needs and to make use
of the new technologies.

6.2. IEEE Standards


In 1985, the Computer Society of the IEEE started a project, called Project 802, to set standards to
enable intercommunication among equipment from a variety of manufacturers. Project 802 does not
seek to replace any part of the OSI or the Internet model. Instead, it is a way of specifying functions of
the physical layer and the data link layer of major LAN protocols.

The standard was adopted by the American National Standards Institute (ANSI). In 1987, the
International Standards Organization (ISO) also approved it as an international standard under the
designation ISO 8802.

The relationship of the 802 Standard to the traditional OSI model is shown in Figure 6.1. The IEEE has
subdivided the data link layer into two sub-layers: Logical Link Control (LLC) and Media Access
Control (MAC) . IEEE has also created several physical layer standards for different LAN protocols.

Figure 6.1. IEEE standard for LANs

1
In this text, however, we treat physical and data link layer together as the underlying technology
supporting other layers in the TCP/IP protocol suite.

6.2.1. Frame Format


The packet sent in an Ethernet LAN is called a frame. In this section we discuss the format and the
length of the frame that is used in our versions of the Ethernet.

The Ethernet frame contains seven fields: preamble, SFD , DA , SA , length or type of data unit, upper-
layer data, and the CRC. Ethernet does not provide any mechanism for acknowledging received frames,
making it what is known as an unreliable medium. Acknowledgments must be implemented at the
higher layers. The format of the MAC frame is shown in Figure 6.2.

Figure 6.2. Ethernet frame

➢ Preamble: The first field of 802.3 frame contains 7 bytes (56 bits) of alternating 0s and 1s that
alerts the receiving system to the coming frame and enables it to synchronize its input timing.
The pattern provides only an alert and a timing pulse. The 56-bit pattern allows the stations to
miss some bits at the beginning of the frame. The preamble is actually added at the physical
layer and is not (formally) part of the frame.
➢ Start frame delimiter (SFD): The second field (1 byte: 10101011) signals the beginning of the
frame. The SFD warns the station or stations that this is the last chance for synchronization. The
last 2 bits are 11 and alert the receiver that the next field is the destination address. The SFD is
also added at the physical layer.
➢ Destination address (DA): The DA field is 6 bytes and contains the physical address of the
destination station or stations to receive the packet.
➢ Source address (SA): it is 6 bytes and contains the physical address of the sender of the packet.
➢ Length or type: IEEE standard used it as length to define the number of bytes in the data field.
➢ Data: This field carries data encapsulated from the upper-layer protocols. It is a minimum of 46
and a maximum of 1500 bytes.
➢ CRC: The last field contains error detection information.

6.2.2. Frame Length


Ethernet has imposed restrictions on both the minimum and maximum lengths of a frame, as shown in
Figure 6.3.

2
Figure 6.3. Minimum and maximum length

The minimum length restriction is required for the correct operation of CSMA/CD. An Ethernet frame
needs to have a minimum length of 512 bits or 64 bytes. Part of this length is the header and the trailer.
If we count 18 bytes of header and trailer (6 bytes of SA, 6 bytes of DA, 2 bytes of length/type, and 4
bytes of CRC), then the minimum length of data from the upper layer is 64 − 18 = 46 bytes. If the
upper-layer packet is less than 46 bytes, padding is added to make up the difference.

The standard defines the maximum length of a frame (without preamble and SFD field) as 1518 bytes.
If we subtract the 18 bytes of header and trailer, the maximum length of the payload is 1500 bytes. The
maximum length restriction has two historical reasons. First, memory was very expensive when
Ethernet was designed: a maximum length restriction helped to reduce the size of the buffer. Second,
the maximum length restriction prevents one station from monopolizing the shared medium, blocking
other stations that have data to send.
NOTE:
Minimum length: 64 bytes (512 bits)
Maximum length: 1518 bytes (12,144 bits)

6.2.3. Ethernet Evolution


Ethernet was created in 1976 at Xerox’s Palo Alto Research Center (PARC). Since then, it has gone
through four generations: Standard Ethernet (10 Mbps), Fast Ethernet (100 Mbps), Gigabit Ethernet (1
Gbps), and Ten Gigabit Ethernet (10 Gbps), as shown in Figure 6.4. We briefly discuss all these
generations starting with the first, Standard (or traditional) Ethernet.

Figure 6.4. Ethernet evolution through four generations

3
1. Standard Ethernet
The original Ethernet with 10-Mbps data rate is now history, but we briefly discuss its characteristics to
pave the way for understanding other Ethernet versions.

Access Method: CSMA/CD: The IEEE 802.3 standard defines Carrier Sense Multiple Access with
Collision Detection (CSMA/CD) as the access method for traditional Ethernet. Stations on a traditional
Ethernet can be connected together using a physical bus or star topology, but the logical topology is
always a bus. By this, we mean that the medium is shared between stations and only one station at a
time can use it. It also implies that all stations receive a frame sent by a station (broadcasting). The real
destination keeps the frame while the rest drop it. In this situation, how can we be sure that two stations
are not using the medium at the same time? If they do, their frames will collide with each other.

To minimize the chance of collision and, therefore, increase the performance, the CSMA method was
developed. The chance of collision can be reduced if a station senses the medium before trying to use
it. Carrier sense multiple access (CSMA) requires that each station first listen to the medium (or check
the state of the medium) before sending. In other words, CSMA is based on the principle “sense before
transmit” or “listen before talk.” CSMA can reduce the possibility of collision, but it cannot eliminate
it, since the stations are connected to a shared channel (usually a dedicated medium).

Minimum Frame Size: For CSMA /CD to work, we need a restriction on the frame size. Before
sending the last bit of the frame, the sending station must detect a collision, if any, and abort the
transmission. It is because the station, once the entire frame is sent, does not keep a copy of the frame
and does not monitor the line for collision detection. Therefore, the frame transmission time Tfr must be
at least two times the maximum propagation time Tp. To understand the reason, let us think about the
worst-case scenario. If the two stations involved in a collision are the maximum distance apart, the
signal from the first takes time Tp to reach the second, and the effect of the collision takes another time
TP to reach the first. So the requirement is that the first station must still be transmitting after 2Tp.

Example 6.1: In the standard Ethernet, if the maximum propagation time is 25.6 μs, what is the
minimum size of the frame?

Solution: The frame transmission time is Tfr = 2 × Tp = 51.2 μs. This means, in the worst case, a station
needs to transmit for a period of 51.2 μs to detect the collision. The minimum size of the frame is 10
Mbps × 51.2 μs = 512 bits or 64 bytes. This is actually the minimum size of the frame for Standard
Ethernet, as we discussed before.

Implementation: The Standard Ethernet defined several implementations, but only four of them
became popular during ’80s. Table 6.1 shows summary of Standard Ethernet implementations. In the
nomenclature 10Base-X, the number defines the data rate (10 Mbps), the term Base means baseband

4
(digital) signal, and X approximately defines either the maximum size of the cable in 100 meters (for
example 5 for 500 or 2 for 185 meters) or the type of the cable, T for unshielded twisted pair cable
(UTP) and F for fiber-optic.
Characteristics 10Base5 10Base2 10Base-T 10Base-F
Medium Thick coax Thin coax 2 UTP 2 Fiber
Maximum length 500 m 185 m 100 m 2000 m
Table 6.1. Summary of Standard Ethernet implementations

2. Fast Ethernet
Fast Ethernet is backward-compatible with Standard Ethernet, but it can transmit data 10 times faster at
a rate of 100 Mbps. The goals of Fast Ethernet can be summarized as follows:
1) Upgrade the data rate to 100 Mbps.
2) Make it compatible with Standard Ethernet
3) Keep the same 48-bit address.
4) Keep the same frame format.
5) Keep the same minimum and maximum frame lengths.

MAC Sublayer: A main consideration in the evolution of Ethernet from 10 to 100 M bps was to keep
the MAC sublayer untouched. However, a decision was made to drop the bus topologies and keep only
the star topology. For the star topology, there are two choices: half-duplex and full-duplex. In the half-
duplex approach, the stations are connected via a hub; in the full-duplex approach, the connection is
made via a switch with buffers at each port.

The access method is the same (CSMA/CD) for half-duplex approach; for full-duplex Fast Ethernet,
there is no need for CSMA/CD. However, the implementations keep CSMA/CD for backward
compatibility with Standard Ethernet.

Autonegotiation: A new feature added to Fast Ethernet is called autonegotiation. It allows a station or
a hub a range of capabilities. Autonegotiation allows two devices to negotiate the mode or data rate of
operation. It was designed particularly for the following purposes:
➢ To allow incompatible devices to connect to one another. For example, a device with a
maximum capacity of 10 Mbps can communicate with a device with a 100 Mbps capacity (but
can work at a lower rate).
➢ To allow one device to have multiple capabilities.
➢ To allow a station to check a hub’s capabilities.

Implementation: Fast Ethernet implementation at the physical layer can be categorized as either two-
wire or four-wire. The two-wire implementation can be either shielded twisted pair, STP (100Base-TX)

5
or fiber-optic cable (100Base-FX). The four-wire implementation is designed only for unshielded twist
pair, UTP (100Base-T4). Table 6.2 is a summary of the Fast Ethernet implementations.

Characteristics 100Base-TX 100Base-FX 10Base-T


Medium STP Fiber UTP
Number of wires 2 2 4
Maximum length 100 m 100 m 100 m
Table 6.2. Summary of Fast Ethernet implementations

3. Gigabit Ethernet
The need for an even higher data rate resulted in the design of the Gigabit Ethernet Protocol (1000
Mbps). The IEEE committee calls the Standard 802.3z. The goals of the Gigabit Ethernet design can be
summarized as follows:
1) Upgrade the data rate to 1 Gbps.
2) Make it compatible with Standard or Fast Ethernet
3) Use the same 48-bit address.
4) Use the same frame format.
5) Keep the same minimum and maximum frame lengths.
6) To support autonegotiation as defined in Fast Ethernet.

MAC Sublayer: A main consideration in the evolution of Ethernet was to keep the MAC sublayer
untouched. However, to achieve a data rate of 1 Gbps, this was no longer possible. Gigabit Ethernet has
two distinctive approaches for medium access: half-duplex and full-duplex. Almost all implementations
of Gigabit Ethernet follow the full-duplex approach. However, we briefly discuss the half-duplex
approach to show that Gigabit Ethernet can be compatible with the previous generations.

Full-Duplex Mode: In full-duplex mode, there is a central switch connected to all computers or other
switches. In this mode, each switch has buffers for each input port in which data are stored until they
are transmitted. There is no collision in this mode. This means that CSMA/CD is not used. Lack of
collision implies that the maximum length of the cable is determined by the signal attenuation in the
cable, not by the collision detection process.
NOTE:
In the full-duplex mode of Gigabit Ethernet, there is no collision; the maximum
length of the cable is determined by the signal attenuation in the cable.

Half-Duplex Mode: Gigabit Ethernet can also be used in half-duplex mode, although it is rare. In this
case, a switch can be replaced by a hub, which acts as the common cable in which a collision might

6
occur. The half-duplex approach uses CSMA/CD.

Implementation: Table 6.3 is a summary of the Gigabit Ethernet implementations.

Characteristics 1000Base-SX 1000Base-LX 1000Base-CX 1000Base-T4


Medium Fiber short-wave Fiber long-wave STP Cat 5 UTP
Number of wires 2 2 2 4
Maximum length 550 m 5000 m 25 m 100 m
Table 6.3. Summary of Gigabit Ethernet implementations

4. Ten-Gigabit Ethernet
The IEEE committee created Ten-Gigabit Ethernet and called it Standard 802.3ae. The goals of the
Ten-Gigabit Ethernet design can be summarized as follows:
1) Upgrade the data rate to 10 Gbps.
2) Make it compatible with Standard Ethernet, Fast Ethernet, and Gigabit Ethernet.
3) Use the same 48-bit address.
4) Use the same frame format.
5) Keep the same minimum and maximum frame lengths.
6) Allow the interconnection of existing LANs into a metropolitan area network (MAN) or a wide
area network (WAN).
7) Make Ethernet compatible with technologies such as Frame Relay and ATM.

Implementation: Ten-Gigabit Ethernet operates only in full duplex mode, which means there is no
need for contention; CSMA/CD is not used in Ten-Gigabit Ethernet. Three implementations are the
most common: 10GBase-S, 10GBase-L, and 10GBase-E. Table 6.4 shows a summary of the Ten-
Gigabit Ethernet implementation.

Characteristics 10GBase-S 10GBase-L 10GBase-E


Medium multi-mode fiber single-mode fiber single-mode fiber
Number of wires 2 2 2
Maximum length 300 m 10,000 m 40,000 m
Table 6.4. Summary of Ten-Gigabit Ethernet implementations

6.3. Token Ring


A wide range of different local area network technologies were developed in the early 1970s, of which
one, the Cambridge Ring had demonstrated the potential of a token passing ring topology, and many
teams worldwide began working on their own implementations. Token Ring local area network (LAN)

7
technology is a communications protocol for local area networks. It uses a special three-byte frame
called a "token" that travels around a logical "ring" of workstations or servers. This token passing is a
channel access method providing fair access for all stations, and eliminating the collisions of
contention-based access methods.

IBM launched their own proprietary Token Ring product on October 15, 1985. It ran at 4 Mbps, and
attachment was possible from IBM PCs, midrange computers and mainframes. It used a convenient
star-wired physical topology, and ran over shielded twisted-pair (STP) cabling, and shortly thereafter
became the basis for the (ANSI)/IEEE standard 802.5.

6.3.1. Comparison with Ethernet


Ethernet and Token ring have some notable differences:
➢ Ethernet supports a direct cable connection between two network interface cards by the use of a
crossover cable. Token ring does not inherently support this feature and requires additional
software and hardware to operate on a direct cable connection setup.
➢ Token Ring eliminates collision by the use of a single-use token and early token release to
alleviate the down time. Ethernet alleviates collision by carrier sense multiple access and by the
use of an intelligent switch; primitive Ethernet devices like hubs can precipitate collisions due
to repeating traffic blindly.
➢ Token Ring employs 'access priority' in which certain nodes can have priority over the token.
Unswitched Ethernet does not have provisioning for an access priority system as all nodes have
equal contest for traffic.
➢ Multiple identical MAC addresses are supported on Token Ring (a feature used by S/390
mainframes). Switched Ethernet cannot support duplicate MAC addresses.
➢ Token Ring was more complex than Ethernet, requiring a specialized processor and licensed
MAC/LLC firmware for each interface. By contrast, Ethernet included both the (simpler)
firmware and the lower licensing cost in the MAC chip. The cost of a Token Ring interface is
approximately three times greater than that of an Ethernet interface.
➢ Initially both networks used expensive cable, but once Ethernet was standardized for unshielded
twisted pair (UTP) with 10BASE-T (Cat 3) and 100BASE-TX (Cat 5(e)), it had a distinct
advantage and sales of it increased markedly.
➢ Token ring frames may contain as many as 17,800 bytes of information, which is significantly
more than the 1500 bytes of user data in an Ethernet frame. A negotiation process is required by
token ring stations to determine the maximum frame size they can use, but most
implementations end up using larger frames than Ethernet implementations, which is more
efficient when transferring large volumes of data.

8
6.3.2. Operation
Stations on a token ring LAN are logically organized in a ring topology with data being transmitted
sequentially from one ring station to the next with a control token circulating around the ring
controlling access. A Token Ring network can be modeled as a polling system where a single server
provides service to queues in a cyclic order.

The token-passing protocol for ring access control is based on a predefined 24-bit (3-byte) pattern,
called a token, which continuously circulates around the ring.

When a station has data to transmit, it waits until its station adapter receives a free token (token bit= 0).
Upon capturing the free token, the station creates a frame by setting the token bit to 1. It then inserts
source and destination addresses (MAC addresses), certain control information and the data to be sent
to the destination station, and starts frame transmission.

During the time the frame is being transmitted, no token is available on the ring and no other station
can initiate a transmission. Thus, collisions on the ring are avoided. The frame is passed (received,
regenerated and retransmitted) from one station to another on the ring until it is received by a station
with a matching destination address.

The destination station copies the data to its internal buffers, sets control bits to indicate that it
recognized the address and successfully copied the data, and retransmits the frame.

When the frame returns to the source station following successful transmission and receipt, it is
removed from the ring. The source station creates a new free token and transmits it on the ring, thereby
allowing other stations access. Until the source station releases a free token, the rest of the stations are
unable to transmit.

To reduce the amount of time a station has to wait for a free token, a function, known as Early Token
Release is available. With Early Token Release, a sending station releases a free token following frame
transmission without waiting for the transmitted frame to return. This enhances the utilization of the
ring by allowing one token and one or more frames to circulate on the network at the same time.

6.3.3. Frame types


Token: When no station is sending a frame, a special token frame circles the loop. This special token
frame is repeated from station to station until arriving at a station that needs to send data. Tokens are 3
bytes in length and consist of a start delimiter, an access control byte, and an end delimiter.

9
Start Delimiter Access Control End Delimiter
8-bits 8-bits 8-bits
Table 6.5. Token frame

Abort frame: Used to abort transmission by the sending station


Start Delimiter End Delimiter
8-bits 8-bits
Table 6.6. Abort frame

Data: Data frames carry information for upper-layer protocols, while command frames contain control
information and have no data for upper-layer protocols. Data/command frames vary in size, depending
on the size of the Information field.

SD AC FC DA SA PDU from LLC (IEEE 802.2) CRC ED FS


8 bits 8 bits 8 bits 48 bits 48 bits up to 4500x8 bits 32 bits 8 bits 8 bits
Table 6.7. Data frame

➢ Starting delimiter (SD) and Ending delimiter (ED): Both the Starting Delimiter and Ending
Delimiter fields are used to mark frame boundaries.
➢ Access control (AC): This byte field consists of the following bits: the first three bits are
priority bits, the fourth bit is the token bit which when set specifies that this is a token frame, the
fifth bit is the monitor bit which is set by the Active Monitor (AM) station when it sees this
frame, and the last three bits are reserved bits.
➢ Frame control (FC): A one byte field that contains bits describing the data portion of the frame
contents which indicates whether the frame contains data or control information.
➢ Destination address (DA): A six byte field used to specify the destination(s) physical address.
➢ Source address (SA): Contains physical address of sending station.
➢ Data: A variable length field of 0 or more bytes, the maximum allowable size depending on
ring speed containing MAC management data or upper layer information. Maximum length of
4500 bytes.
➢ Frame check sequence (CRC): A four byte field used to store the calculation of a CRC for
frame integrity verification by the receiver.
➢ Frame status (FS): A one byte field used as a primitive acknowledgement scheme on whether
the frame was recognized and copied by its intended receiver.

10

You might also like