Now let’s learn what switches are and how to use them in a local network.
A switch enables the connection of multiple devices to the same network.
Note each network interface to the switch has its own dedicated PHY responsible for driving the signals on each wire.
The uplink port on a switch is the same as the regular ports except that the Tx and Rx signals are reversed. This means a crossover cable is not required to connect one switch to another. Most new switches have Auto-MDIX interfaces which automatically switch the Tx and Rx signals if needed.
Switches Inside Routers
Most routers for home and small business have a built-in switch.
Switches use MAC Addresses
We’ve seen how routers use IP addresses to address hosts on the network. Switches don’t have the intelligence to use IP addresses. They instead use something called a MAC address.
A switch uses a Media Access Controller or MAC to forward and filter data based on a host’s MAC address, not its IP address.
The Media Access Controller (MAC) controls Layer 2 network functions. It forwards and filters frames based on their MAC addresses.
Every network host has two addresses:
1) IP Address (Layer 3 virtual address)
2) MAC Address (Layer 2 physical address)
A switch has a Media Access Controller, but no MAC address. It is transparent to the network. It is never the final destination for network traffic, so it doesn’t need a MAC address. A router on the other hand has two MAC addresses, one used for the local network or LAN, and one used for the Internet or WAN.
The MAC allows multiple devices to access the same physical network using CSMA/CD (Carrier Sense Multiple Access/ with Collision Detection (Ethernet)), or CSMA/CA (with Collision Avoidance (WLAN)).