What is the difference between a hub and a switch?
1. From the perspective of OSI architecture, hubs belong to the first layer of physical layer devices, while switches belong to the second layer of OSI data link layer devices. That is to say, the hub only plays the role of synchronizing, amplifying and shaping the data transmission, and cannot effectively process short frames = fragments in data transmission, and cannot guarantee the integrity and correctness of data transmission;
The switch can not only synchronize, amplify and reshape the data transmission, but also filter short frames and fragments.
2. From the perspective of working mode, the hub is a broadcast mode, that is to say, when a certain port of the hub is working, all other ports can listen to the information, which is prone to broadcast storms. When the network is large, the network performance will be greatly affected. great influence;
The switch can avoid this phenomenon. When the switch is working, only the port that sends the request and the destination port respond to each other without affecting other ports. Therefore, the switch can isolate the conflict domain and effectively suppress the occurrence of broadcast storms.
3. From the perspective of bandwidth, no matter how many ports a hub has, all ports share a bandwidth. Only two ports can transmit data at the same time, and other ports can only wait. At the same time, the hub can only work in half-duplex mode. ;
For switches, each port has an exclusive bandwidth. When two ports are working, it does not affect the work of other ports. At the same time, the switch can not only work in half-duplex mode but also in full-duplex mode.
4. To put it bluntly, a hub is just a network device that connects multiple computers. It can only play a role in signal amplification and transmission. It cannot process the fragments in the signal, so it is easy to make errors during the transmission process. A switch can be regarded as an intelligent hub. In addition to having all the characteristics of a hub, it also has its own active addressing, switching, and processing functions. And during the data transfer process. The sender and receiver work independently. There is no relationship with other ports, so as to prevent data loss and improve throughput.