• Networking
  • Programming
  • DBMS
  • Operating System
  • Internet
  • Hardware
  • Software

Tech Differences

Know the Technical Differences

Difference Between Hub and Switch

hub vs switchThe Hub and Switch are the networking devices which appear to be similar and physically used as a star topology. However, there are several differences between Hub and switch. The prior difference is that logically the hub works like a bus where the same signal is transmitted to all the connections. On the other hand, the switch can provide the communication between any pair of ports. As a result, all the ports in the hub belong to the same collision domain while in switch the ports are operated on the separate collision domain.

Content: Hub Vs Switch

    1. Comparison Chart
    2. Definition
    3. Key Differences
    4. Conclusion

Comparison Chart

Basis for comparisonHubSwitch
Operates onPhysical layerData link layer
Type of transmissionBroadcastUnicast, multicast, broadcast.
Number of ports4 (more or less)24 - 28 (depending on the type of switch).
Collision domainOnly oneDifferent ports have separate collision domain.
Transmission mode
Half duplexFull duplex
Filtering
No provision of packet filteringProvided
Loop avoidanceSusceptible to switching loopsCan avoid switching loops by using STP.

Definition of Hub

The hub is also called as the multiport repeater, which transmits the amplified signal to each port excluding the one from which the signal was received. A hub is used to link the networking devices physically for communication and successfully generate multiple hierarchies of stations. Hubs are unable to perform intelligent forwarding and process layer 2 and layer 3 information. It makes the decision on the basis of physical addressing instead of hardware and logical addressing. The hub cannot distinguish the type of the frame, that is the reason it forwards unicast, multicasts, and broadcasts to every other port except originating port.

The multiple LAN cables are connected to the hub with the help of the RJ45 connector. These LAN cables can be at maximum 100 meters long. To form a huge network of the enormous nodes the hub can be linked in a hierarchical manner. The hub behaves as a linking device which works in a half-duplex mode where either transmission and reception of the data by the host is permitted at a time.

Types of HUB

Active Hub: The active hub is one which provides the amplification and regeneration of the signals along with the connection.

Passive Hub: The passive hub works as a connector and connects multiple cables together, but there is no amplification and regeneration of the signal.

Definition of Switch

A switch is nothing but a bridge which provides more efficient bridging. In a broad way, a switch is a device which enables the connections to be established and terminated according to the need. It provides multiple functionalities such as filtering, flooding and transmission of the frames. It needs the destination address of the frames for its functioning which it learns from the source MAC address. Unlike a hub, the switch can work in full-duplex mode.

Each port has its separate collision domain, therefore the collisions produced in the switch much less than produced in the hub. Similar to the hub, switch also have one broadcast domain it can transmit both broadcast and multicast out each port except the originating port, which makes it unsuitable for a vast and scalable network. There is no mechanism provided by the layer 2 header to distinguish the different networks; however, it can differentiate distinct hosts. The Internet wouldn’t be able to work if only hardware addressing is provided. Think as a practical situation in which internet is working as a purely layer-2 switched environment then the switch has to forward broadcast out to every port in a collection of billions of devices and computers on the internet. It could result in the internet failure.

The hubs and switches are prone to switching loop, which can result in damaging broadcast domain. The switch employs Spanning Tree Protocol to make the surroundings loop free.

Types of frame forwarding methods

Store-and-Forward – In this technique the entire frame is stored in the memory then cyclic redundancy check is carried out, in order to check the integrity of the frame. The latency experienced in this technique is the highest.

Cut-Through (Real Time) – This technique forwards the packet to the output buffer as soon as the destination address is known. The latency produced in this method is the least. There is no error checking is performed.

Key Differences Between Hub and Switch

  1. The hub operates on the physical layer of the OSI while a switch works on the datalink layer of the OSI.
  2. Hub shares the bandwidth between the ports. On the other hand, in a switch, the dedicated bandwidth is provided to the ports.
  3. The number of ports that can connect to the device is significantly more abundant in switch while it is less in a hub.
  4. A hub can have a single collision domain whereas in switch different ports have different collision domain. As a consequence, the hub introduces more collision than the switch.
  5. The half-duplex transmission mode is used in the hub. As against, the switch transmits the data in the full-duplex mode.
  6. A switch provides filtering of frames so that only the dedicated device receives the forwarded frame. Conversely, there is no such concept of filtering is used in the hub and it forwards a frame to each port.
  7. The switch uses Spanning Tree Protocol to eliminate the problem of switching loops. In contrast, the hub is incapable of avoiding the switching loops.

Conclusion

Hub and switch are networking devices which provide a mechanism to connect several devices in order to communicate with each other. However, the hub works on physical layer whereas switch operates on the data link layer. A switch overcomes the limitations of the hub and provides intelligent forwarding of the frame, hardware address learning and loop avoidance.

Related Differences:

  1. Difference Between Simplex, Half duplex and Full Duplex Transmission Modes
  2. Difference Between Hub and Bridge
  3. Difference Between LAN and VLAN
  4. Difference Between Router and Switch
  5. Difference Between Bridge and Switch

Comments

  1. kyawthuya says

    April 11, 2020 at 3:25 pm

    I am interesting that about

    Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Top 10 Differences

  • Difference Between OLTP and OLAP
  • Difference Between while and do-while Loop
  • Difference Between Guided and Unguided Media
  • Difference Between Preemptive and Non-Preemptive Scheduling in OS
  • Difference Between LAN, MAN and WAN
  • Difference Between if-else and switch
  • Difference Between dispose() and finalize() in C#
  • Difference Between for and while loop
  • Difference Between View and Materialized View
  • Difference Between Server-side Scripting and Client-side Scripting

Recent Addition

  • Difference Between Unit Testing and Integration Testing
  • 4G Vs 5G
  • Raster Vs Vector Images
  • JPEG Vs TIFF
  • RJ11 Vs RJ12

Categories

  • DBMS
  • Hardware
  • Internet
  • Networking
  • Operating System
  • Programming
  • Software

Copyright © 2023 · Tech Differences · Contact Us · About Us · Privacy