An Overview of Modern Ethernet LANs The term Ethernet refers to a family of standards that together define the physical and data link layers of the world’s most popular type of LAN.. Mo
Trang 1This chapter explains some of the basics of local-area networks (LAN) The term LAN refers to a set of Layer 1 and 2 standards designed to work together for the purpose of implementing geographically small networks This chapter introduces the concepts of LANs—in particular, Ethernet LANs More-detailed coverage of LANs appears in Part II (Chapters 7 through 11).
“Do I Know This Already?” Quiz
The “Do I Know This Already?” quiz allows you to assess whether you should read the entire chapter If you miss no more than one of these 11 self-assessment questions, you might want to move ahead to the “Exam Preparation Tasks” section Table 3-1 lists the major headings in this chapter and the “Do I Know This Already?” quiz questions covering the material in those sections This helps you assess your knowledge of these specific areas The answers to the “Do I Know This Already?” quiz appear in Appendix A
Table 3-1 “Do I Know This Already?” Foundation Topics Section-to-Question Mapping
An Overview of Modern Ethernet LANs 1
Improving Performance by Using Switches Instead of Hubs 5–7
Ethernet Data-Link Protocols 8–11
Trang 21. Which of the following is true about the cabling of a typical modern Ethernet LAN?
a. Connect each device in series using coaxial cabling
b. Connect each device in series using UTP cabling
c. Connect each device to a centralized LAN hub using UTP cabling
d. Connect each device to a centralized LAN switch using UTP cabling
2. Which of the following is true about the cabling of a 10BASE2 Ethernet LAN?
a. Connect each device in series using coaxial cabling
b. Connect each device in series using UTP cabling
c. Connect each device to a centralized LAN hub using UTP cabling
d. Connect each device to a centralized LAN switch using UTP cabling
3. Which of the following is true about Ethernet crossover cables?
a. Pins 1 and 2 are reversed on the other end of the cable
b. Pins 1 and 2 on one end of the cable connect to pins 3 and 6 on the other end of the cable
c. Pins 1 and 2 on one end of the cable connect to pins 3 and 4 on the other end of the cable
d. The cable can be up to 1000 meters long to cross over between buildings
e. None of the other answers is correct
4. Each answer lists two types of devices used in a 100BASE-TX network If these devices were connected with UTP Ethernet cables, which pairs of devices would require a straight-through cable?
a. PC and router
b. PC and switch
c. Hub and switch
d. Router and hub
e. Wireless access point (Ethernet port) and switch
Trang 3“Do I Know This Already?” Quiz 43
5. Which of the following is true about the CSMA/CD algorithm?
a. The algorithm never allows collisions to occur
b. Collisions can happen, but the algorithm defines how the computers should notice a collision and how to recover
c. The algorithm works with only two devices on the same Ethernet
d. None of the other answers is correct
6. Which of the following is a collision domain?
a. All devices connected to an Ethernet hub
b. All devices connected to an Ethernet switch
c. Two PCs, with one cabled to a router Ethernet port with a crossover cable and the other PC cabled to another router Ethernet port with a crossover cable
d. None of the other answers is correct
7. Which of the following describe a shortcoming of using hubs that is improved by instead using switches?
a. Hubs create a single electrical bus to which all devices connect, causing the devices to share the bandwidth
b. Hubs limit the maximum cable length of individual cables (relative to switches)
c. Hubs allow collisions to occur when two attached devices send data at the same time
d. Hubs restrict the number of physical ports to at most eight
8. Which of the following terms describe Ethernet addresses that can be used to communicate with more than one device at a time?
a. Burned-in address
b. Unicast address
c. Broadcast address
d. Multicast address
Trang 49. Which of the following is one of the functions of OSI Layer 2 protocols?
a. Framing
b. Delivery of bits from one device to another
c. Error recovery
d. Defining the size and shape of Ethernet cards
10. Which of the following are true about the format of Ethernet addresses?
a. Each manufacturer puts a unique code into the first 2 bytes of the address
b. Each manufacturer puts a unique code into the first 3 bytes of the address
c. Each manufacturer puts a unique code into the first half of the address
d. The part of the address that holds this manufacturer’s code is called the MAC
e. The part of the address that holds this manufacturer’s code is called the OUI
f. The part of the address that holds this manufacturer’s code has no specific name
11. Which of the following is true about the Ethernet FCS field?
a. It is used for error recovery
b. It is 2 bytes long
c. It resides in the Ethernet trailer, not the Ethernet header
d. It is used for encryption
e. None of the other answers is correct
Trang 5An Overview of Modern Ethernet LANs 45
Foundation Topics
A typical Enterprise network consists of several sites The end-user devices connect to a LAN, which allows the local computers to communicate with each other Additionally, each site has a router that connects to both the LAN and a wide-area network (WAN), with the WAN providing connectivity between the various sites With routers and a WAN, the computers at different sites can also communicate
This chapter describes the basics of how to create LANs today, with Chapter 4,
“Fundamentals of WANs,” describing the basics of creating WANs Ethernet is the undisputed king of LAN standards today Historically speaking, several competing LAN standards existed, including Token Ring, Fiber Distributed Data Interface (FDDI), and Asynchronous Transfer Mode (ATM) Eventually, Ethernet won out over all the competing LAN standards, so that today when you think of LANs, no one even questions what type—
it’s Ethernet
An Overview of Modern Ethernet LANs
The term Ethernet refers to a family of standards that together define the physical and data
link layers of the world’s most popular type of LAN The different standards vary as to the speed supported, with speeds of 10 megabits per second (Mbps), 100 Mbps, and 1000 Mbps (1 gigabit per second, or Gbps) being common today The standards also differ as far as the types of cabling and the allowed length of the cabling For example, the most commonly
used Ethernet standards allow the use of inexpensive unshielded twisted-pair (UTP)
cabling, whereas other standards call for more expensive fiber-optic cabling Fiber-optic cabling might be worth the cost in some cases, because the cabling is more secure and allows for much longer distances between devices To support the widely varying needs for building a LAN—needs for different speeds, different cabling types (trading off distance requirements versus cost), and other factors—many variations of Ethernet standards have been created
The Institute of Electrical and Electronics Engineers (IEEE) has defined many Ethernet standards since it took over the LAN standardization process in the early 1980s Most of the standards define a different variation of Ethernet at the physical layer, with differences
in speed and types of cabling Additionally, for the data link layer, the IEEE separates the functions into two sublayers:
■ The 802.3 Media Access Control (MAC) sublayer
■ The 802.2 Logical Link Control (LLC) sublayer
Trang 6In fact, MAC addresses get their name from the IEEE name for this lower portion of the data link layer Ethernet standards.
Each new physical layer standard from the IEEE requires many differences at the physical layer However, each of these physical layer standards uses the exact same 802.3 header, and each uses the upper LLC sublayer as well Table 3-2 lists the most commonly used IEEE Ethernet physical layer standards
The table is convenient for study, but the terms in the table bear a little explanation First,
beware that the term Ethernet is often used to mean “all types of Ethernet,” but in some
cases it is used to mean “10BASE-T Ethernet.” (Because the term Ethernet sometimes can
be ambiguous, this book refers to 10-Mbps Ethernet as 10BASE-T when the specific type
of Ethernet matters to the discussion.) Second, note that the alternative name for each type
of Ethernet lists the speed in Mbps—namely, 10 Mbps, 100 Mbps, and 1000 Mbps The T and TX in the alternative names refer to the fact that each of these standards defines the use
of UTP cabling, with the T referring to the T in twisted pair.
To build and create a modern LAN using any of the UTP-based types of Ethernet LANs listed in Table 3-2, you need the following components:
■ Computers that have an Ethernet network interface card (NIC) installed
■ Either an Ethernet hub or Ethernet switch
■ UTP cables to connect each PC to the hub or switch
Figure 3-1 shows a typical LAN The NICs cannot be seen, because they reside in the PCs However, the lines represent the UTP cabling, and the icon in the center of the figure represents a LAN switch
Table 3-2 Today’s Most Common Types of Ethernet
Common Name Speed
Alternative Name
Name of IEEE Standard
Cable Type, Maximum Length
Ethernet 10 Mbps 10BASE-T IEEE 802.3 Copper, 100 m
Fast Ethernet 100 Mbps 100BASE-TX IEEE 802.3u Copper, 100 m Gigabit Ethernet 1000 Mbps 1000BASE-LX,
1000BASE-SX
IEEE 802.3z Fiber, 550 m (SX)
5 km (LX) Gigabit Ethernet 1000 Mbps 1000BASE-T IEEE 802.3ab 100 m
Trang 7An Overview of Modern Ethernet LANs 47
Figure 3-1 Typical Small Modern LAN
Most people can build a LAN like the one shown in Figure 3-1 with practically no real knowledge of how LANs work Most PCs contain an Ethernet NIC that was installed at the factory Switches do not need to be configured for them to forward traffic between the computers All you have to do is connect the switch to a power cable and plug in the UTP cables from each PC to the switch Then the PCs should be able to send Ethernet frames to each other
You can use such a small LAN for many purposes, even without a WAN connection
Consider the following functions for which a LAN is the perfect, small-scale solution:
File sharing: Each computer can be configured to share all or parts of its file system
so that the other computers can read, or possibly read and write, the files on anothercomputer This function typically is simply part of the PC operating system
Printer sharing: Computers can share their printers as well For example, PCs A, B,
and C in Figure 3-1 could print documents on PC D’s printer This function is alsotypically part of the PC’s operating system
File transfers: A computer could install a file transfer server, thereby allowing other
computers to send and receive files to and from that computer For example, PC Ccould install File Transfer Protocol (FTP) server software, allowing the other PCs touse FTP client software to connect to PC C and transfer files
Gaming: The PCs could install gaming software that allows multiple players
to play in the same game The gaming software would then communicate using the Ethernet
NOTE Figure 3-1 applies to all the common types of Ethernet The same basic design and topology are used regardless of speed or cabling type
Printer Cable
Trang 8The goal of the first half of this chapter is to help you understand much of the theory and practical knowledge behind simple LAN designs such as the one illustrated in Figure 3-1
To fully understand modern LANs, it is helpful to understand a bit about the history of Ethernet, which is covered in the next section Following that, this chapter examines the physical aspects (Layer 1) of a simple Ethernet LAN, focusing on UTP cabling Then this chapter compares the older (and slower) Ethernet hub with the newer (and faster) Ethernet switch Finally, the LAN coverage in this chapter ends with the data-link (Layer 2) functions on Ethernet
A Brief History of Ethernet
Like many early networking protocols, Ethernet began life inside a corporation that was looking to solve a specific problem Xerox needed an effective way to allow a new invention, called the personal computer, to be connected in its offices From that, Ethernet was born (Go to http://inventors.about.com/library/weekly/aa111598.htm for an
interesting story on the history of Ethernet.) Eventually, Xerox teamed with Intel and Digital Equipment Corp (DEC) to further develop Ethernet, so the original Ethernet
became known as DIX Ethernet, referring to DEC, Intel, and Xerox.
These companies willingly transitioned the job of Ethernet standards development to the IEEE
in the early 1980s The IEEE formed two committees that worked directly on Ethernet—the IEEE 802.3 committee and the IEEE 802.2 committee The 802.3 committee worked on
physical layer standards as well as a subpart of the data link layer called Media Access Control (MAC) The IEEE assigned the other functions of the data link layer to the 802.2 committee, calling this part of the data link layer the Logical Link Control (LLC) sublayer (The 802.2
standard applied to Ethernet as well as to other IEEE standard LANs such as Token Ring.)
The Original Ethernet Standards: 10BASE2 and 10BASE5
Ethernet is best understood by first considering the two early Ethernet specifications, 10BASE5 and 10BASE2 These two Ethernet specifications defined the details of the physical and data link layers of early Ethernet networks (10BASE2 and 10BASE5 differ
in their cabling details, but for the discussion in this chapter, you can consider them as behaving identically.) With these two specifications, the network engineer installs a series
of coaxial cables connecting each device on the Ethernet network There is no hub, switch,
or wiring panel The Ethernet consists solely of the collective Ethernet NICs in the computers and the coaxial cabling The series of cables creates an electrical circuit, called
a bus, which is shared among all devices on the Ethernet When a computer wants to send some bits to another computer on the bus, it sends an electrical signal, and the electricity propagates to all devices on the Ethernet
Figure 3-2 shows the basic logic of an old Ethernet 10BASE2 network, which uses a single electrical bus, created with coaxial cable and Ethernet cards
Trang 9A Brief History of Ethernet 49
Figure 3-2 Small Ethernet 10BASE2 Network
The solid lines in the figure represent the physical network cabling The dashed lines with arrows represent the path that Larry’s transmitted frame takes Larry sends an electrical signal across his Ethernet NIC onto the cable, and both Bob and Archie receive the signal
The cabling creates a physical electrical bus, meaning that the transmitted signal is received
by all stations on the LAN Just like a school bus stops at every student’s house along a route, the electrical signal on a 10BASE2 or 10BASE5 network is propagated to each station on the LAN
Because the network uses a single bus, if two or more electrical signals were sent at the same time, they would overlap and collide, making both signals unintelligible So, unsurprisingly, Ethernet also defined a specification for how to ensure that only one device sends traffic on the Ethernet at one time Otherwise, the Ethernet would have been
unusable This algorithm, known as the carrier sense multiple access with collision detection (CSMA/CD) algorithm, defines how the bus is accessed.
In human terms, CSMA/CD is similar to what happens in a meeting room with many attendees It’s hard to understand what two people are saying at the same time, so generally, one person talks and the rest listen Imagine that Bob and Larry both want to reply to the current speaker’s comments As soon as the speaker takes a breath, Bob and Larry both try to speak If Larry hears Bob’s voice before Larry makes a noise, Larry might stop and let Bob speak Or, maybe they both start at almost the same time, so they talk over each other and no one can hear what is said Then there’s the proverbial “Pardon me; go ahead with what you were saying,” and eventually Larry or Bob talks Or perhaps another person jumps in and talks while Larry and Bob are both backing off These “rules” are based on your culture; CSMA/
CD is based on Ethernet protocol specifications and achieves the same type of goal
Basically, the CSMA/CD algorithm can be summarized as follows:
■ A device that wants to send a frame waits until the LAN is silent—in other words, no frames are currently being sent—before attempting to send an electrical signal
■ If a collision still occurs, the devices that caused the collision wait a random amount
of time and then try again
Trang 10In 10BASE5 and 10BASE2 Ethernet LANs, a collision occurs because the transmitted electrical signal travels along the entire length of the bus When two stations send at the same time, their electrical signals overlap, causing a collision So, all devices on a 10BASE5 or 10BASE2 Ethernet need to use CSMA/CD to avoid collisions and to recover when inadvertent collisions occur
In some cases, the maximum cable length was not enough, so a device called a repeater was
developed One of the problems that limited the length of a cable was that the signal sent
by one device could attenuate too much if the cable was longer than 500 m or 185 m
Attenuation means that when electrical signals pass over a wire, the signal strength gets
weaker the farther along the cable it travels It’s the same concept behind why you can hear someone talking right next to you, but if that person speaks at the same volume and you are
on the other side of a crowded room, you might not hear her because the sound waves have attenuated
Repeaters connect to multiple cable segments, receive the electrical signal on one cable, interpret the bits as 1s and 0s, and generate a brand-new, clean, strong signal out the other cable A repeater does not simply amplify the signal, because amplifying the signal might also amplify any noise picked up along the way
You should not expect to need to implement 10BASE5 or 10BASE2 Ethernet LANs today However, for learning purposes, keep in mind several key points from this section as you move on to concepts that relate to today’s LANs:
■ The original Ethernet LANs created an electrical bus to which all devices connected
■ Because collisions could occur on this bus, Ethernet defined the CSMA/CD algorithm, which defined a way to both avoid collisions and take action when collisions occurred
■ Repeaters extended the length of LANs by cleaning up the electrical signal and repeating it—a Layer 1 function—but without interpreting the meaning of the electrical signal
NOTE Because the repeater does not interpret what the bits mean, but it does examine and generate electrical signals, a repeater is considered to operate at Layer 1
Trang 11A Brief History of Ethernet 51
Building 10BASE-T Networks with Hubs
The IEEE later defined new Ethernet standards besides 10BASE5 and 10BASE2
Chronologically, the 10BASE-T standard came next (1990), followed by 100BASE-TX (1995), and then 1000BASE-T (1999) To support these new standards, networking devices called hubs and switches were also created This section defines the basics of how these three popular types of Ethernet work, including the basic operation of hubs and switches
10BASE-T solved several problems with the early 10BASE5 and 10BASE2 Ethernet specifications 10BASE-T allowed the use of UTP telephone cabling that was already installed Even if new cabling needed to be installed, the inexpensive and easy-to-install UTP cabling replaced the old expensive and difficult-to-install coaxial cabling
Another major improvement introduced with 10BASE-T, and that remains a key design point today, is the concept of cabling each device to a centralized connection point
Originally, 10BASE-T called for the use of Ethernet hubs, as shown in Figure 3-3.
Figure 3-3 Small Ethernet 10BASE-T Network Using a Hub
When building a LAN today, you could choose to use either a hub or a switch as the centralized Ethernet device to which all the computers connect Even though modern Ethernet LANs typically use switches instead of hubs, understanding the operation of hubs helps you understand some of the terminology used with switches, as well as some of their benefits
Hubs are essentially repeaters with multiple physical ports That means that the hub simply regenerates the electrical signal that comes in one port and sends the same signal out every other port By doing so, any LAN that uses a hub, as in Figure 3-3, creates an electrical bus, just like 10BASE2 and 10BASE5 Therefore, collisions can still occur, so CSMA/CD access rules continue to be used
10BASE-T networks using hubs solved some big problems with 10BASE5 and 10BASE2
First, the LAN had much higher availability, because a single cable problem could, and probably did, take down 10BASE5 and 10BASE2 LANs With 10BASE-T, a cable connects each device to the hub, so a single cable problem affects only one device As mentioned earlier, the use of UTP cabling, in a star topology (all cables running to a centralized connection device), lowered the cost of purchasing and installing the cabling
Trang 12Today, you might occasionally use LAN hubs, but you will more likely use switches instead
of hubs Switches perform much better than hubs, support more functions than hubs, and typically are priced almost as low as hubs However, for learning purposes, keep in mind several key points from this section about the history of Ethernet as you move on to concepts that relate to today’s LANs:
■ The original Ethernet LANs created an electrical bus to which all devices connected
■ 10BASE2 and 10BASE5 repeaters extended the length of LANs by cleaning up the electrical signal and repeating it—a Layer 1 function—but without interpreting the meaning of the electrical signal
■ Hubs are repeaters that provide a centralized connection point for UTP cabling—but they still create a single electrical bus, shared by the various devices, just like 10BASE5 and 10BASE2
■ Because collisions could occur in any of these cases, Ethernet defines the CSMA/CD algorithm, which tells devices how to both avoid collisions and take action when collisions do occur
The next section explains the details of the UTP cabling used by today’s most commonly used types of Ethernet
Ethernet UTP Cabling
The three most common Ethernet standards used today—10BASE-T (Ethernet),
100BASE-TX (Fast Ethernet, or FE), and 1000BASE-T (Gigabit Ethernet, or GE)—use UTP cabling Some key differences exist, particularly with the number of wire pairs needed
in each case, and in the type (category) of cabling This section examines some of the details
of UTP cabling, pointing out differences among these three standards along the way In particular, this section describes the cables and the connectors on the ends of the cables, how they use the wires in the cables to send data, and the pinouts required for proper operation
UTP Cables and RJ-45 Connectors
The UTP cabling used by popular Ethernet standards include either two or four pairs of wires Because the wires inside the cable are thin and brittle, the cable itself has an outer jacket of flexible plastic to support the wires Each individual copper wire also has a thin plastic coating to help prevent the wire from breaking The plastic coating on each wire has
a different color, making it easy to look at both ends of the cable and identify the ends of
an individual wire
The cable ends typically have some form of connector attached (typically RJ-45 connectors), with the ends of the wires inserted into the connectors The RJ-45 connector has eight
Trang 13Ethernet UTP Cabling 53
specific physical locations into which the eight wires in the cable can be inserted, called
pin positions, or simply pins When the connectors are added to the end of the cable, the
ends of the wires must be correctly inserted into the correct pin positions
As soon as the cable has RJ-45 connectors on each end, the RJ-45 connector needs to be
inserted into an RJ-45 receptacle, often called an RJ-45 port Figure 3-4 shows photos of
the cables, connectors, and ports
Figure 3-4 RJ-45 Connectors and Ports
The figure shows three separate views of an RJ-45 connector on the left The head-on view
in the upper-left part of the figure shows the ends of the eight wires in their pin positions inside the UTP cable The upper-right part of the figure shows an Ethernet NIC that is not yet installed in a computer The RJ-45 port on the NIC would be exposed on the side of the
NOTE If you have an Ethernet UTP cable nearby, it would be useful to closely examine the RJ-45 connectors and wires as you read through this section
NOTE The RJ-45 connector is slightly wider, but otherwise similar, to the RJ-11 connectors commonly used for telephone cables in homes in North America
Trang 14computer, making it easily accessible as soon as the NIC has been installed into a computer The lower-right part of the figure shows the side of a Cisco 2960 switch, with multiple RJ-45 ports, allowing multiple devices to easily connect to the Ethernet network.
Although RJ-45 connectors and ports are popular, engineers might want to purchase Cisco LAN switches that have a few physical ports that can be changed without having to purchase a whole new switch Many Cisco switches have a few interfaces that use either Gigabit Interface Converters (GBIC) or Small-Form Pluggables (SFP) Both are small removable devices that fit into a port or slot in the switch Because Cisco manufactures a wide range of GBICs and SFPs, for every Ethernet standard, the switch can use a variety of cable connectors and types of cabling and support different cable lengths—all by just switching to a different kind of GBIC or SFP Figure 3-5 shows a 1000BASE-T GBIC, ready to be inserted into a LAN switch
Figure 3-5 1000BASE-T GBIC with an RJ-45 Connector
If a network engineer needs to use an existing switch in a new role in a campus network, the engineer could simply buy a new 1000BASE-LX GBIC to replace the old 1000BASE-T GBIC and reduce the extra cost of buying a whole new switch For example, when using a switch so that it connects only to other switches in the same building, the switch could use 1000BASE-T GBICs and copper cabling Later, if the company moved to another location, the switch could be repurposed by using a different GBIC that supported fiber-optic cabling, and different connectors, using 1000BASE-LX to support a longer cabling distance
Transmitting Data Using Twisted Pairs
UTP cabling consists of matched pairs of wires that are indeed twisted together—hence the
name twisted pair The devices on each end of the cable can create an electrical circuit using
a pair of wires by sending current on the two wires, in opposite directions When current passes over any wire, that current induces a magnetic field outside the wire; the magnetic field can in turn cause electrical noise on other wires in the cable By twisting together the
1000BASE-T GBIC Module
GBIC Module Slot Metal Flap Door
Trang 15Ethernet UTP Cabling 55
wires in the same pair, with the current running in opposite directions on each wire, the magnetic field created by one wire mostly cancels out the magnetic field created by the other wire Because of this feature, most networking cables that use copper wires and electricity use twisted pairs of wires to send data
To send data over the electrical circuit created over a wire pair, the devices use an encoding scheme that defines how the electrical signal should vary, over time, to mean either a binary
0 or 1 For example, 10BASE-T uses an encoding scheme that encodes a binary 0 as a transition from higher voltage to lower voltage during the middle of a 1/10,000,000th-of-a-second interval The electrical details of encoding are unimportant for the purposes of this book But it is important to realize that networking devices create an electrical circuit using each wire pair, and vary the signal as defined by the encoding scheme, to send bits over the wire pair
UTP Cabling Pinouts for 10BASE-T and 100BASE-TX
The wires in the UTP cable must be connected to the correct pin positions in the RJ-45 connectors in order for communication to work correctly As mentioned earlier, the RJ-45
connector has eight pin positions, or simply pins, into which the copper wires inside the cable protrude The wiring pinouts—the choice of which color wire goes into which pin
position—must conform to the Ethernet standards described in this section
Interestingly, the IEEE does not actually define the official standards for cable manufacturing, as well as part of the details of the conventions used for the cabling pinouts
Two cooperating industry groups, the Telecommunications Industry Association (TIA) and the Electronics Industry Alliance (EIA), define standards for UTP cabling, color coding for wires, and standard pinouts on the cables (See http://www.tiaonline.org and http://
www.eia.org.) Figure 3-6 shows two pinout standards from the EIA/TIA, with the color coding and pair numbers listed
Figure 3-6 EIA/TIA Standard Ethernet Cabling Pinouts