Network Connection Devices
Network Connection Devices
A variety of devices are used to connect networks: repeaters, hubs, bridges, switches, and routers.
repeaters and hubs operate at the physical level
bridges and switches operate at the data link level
routers operate at the network level
Repeaters
A repeater is placed on a line (say, an Ethernet wire) to amplify and "clean up" the signal. It simply sends what it hears.
- A repeater transmits all bits from one side to the other.
- It operates at the physical layer.
- Result is the extension of a single LAN, rather than connecting two LANs.
- All hosts belong to the same collision domain.
Hubs
A hub is used to implement a broadcast network on a physical star topology.
Each host is connected to the hub by two wire (for input and output). Everything the hub hears (on any of its input lines) is broadcast on all its
outgoing lines.
--A hub is basically a multiport repeater.
-- All hosts belong to the same collision domain.
-- Used by 10 Base T Ethernet.
Switches
Link layer switches serve a purpose similar to hubs (that is, they are
used to connect hosts into a single LAN, but are more sophisticated than
hubs and understand frames and addresses.
A four port switch has two-way connection to 4 hosts. When it receives a frame
from one host, it examines the destination address field in the frame, and
sends the frame to the destination host only. The frame is not
broadcast to all the other hosts.
store-and-forward vs cut-through
A store-and-forward switch reads a frame and buffers it, then sends it to
the destination host.
A cut-through switch begins sending the frame to the destination host as
soon as it reads the destination address in the frame header.
It is not necessary to store
the entire frame all at once.
The effect of using a switch instead of a hub is that frames are not broadcast,
so there are fewer collisions, and therefore higher throughput.
Switches are "plug-and-play" -- they don't need to be configured with the
MAC addresses of all the connected hosts. How is this possible?
How to connect multiple LANs?
Use a bridge.
FIGURE
A bridge is a computer connected to both LANs. The LANs may be
the same or use different standards.
The bridge is responsible for
1. Translating frame structure
- It strips off one LAN's framing and adds another's.
- It does not look at the contents of the frame -- so it only works at the data link level.
- Problems: frame size, speed.
- Forwarding frames received from one LAN to destinations on another LAN.
- Each node has a unique global address, so that is not a problem.
How to do routing:?
1. Transparent bridge
The existence of bridges is transparent to the hosts.
- Each bridge keeps a table mapping host addresses to LANs.
- Initially empty, it is updated each time a frame is received. If a message with source address A is received on LAN X, then (A,X) is entered into the table.
- Outdated entries can be overwritten with new information. Periodically, the entire table can be purged.
- Read every frame on each LAN it is connected to.
- Look up the destination address of the frame.
- If LAN(destination) is the same as the LAN from which the frame came, discard it.
- If LAN(destination) is not the same, forward it to the desired LAN.
- If LAN(destination) is not found in the table, forward it to all other LANs. This is called "flooding".
2. Source routing bridge
Each host is responsible for routing its messages through bridges.
Each sender on each LAN must know
- which LAN the destination is on, and
- what route to take (throught bridges) to get to the destination
- Advantage: Once the sender knows the path, routing is faster and can be handled in hardware.
- Disadvantage: More work for hosts (that is, not transparent to hosts).
- The network administrator must design LAN#s and bridge#s, so there is a possibility of error.
Bridges vs. Repeaters
- A repeater transmits all bits from one side to the other.
- It operates at the physical layer.
- Result is the extension of a single LAN, rather than connecting two LANs.
- All hosts belong to the same collision domain.
- With a bridge, there are separate LANs with separate collision domains. But it appears to a host as a single LAN.