Computer Networking Lecture Notes
2014 October 27 • Local Area Networks
Outline
Shared wire media.
Ethernet switches.
Combined LANs.
At layer 2 or 3.
Data-Link Networks
The data-link layer groups hosts into two types of networks:
Point-to-point networks.
Shared-channel networks.
Local-Area Networks
A shared-channel network is commonly called
Local-Area Network
(
LAN
).
“Local area”:
Limited geographical coverage (up to a square mile).
Limited host population (up to a few hundred hosts).
Shared Channel
Most modern high-capacity LANs don’t use shared-channel media.
Too expensive: sharing coordination overhead.
Too inefficient: conflict resolution overhead.
Switched Ethernet
The most common wired LAN is
switched Ethernet
.
A
star architecture
.
Hosts around the outside.
A
LAN switch
in the middle.
Point-to-point links connecting them.
LAN Switches
A LAN (or layer-2) switch forwards PDUs among connected hosts.
There are no collisions.
Incoming PDUs are buffered at the switch.
Links are full duplex.
There is no direct connection (no circuit) between hosts.
LAN Switch Forwarding
A LAN switch forwarding table is a list of (destination, port) pairs.
Entries are aged.
A PDU arrives at a switch port.
If the destination MAC address is not in the forwarding table, flood the PDU.
Otherwise send the PDU out the designated port.
The star architecture means flooding is trivial.
Forwarding Example
PDU Snooping
Switch forwarding tables are self-discovered.
A PDU from
MAC
s
shows up on port
i
.
Put (
MAC
s
,
i
) in the forwarding table.
Or reset the aging timer if it’s already there.
No set-up, no routing algorithms.
But non-sending hosts don’t get discovered.
Connecting LANs
A LAN per department is a convenient network layout.
Traffic and fault isolation.
On the other hand, communication between departments is also nice.
LANs can be connected at the data-link layer, or at the network layer.
Network-Connected LANs
Comments
Flexible and scalable interconnect.
Can grow to connect 100s of LANs.
Allows communication, but preserves LAN structure.
Each component LAN remains a separate entity.
But network management is difficult and labor intensive.
Data-Link-Connected LANs
Forget the network layer and connect at the data-link layer.
Comments
Much simpler than network connections, but not as scalable.
Connect 10s of LANs.
Large forwarding tables.
One big LAN doesn’t preserve component LAN structure.
Large drop in aggregate resource availability.
Layer-2 switches help with this.
The Deadly Cycle
Cycles provide redundant connectivity for reliability.
Cycles can occur accidentally, particularly in large interconnected LANs.
Flooding and Cycles
Switches flood when destinations aren’t known.
Floods and cycles are a bad combination.
Routers deal with this by
not flooding
.
Switches avoid flooding problems using a different approach.
Spanning Trees
A
tree
is an acyclic graph.
Being acyclic, trees can flood PDUs without problems.
No excessive PDU copying.
The flood naturally dies down.
A
spanning tree
is a tree containing every switch in the LAN.
It spans the hosts in the LAN.
The switches build a spanning tree.
Growing a Spanning Tree
To build a spanning tree:
Use flooding to select the
root switch
, the switch with
the lowest MAC address
.
The root switch floods a
path PDU
.
Switch
S
receiving the first path PDU marks the incoming port as the
root port
and floods the path PDU.
S
discards further path PDUs
.
The set of root ports forms a spanning tree.
Summary
Shared wire media isn’t much shared anymore.
Ethernet switches are layer 2 store and forward devices.
LANs can be combined into larger structures.
At layer 3 with routers.
At layer 2 with switches.
This page last modified on 2014 October 26.