web analytics

Sending Ethernet Frames with Switches and Hubs

Ethernet LANs behave slightly differently depending on whether the LAN has mostly modern
devices, in particular, LAN switches instead of some older LAN devices called LAN
hubs. Basically, the use of more modern switches allows the use of full-duplex logic, which
is much faster and simpler than half-duplex logic, which is required when using hubs. The
final topic in this chapter looks at these basic differences.

Sending in Modern Ethernet LANs Using Full Duplex
Modern Ethernet LANs use a variety of Ethernet physical standards, but with standard
Ethernet frames that can flow over any of these types of physical links. Each individual
link can run at a different speed, but each link allows the attached nodes to send the bits in
the frame to the next node. They must work together to deliver the data from the sending
Ethernet node to the destination node.

The process is relatively simple, on purpose; the simplicity lets each device send a large
number of frames per second. Figure 2-17 shows an example in which PC1 sends an
Ethernet frame to PC2.
Free CISCO CCNA Routing and Switching ICND1 Study Guide
Figure 2-17 Example of Sending Data in a Modern Ethernet LAN
Following the steps in the figure:
1. PC1 builds and sends the original Ethernet frame, using its own MAC address as the
source address and PC2’s MAC address as the destination address.
2. Switch SW1 receives and forwards the Ethernet frame out its G0/1 interface (short
for Gigabit interface 0/1) to SW2.
3. Switch SW2 receives and forwards the Ethernet frame out its F0/2 interface (short for
Fast Ethernet interface 0/2) to PC2.
4. PC2 receives the frame, recognizes the destination MAC address as its own, and processes
the frame.

The Ethernet network in Figure 2-17 uses full duplex on each link, but the concept might be
difficult to see.

Full-duplex means that that the NIC or switch port has no half-duplex restrictions. So, to
understand full duplex, you need to understand half duplex, as follows:
Half duplex: The device must wait to send if it is currently receiving a frame; in other
words, it cannot send and receive at the same time.
Full duplex: The device does not have to wait before sending; it can send and receive at
the same time.

So, with all PCs and LAN switches, and no LAN hubs, all the nodes can use full duplex. All
nodes can send and receive on their port at the same instant in time. For example, in Figure
2-17, PC1 and PC2 could send frames to each other simultaneously, in both directions,
without any half-duplex restrictions.

Using Half Duplex with LAN Hubs
To understand the need for half-duplex logic in some cases, you have to understand a
little about an older type of networking device called a LAN hub. When the IEEE first
introduced 10BASE-T in 1990, the Ethernet did not yet include LAN switches. Instead of
switches, vendors created LAN hubs. The LAN hub provided a number of RJ-45 ports as a
place to connect links to PCs, just like a LAN switch, but it used different rules for forwarding

LAN hubs forward data using physical layer standards, and are therefore considered to be
Layer 1 devices. When an electrical signal comes in one hub port, the hub repeats that electrical
signal out all other ports (except the incoming port). By doing so, the data reaches all
the rest of the nodes connected to the hub, so the data hopefully reaches the correct destination.
The hub has no concept of Ethernet frames, of addresses, and so on.

The downside of using LAN hubs is that if two or more devices transmitted a signal at the
same instant, the electrical signal collides and becomes garbled. The hub repeats all received
electrical signals, even if it receives multiple signals at the same time. For example, Figure
2-18 shows the idea, with PCs Archie and Bob sending an electrical signal at the same
instant of time (at Steps 1A and 1B) and the hub repeating both electrical signals out toward
Larry on the left (Step 2).
Free CISCO CCNA Routing and Switching ICND1 Study Guide

Figure 2-18 Collision Occurring Because of LAN Hub Behavior
NOTE For completeness, note that the hub floods each frame out all other ports (except
the incoming port). So, Archie’s frame goes to both Larry and Bob; Bob’s frame goes to
Larry and Archie.

If you replace the hub in Figure 2-18 with a LAN switch, the switch prevents the collision
on the left. The switch operates as a Layer 2 device, meaning that it looks at the data-link
header and trailer. A switch would look at the MAC addresses, and even if the switch needed
to forward both frames to Larry on the left, the switch would send one frame and queue
the other frame until the first frame was finished.

Now back to the issue created by the hub’s logic: collisions. To prevent these collisions, the
Ethernet nodes must use half-duplex logic instead of full-duplex logic. A problem occurs
only when two or more devices send at the same time; half-duplex logic tells the nodes that
if someone else is sending, wait before sending.

For example, back in Figure 2-18, imagine that Archie began sending his frame early enough
so that Bob received the first bits of that frame before Bob tried to send his own frame.
Bob, at Step 1B, would notice that he was receiving a frame from someone else, and using
half-duplex logic, would simply wait to send the frame listed at Step 1B.

Nodes that use half-duplex logic actually use a relatively well-known algorithm called carrier
sense multiple access with collision detection (CSMA/CD). The algorithm takes care of
the obvious cases but also the cases caused by unfortunate timing. For example, two nodes
could check for an incoming frame at the exact same instant, both realize that no other
node is sending, and both send their frames at the exact same instant, causing a collision.
CSMA/CD covers these cases as well, as follows:
Step 1. A device with a frame to send listens until the Ethernet is not busy.
Step 2. When the Ethernet is not busy, the sender begins sending the frame.
Step 3. The sender listens while sending to discover whether a collision occurs; collisions
might be caused by many reasons, including unfortunate timing. If a collision
occurs, all currently sending nodes do the following:
A. They send a jamming signal that tells all nodes that a collision happened.
B. They independently choose a random time to wait before trying again, to
avoid unfortunate timing.
C. The next attempt starts again at Step 1.

Although most modern LANs do not often use hubs, and therefore do not need to use half
duplex, enough old hubs still exist in enterprise networks so that you need to be ready
to understand duplex issues. Each NIC and switch port has a duplex setting. For all links
between PCs and switches, or between switches, use full duplex. However, for any link
connected to a LAN hub, the connected LAN switch and NIC port should use half-duplex.
Note that the hub itself does not use half-duplex logic, instead just repeating incoming signals
out every other port.

Figure 2-19 shows an example, with full-duplex links on the left and a single LAN hub on
the right. The hub then requires SW2’s F0/2 interface to use half-duplex logic, along with
the PCs connected to the hub.
Free CISCO CCNA Routing and Switching ICND1 Study Guide

Subscribe To Get

Latest IT certification News 

Help You Pass Any IT Exam