Both three-layer switches and routers work on the third floor of the network, according to the forwarding (or exchange) of the packet according to the IP address, the principle does not have much difference, the two nouns tend to unify, the so-called switching router and routing switch finger Is the same thing. We can think that the three-layer switch is a multi-port router.
But if you look for the perspective of the development of the two, we can still find out some differences:
The history of the router is more than a long time. In the 80s, Cisco launched the industry's first router. The launch of the router is to solve the remote, different network segments of interconnects, so-called "routing" is based on the destination address of the network (such as the IP packet), to determine and put the packet. Forward to "next hop" to the destination. Since the routing algorithm is more complex, the early routers are generally based on the CPU to handle and forward packets in a "single-jump clock" instruction, which is relatively low in the forwarding of the packet. But we don't want to forget, at that time, the interconnection of remote wide area is the first, but it needs and uses the router is a large business university (such as bank). On the one hand, the broadcast data is relatively low (less than 1 E1 = 2 Mbps, such as PSTN, ISDN, DDN, Frame Relay, etc.), on the other hand, the application is mainly based on UNIX host, so network transmission The speed is not a big problem.
Summary, there are three features of traditional routers:
CPU-based single-step clock processing mechanism can handle complex routing algorithms and protocols Mainly used in WAN to enter the 90s, the rapid development of PCs, leading to rapid rise and extensive applications of the Ethernet and TCP / IP protocols. The internal network of enterprises is increasing, and the Internet has become the largest wide area network. The remote interconnection of the company has become more and more from the special network of self-built (rent). These changes directly lead to the emergence of switches, and the router upgrade, and the fusion of routers and switches.
The earliest Ethernet switch came out before and after 95 years, his predecessor is a bridge. The bridge works in the second floor of the network, one of its roles is to isolate the network broadcast storm. We know that the establishment of the communication link between the Ethernet host has largely depends on a broadcast package, strictly speaking, the broadcast package is only responsible for establishing and maintaining communication without transmitting effective data, when the number of hosts on the network increases The broadcast package will grow in an index level, accounting for too many bandwidth, reducing network efficiency (authoritative statement, the number of hosts of an Ethernet segment should not exceed 30 units, more than 10 bridges should be isolated). The bridge is like a person with a left and right arm, which determines whether the frame is exchanged between the left and right hands according to the destination MAC address of the Ethernet data frame (Frame). The broadcast package is no destination address (meaning to everyone), so it is partitioned. We can understand the switch into a multi-port bridge, which is connected to the host or network segment on each of its ports, and the exchange between each port is relatively independent, and network efficiency is improved. The switch works in the second floor of the network, the algorithm is relatively simple, soon there is a chip manufacturer to cure it, produce the core ASIC chip of the switch, and launch hardware line speed switches.
Summary, there are three features of the traditional switch:
Based on the ASIC hardware, line speed exchange work is second layer network, mainly the Ethernet is mainly used for fast data exchange of local area network With the further expansion of the internal network of enterprises, the host increases to hundreds of thousands, the third layer of the network Broadcasting storm has become a problem (authoritative statement: the number of hosts on a TCP / IP network section should not exceed 300). Traditional switches work in the second layer of the network and cannot isolate the three-layer broadcast. One solution is to do VLAN isolation on the switch, and then blick on the VLAN to the upper router, and the router is forwarded between different network segments (3-layer network segment) by the router. This is the initial routing exchange model, typical product is Cisco's Catalyst 5500 route switch. Routing Exchange is a transition product, today's three-layer switch has changed in the architecture, routing and exchange pass through the ASIC, the first package After determining the path, subsequent data packets The switching engine implements line speed exchange. Of course, all routing algorithms are still very difficult, this is today's three-layer switch either unable to implement line speed, or only the reason for limited simple routing protocols. Traditional routers continue to maintain their vital with the development of the Internet. Complex protocols such as BGP, MPLS, new features and applications (such as VPN, Security) are inseparable from software and CPU computing, but routers have also made very much improvements in architectural structure and integrated increasingly The more firmware and ASIC.
The development of routing and exchange is dialyzed with the evolution of IT industry software and hardware, and will continue to evolve as people's relentless pursuit of functionality and performance.