What's the diff between a router, switch, hub

Posted on 2009-04-25
Last Modified: 2012-08-14
What's the difference between a router, switch, hub, and an unmanaged switch?
Question by:davidlu766
    LVL 19

    Expert Comment


    A router is a device for passing/controlling traffic between seperate physical/logical interfaces.  It routes traffic at layer 3 between networks and is capable of supporting routing protocols which work out the best path for the traffic.

    A hub is a layer 2 device that provides port access to several nodes at once - nodes pass traffic by the hub sending arp requests to all ports on the hub and forwards the packets on finding the correct destination

    A switch is typically a layer 2 device that works the same as a hub but it has a cam-table where it learns the full table of all arp information of attached devices.  A lookup is performed on the cam-table to direct traffic to the correct destination rather than flooding all ports like a hub.  Some switches also work on layer 3 acting like routers and also support newer functionality like Power over Ethernet, RADIUS 802.1X authentication etc.

    An unmanaged switch has the same basic functionality as a switch but does not have the capabililty of having an ip address, working with snmp etc.  Like hubs, they are not typically deployed in larger setups as you cannot see what is happening on the ports/switch engine.

    If you google the above in a Q you will get heaps more detail but thats a quick overview

    LVL 9

    Expert Comment

    A router links together two logical IP subnets.  For instance is on a different network than  A router is needed to pass traffic between the two.  A bridge is similar except for that it is used to connect to networks that are in the same IP range.  For instance is split between to physical segments.  The bridge is responsible for keeping track of what IPs exist on either side and sending that traffic across as necessary.  The only place you see bridge technology anymore is in wifi to extend a wireless network range.  

    A hub is a dumb device in that it doesn't not interfere with traffic.  When one computer transmits data, everything on that network gets that traffic.  

    A switch is a much better device than a hub because it keeps a list of the IP addresses at every physical connection.  In this way it can deliver traffic only to the port that it needs to go.  The importance of this is seen with networks that get above 5 or 10 devices.  The more traffic that appears on the network, the more collisions there are, the slower the network gets, exponentially.  

    A managed switch gives more control over how to handle the traffic and it will have an interface that you can connect to.  You have to read the features to see what it includes.  A layer 2 switch, which is more expensive, keeps a list of IPs, but also keeps track of the hardware addresses, an arp list.  This allows more control.
    LVL 4

    Accepted Solution

    Lets start with the HUB. A hub is typically the least expensive, least intelligent, and least complicated of the three. Its job is very simple: anything that comes in one port is sent out to the others.Hubs are used to expand the size of a LAN. Hubs are mainly used to expand the number of devices that can be used on a LAN.In a hub, when one PC sends data onto the wire, the hub simply forwards the packets to all the other devices connected to it. Each device is responsible for determining which packets are destined for it and ignoring the others. Current "hubs" typically share bandwidth between all the ports. In the days of coaxial networking, hubs were often called "bridges". Because they forward every packet that they receive, they do nothing to streamline the traffic on your local network.

    The next step up is typically referred to as a switch.A switch is a little smarter than a hub, in that it records the IP and MAC addresses in a table of all the devices connected to it. Thus, when a packet is put onto the wire by one device, the switch reads the destination address information to determine if the destination device is connected to it.If it is, the switch forwards the packet ONLY to the destination device, sparing the other devices connected to it from having to read and deal with the traffic (making your network more efficient). If the switch does not recognize the destination device, then the switch sends the packet to everything connected to it, thereby requiring the devices to decide for themselves whether or not the packet is for them. In general, switches provide each device connected to them with dedicated bandwidth.A switch is used to segment a LAN into separate networks. If the traffic on you LAN were flooding the network with data then you would install a switch to segment the traffic.

    A router is the smartest and most complicated of the bunch.A router records the address information of everything connected to it like a switch. But it also records the address of the next closest router in the network.A router allows connectivity to one or more computers, helping create a network.In the telecoms industry, the backbone of the internet is formed by industrial routers.Routers are used to connect a WAN or WANS to your LAN or connect dissimilar networks together. Routers can be used to filter and isolate traffic or segment network traffic like switches
    LVL 12

    Expert Comment

    by:Faruk Onder Yerli
    Dear Friend;
    Those devoce sequence is below.
    Hub->switch-> router
       |.                       |
    Unmanaged.     Manageable

    Hub=repeater. Means that; hub is a layer1 device. It just increase amlitude of signal.

    Switch=multiport bridge. All switch operations are called layer2. Layer2 means mac-address control. Eachport of switch knows which mac address is working where. So, if port 1 host speaking with port4 host, other ports can not hear this conversation.

    Router is a layer 3 device. L3 means ip operation device. Ip is hyrercical address. Router can decide whoch ip will go to where under which condition.

    Manageable/unmanageable switch difference is detail issue. Basicly unmanageable just simle switch. It makes switching according to mac address table.
    Manageable switch can decide switching operation result conditions of admin define. It may include some futures as Vlans, qos, mac filtering.  

    LVL 9

    Expert Comment

    @Equalizer, the information that you are giving is very much incorrect.  There are layer 2 and layer 3 switches.  As a matter of fact, most switches work on layer 3 with no knowledge of layer 2.  Also, routers work with both layer 2 and layer 3 to accomplish their tasks.  Also, your sequence of devices has no bearing in networking.  Your information is incorrect and misleading.  Sorry to blast you, but I don't want the poster to get confused.  Read the other posts.

    @numero_uno, for the most part I agree with what you are saying, but I do have to correct one minor point.  Switches do not technically "segment a LAN into separate networks."  They separate a LAN into separate segments.  It's just a matter of terminology.  
    LVL 12

    Expert Comment

    by:Faruk Onder Yerli
    You are excatly incorrect. Some device can called l3 or l4 switch. This means that they are multi port router. Usually router options are enabled by admin. Other means switch router integrated devices. Please before talk market languages, you should read what is the osi model and devices. Who does not know base of network, he is not able to understand integrated devices working technichs.  
    LVL 9

    Expert Comment

    @Equalizer: Sorry, you are correct.  I don't say that very often, but I had a momentary lapse.  Layer 3 switches are the less common, more expensive switches because they maintain MAC/IP translation.  

    Featured Post

    New My Cloud Pro Series - organize everything!

    With space to keep virtually everything, the My Cloud Pro Series offers your team the network storage to edit, save and share production files from anywhere with an internet connection. Compatible with both Mac and PC, you're able to protect your content regardless of OS.

    Join & Write a Comment

    Creating an OSPF network that automatically (dynamically) reroutes network traffic over other connections to prevent network downtime.
    #Citrix #Citrix Netscaler #HTTP Compression #Load Balance
    After creating this article (, I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
    This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor ( If you're looking for how to monitor bandwidth using netflow or packet s…

    745 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    16 Experts available now in Live!

    Get 1:1 Help Now