A hub simply acts as a multi port repeater. If you remember the OSI model, the layer 1 was the physical layer. This device works on the layer 1 of the OSI model. It performs the function of connecting several ethernet devices together.
They work as a broadcast medium. No methods of analyzing or controlling the traffic coming to them is implemented. If there are n number of output ports, when a packet comes into it’s incoming port,the ethernet hub forwards the packet to all the n number of output ports. The result is
1. Packet Collision
2. Network Congestion
There is no method for a hub for identifying what is the data that is sent and what is the destination or even the source of the packet. It is just a means to amplifying the signal when we talk in electronics terms.
Ethernet hubs are fairly inexpensive and they are used as basic connecting devices. As of now, ethernet hubs are almost extinct. No network uses them due to their poor network traffic management. You have better options available such as switches, routers etc.
If you want, you can use the hubs as a temporary replacement for a switch. Never try this in a corporate environment though. If you have a small network, you are probably fine with hub as a temporary replacement.
** Some uses of ethernet hubs
1. Protocol analyzer
2. Cluster communication
3. Temporary switch replacement
4. Connect devices that support only 10BASE2
I am not going into details about hub’s as they are no longer relevant and extremely outdated.