What is a switch? A switch is an electronic device used for networking that connects two or more network segments. This method of connecting networks together is sometimes called 'bridging'. Because the switch bridges together two network segments, the switch is said to functions as a bridging device. However, a switch can bridge more than two network segments, it forwards traffic intelligently and the function of the switch is transparent to the network. A device that is transparent to an Internet Protocol-based network will not show up in a traceroute. The fact that a switch has multiple ports, and the fact that it learns MAC addresses dynamically makes it different from an ordinary bridge. Switches are most accurately described as 'transparent multiport learning bridges'.
It greatly reduces or minimizes broadcasts of MAC addresses and ARP/RARP reuqests. A switch receives data from one port and forwards it to the correct port to which the destination MAC address is located. In short, a switch is a multi-port intelligent bridge.
When a switch knows the port on which a MAC address is located, it forwards the packet out that interface. If the MAC address is not known, the packet is flooded to all ports except the port that received the packet.
The switch listens for, and retains memory of the MAC addresses of all stations connected to it in a special forwarding table. This table allows the switch to look up the association between a MAC address and a port and forward a given packet selectively based on the MAC address.
In cases where the MAC address is not in this special forwarding table, a request for the address must be made on all ports the switch associates with that LAN.
- Store and Forward
- Cut Through
Modern switches support Virtual LANs (VLAN) which allows a single switch, or set of switches that comprise a connected physical network to support multiple virtual logical networks supporting different IP subnet ranges. When two switches support the same VLAN, a network 'trunk' must be constructed between them, and that trunk port requires special configuration to designate it as a trunk port. Because the utilization over the trunk port between the switches can get very busy, many vendors support another technology called Fast Etherchannel which allows two switches to bind more than one physical connection into a faster high speed connection that acts as a single connection.