Hubs and Switches
Hub
- Predecessor of a switch
- Electrical repeater
- Inexpensive
- Unintelligent
- A signal comes in to one port and is flooded out all the other ports. So each of the members of the network had to look to each piece of mail and say "is this for me?"
- Your NIC is responsible for doing this, it will look at the MAC address on the frame and it will drop it if it does not match the localhost MAC address.
- A signal comes in to one port and is flooded out all the other ports. So each of the members of the network had to look to each piece of mail and say "is this for me?"
/CSCE-120/Visual%20aids/Pasted%20image%2020241010114945.png)
Switch
- Datalink Layer
- Successor to the hub
- Maintains intelligent forwarding table
- The MAC table.
- or CAM table for Content Addressable Memory
- CAM is like RAM but its different, its faster, and that makes sense because switches are built for accelerated forwarding
- Can cost millions
- Depending on port density, depending on speed and depending on the intelligent capabilities of that switch.
- Some switches have Power over Ethernet (PoE)
- Speed & capabilities vary
- Some switches have Power over Ethernet (PoE)
- Cisco switches have a console port for manual configuration
Intelligent Forwarding
Layer 2 forwarding mechanics
- MAC address table
- Associates MAC addresses to ports
- Dynamic learning on ingress
- As frames come into the switch
- Flooding
- Any time we do not know where something is (not found on the MAC table) we just flood the message out to every single port assuming that it will get there.
- If the frame does get there, when that device replies, we'll see the message come in. And again, on ingress, we'll dynamically know that that source lives there, and we'll take our new device that just responded, and we'll add the appropriate port number.
- Filtering
- As frames come in, if it is not destinated to you, we are not gonna flood it because we got a hint or a match in our MAC address table.
Switch Features
Network Layer
- Management (CLI / HTTP / SNMP / API)
- Do I have access to a Command Line Interface?
- Is that through SSH or can I get there through a console port?
- Am I limited to only a web browser?
- A lot of switches have support for Simple Network Management Protocol (SNMP) and it's just a way to take a management software and monitor all of our devices, really handy for centralized management.
- If you want to do centralized management and you want to change 100 switches and make all of them run a new access-list, that's where an Application Program Interface (API) comes in. I can have a centralized controller that can push out, and make changes to lots and lots of devices - Software-Define Networking (SDN).
- Do I have access to a Command Line Interface?
- Security (Isolation, rate limit, traffic filtering)
- Routing (even faster than a router)
- A router might have 4 interfaces while a Switch can have 24, 48, 96 and more interfaces. Each of those interfaces needs to be able to speak and listen at the same time, that is called full-duplex. If a port is 10 GiB/s the switch should ideally support 10 GiB/s going and 10 GiB/s coming at the same time.
- Many times switches exceed routers in terms of speed.
- Routers are useful if we want to do media translation, for example if we want to go from a LAN to a WAN, If I want to build VPNs or if I want to use advanced protocols like BGP. Maybe I've got more memory in my router.
- But for fast quick decisions nothing beats a Switch.
- Integrated Services (AAA, WLAN, DHCP, etc)
- Authentication, Authorization, Accounting (AAA)
- Some switches have a Wireless LAN (WLAN) controlled capability
- Wireless Access Points (WAP) will talk to this switch with this capabilities and share their configurations.
- Some switches may be your Dynamic Host Configuration Protocol (DHCP) server, also know as your time server.