Current location - Plastic Surgery and Aesthetics Network - Plastic surgery and beauty - What is the difference between HUB and switch?
What is the difference between HUB and switch?
all the output ports of the hub share the bandwidth of the input port of the hub, while the bandwidth of all the output ports of the switch is equal to the bandwidth of the input port. That is to say, if the bandwidth of the wire drawn from the outside to your home is 1M, and if the wire is connected to a hub (with four output ports and one input port), then the bandwidth of these four output lines is 2 on average. 5M。 However, if a switch is connected, the bandwidth of these four lines is basically 1M.

in addition, the hub expands the collision domain, while the switch isolates the collision domain.

a SWITCH is similar to a HUB and can connect two LAN segments. It works at the data link layer and can filter frames. SWITCH detects the source address and destination address of the frame. If it is in the same network segment, it will not be forwarded. If not in the same network segment, forward the frame to another network segment.

several or hundreds of computers in the company form a local area network, which can be connected by several hubs. From the price point of view. HUB has the advantages of low price and plug and play. But this method of building a local area network is only the simplest topology. This kind of peer-to-peer network can only complete simple data sharing. This is not enough for a company that needs advanced network management.

Any company is developing, and the application of corporate LAN will be more abundant. There are more and more PCs in the local area network, and the division of labor is more clear, which makes the topology of the network increasingly complex. The reasonable framework of the network should fully consider compatibility and expansibility. In addition, we should also consider the bandwidth balance between backbone networks and the stability of different network media at different transmission distances, so that the connection between backbone networks can meet the needs of bandwidth and different transmission distances. HUB is no longer competent for such a network with complex system integration and reasonable planning. Therefore, SWITCH will be the first choice.

comparison shows the difference between HUB and SWITCH

1 In the process of data transmission. Because of congestion, delay and other reasons. There will be short frames, fragments, etc. From the perspective of ISO physical system, HUB belongs to the equipment of physical layer. The physical layer provides the basic mechanism for encoding (sending) and decoding (receiving) binary data (bits), and it also defines the physical connection mechanism with the medium, but not the medium itself. Therefore, HUB only performs a single synchronization, amplification and shaping function on data, but it can't handle short frames and fragments in the data process.

SWITCH works at the data link layer. This layer provides a Frame composed of information bits, which consists of a header or header bit containing a start flag, addressing information and (for LAN) a 32-bit cyclic redundancy code (CRC). The function of CRC is to ensure the integrity of the frame when the information bits pass through the physical medium. The data link layer also provides link management. For Ethernet, frames are transmitted when the channel is idle and stop when a collision is detected. In token ring network. When a free token is received, the frame is transmitted. Therefore, the switch can not only synchronize, amplify and reshape the data, but also effectively filter short frames and fragments.

2 with the increase of workstations in the company's local area network, data communication will be busier. When the HUB is working, no matter how many ports are communicating, all ports use a bandwidth. It adopts the way of time-sharing processing.

for SWITCH, each port has one bandwidth, and two arbitrary ports can communicate at any time, which will never affect the work of other ports. This makes the data transmission smoother when the SWITCH works than the HUB. Of course, all mainstream SWITCH support 1M/1M self-adaptation, which can work in both half-duplex and full-duplex modes.

when a port of p>3 HUB sends data, it will not send it to the destination port actively, but send information to every port. Imagine that one workstation transmits data to another workstation. This information frame will spread all over the network through the HUB. Waste bandwidth resources. Use SWITCH to connect network segments. If the source port and the destination port are in the same network segment, information will not enter another network segment through SWITCH.

similarly, in the above situation, the HUB works in broadcast mode. If a port receives information, it will send the information to all ports in the network because it is not the destination port. If this is repeated, there will be a "broadcast storm". The omni-directional SWITCH can prevent this from happening. Because when the SWITCH works, only the source port and the destination port respond, and other ports will not be affected, so the SWITCH effectively suppresses the broadcast storm.

generally speaking, HUB only has the advantage of being cheaper than SWITCH. But in the face of cost-effective SWITCH, this advantage no longer exists. Different SWITCH also have different functions. For example, it can connect optical fiber, and has VLAN function, intelligent management function and routing function.