Beginner Topic 11 of 50 Computer Networks
Switches and Hubs
Devices forwarding frames within a local network.
How it works
A hub is a simple layer 1 device that repeats every incoming signal to all ports, so all devices share one collision domain. A switch is a layer 2 device that learns which MAC address is on which port and forwards frames only to the right port, giving each port its own collision domain and allowing full-duplex connections and many simultaneous conversations. Managed switches add VLANs, port mirroring, spanning tree and access control.
Step-by-step walkthrough
- A hub repeats every bit to all ports and causes collisions.
- It also sends to PC 2, wasting bandwidth.
- A switch learns which MAC is on which port.
- It forwards frames only to the right port.
- Switching gives each port its own collision domain.
Where it is used
Switches form the backbone of LANs and data centers, and hubs are now obsolete. Layer 3 switches also route between VLANs.
Common pitfall
A switch floods unknown destinations and broadcasts, so large flat networks create excess broadcast traffic. Loops without spanning tree cause storms. MAC table overflow attacks make a switch behave like a hub. Secure unused ports, segment with VLANs and monitor with port mirroring.
Where it fits in the course
Switches and Hubs is topic 11 of 50 in Computer Networks, rated Beginner. It follows Ethernet. The next topic is Routers.
Practice and explore
- Open the interactive lesson, with a mini quiz.
- Take the Computer Networks quiz.
How to study this topic
- Read the explanation above and restate the definition in your own words.
- Open the interactive lesson and answer its mini quiz.
- Read the common pitfall, then write a short example that avoids it.
- Check your understanding in the Computer Networks quiz, and revisit the topic if you miss a question.
Frequently asked questions
What is Switches and Hubs?
Where do people use Switches and Hubs?
What is the most common mistake with Switches and Hubs?
What should I learn before this topic?
How can I practice it?
Is Switches and Hubs hard to learn?
How long does it take to learn Switches and Hubs?
Which topics are related to Switches and Hubs?
What should I study after Switches and Hubs?
Related topics
- Ethernet (Computer Networks)
- Routers (Computer Networks)
- MAC Addresses (Computer Networks)
- DNS (Computer Networks)