What Is a Switch?
- A switch is a networking device that connects devices (computers, printers, etc.) within the same network.
- Unlike a router, it operates within a single network and doesn’t connect different networks.
How Does a Switch Work?
- Receives a Frame: A switch operates at Layer 2 (Data Link Layer) and uses MAC addresses.
- Checks Its MAC Table: It checks its internal MAC table to find the port associated with the destination MAC address.
- Forwards the Frame: Sends the frame only to the specific port (unlike a hub, which broadcasts to all devices).
Key Features of a Switch:
- Efficient Communication: Sends data only to the intended recipient, not to all devices.
- Improves Network Performance: Reduces collisions and improves bandwidth efficiency.
- Managed vs. Unmanaged:
- Managed switches can be configured (e.g., VLANs).
- Unmanaged switches are plug-and-play.
Example:
- In an office, all computers are connected to a switch to share files and access printers.