♪ MUSIC ♪
JONATHAN DAVIS: Hello, my name is Jonathan
Davis and I am with the National Consortium for Mission Critical Operations. Today, we're going
to talk about the differences between a hub, a switch, and a router.
Now, I've got three examples here. First, we'll start with a hub.
And, you know, if I hold up a hub and you look at it, you've got ports
that you connect wires in to and if I hold up a switch
you're seeing the same thing
You've got a bunch of ports that you connect wires in to. So, when you look
at a hub and you look at a switch, you don't really see a difference
The difference is in what's inside
So, the basic difference between a hub and a
switch is that a hub operates at layer 1 of the
OSI model. That's the physical layer. If we have two
computers connected in to each one of these ports here and one
computer is sending a signal to another computer, the signal
that the sending computer sends will be broadcast
out every port on a hub
It doesn't matter if two computers are connected or twenty four
computers are connected to this hub. When a computer sends a signal
it is broadcast out of every single port. So there are some things
to keep in mind with that. For example, when that happens
we are broadcasting every packet
to every computer. Which means that every computer
receives every packet that is sent on the network
So, it's inefficient, it's going to slow things down because
we're handling that many packets and the more computers we have, the more packets
we're going to be receiving. It's no secure because any private information
that is sent though a hub is sent to every computer. So, if I'm
a hacker and I have a packet sniffing application on my computer
I'm going to be able to pick up all the packets on the network that are intended for anybody.
A switch, on the other hand
operates at layer 2 of the OSI model
That's the MAC layer
A switch operating at layer 2 is capable of keeping track
of MAC addresses using what is called a MAC Address Table or a MAC Table.
Each computer connects to a port on the switch.
The switch remembers the MAC address of the computer connected
to which port. So, when a computer sends a signal to another computer
the computer always says which MAC
address the packet is intended for
So, once the switch receives it, it's going to look at that packet or that
frame and it's going to look for the sending MAC address
or the destination MAC address. What MAC address was this
frame intended for. It's then going to look that MAC address up in its MAC
address table and see which port is designated for that
MAC address. The switch then forwards that frame to that specific
port, so that only the computer with that MAC address
only the computer that the frame was intended for, receives that packet
and this is with modern switches that have
full duplex, an added advantage that
with a hub,
you have one collision domain. Meaning that
all the computers connected to this device
if there is a collision, then all computers are affected.
Not just the computers that are connected to one port.
Whereas, on a switch
each port on a switch represents a different collision domain.
So, what is a collision? A collision is when
two computers, or two devices on the network, try to send a packet at the
exact same time. In a full duplex
switch, each port is capable of designating
four wires for sending and four for receiving
meaning that there is never an opportunity for a collision on a switch.
On a modern switch. Whereas, with a hub
any computer that's connected that tries to send
a packet or a frame at the exact same time as another computer
we are going to have a collision
So, collisions are way more abundant when we're talking about hubs than they are
when we're talking about switches. And in modern switches
the threat of a collision is basically eliminated
The last thing we're going to talk about is a router.
A router operates at layer 3 of the OSI model
or the network layer. That layer
operating at that layer means that the router is capable of looking at
the IP address, the destination...the source and destination
IP address in a packet
and forwarding information, or forwarding that packet based on
an IP route table that the router keeps
track of. Also, the router has a built
in switch and has two ports that can connect to
a local area network that operate at layer two
meaning that it can communicate on a local area network
and a wide area network through its serial interface
So, the serial interface is for the wide area connection and these
two cat5 interfaces or RJ45 connectors here
ethernet connections, are meant for a local area connection
So, these two ports operate at layer two
and these two ports, the serial ports, operate at layer three
So, what that means is that this router can
accept frames from a local area network, then look at an IP
address, determine which serial port it needs
to go out of in order to reach another server
or another computer that may be out on the internet. Because
it call look at the IP address and it keeps address of IP address tables, it can
It can reach devices that are outside of this network
It becomes known as the default gateway for that
network. That's the basic difference between
a hub, a switch, and a router.
♪ MUSIC ♪