Traditional Culture Encyclopedia - Traditional festivals - Difference between gateway and switch
Difference between gateway and switch
What is a gateway? And what is a gateway? What is the difference between them? Here is my compilation of the difference between a gateway and a switch.
Difference between a gateway and a switch
1) Switch
In a computer network system, a switch is introduced to address the weaknesses of the *** enjoyment mode of operation. A switch has a high-bandwidth back bus and an internal switching matrix. All of the switch's ports are hooked up to this back bus. When the control circuit receives a packet, the processing port looks up the address cross-reference table in memory to determine the port on which the NIC (Network Interface Card) with the destination MAC (NIC's hardware address) is hooked up, and then quickly transmits the packet to the destination port through the internal switching matrix. If the destination MAC does not exist, the switch broadcasts to all ports and receives a response from the port and the switch "learns" the new address and adds it to the internal address table.
The switch operates at the second layer of the OSI reference model, the data link layer. The CPU inside the switch learns the MAC address of each port as it is successfully connected, using the ARP protocol, and saves it in an ARP table. In future communications, packets addressed to this MAC address will be sent only to its corresponding port, not to all . ports. Therefore, the switch can be used to delineate data-link layer broadcasts, or conflict domains; however, it cannot delineate network layer broadcasts, or broadcast domains.
Switches are widely used for Layer 2 network switching, and are commonly referred to as "Layer 2 switches".
The types of switches are: Layer 2 switches, Layer 3 switches, Layer 4 switches, and Layer 7 switches, which work at Layer 2, Layer 3, Layer 4, and Layer 7 of the OSI seven-layer model, and are so named.
2) Gateway
Gateway (Gateway), the gateway as the name suggests is a device that connects two networks, different from the router (for historical reasons, many of the literature on TCP/IP used to use the network layer of the router (Router) known as the gateway, in today's LANs are used by many of them). For historical reasons, much of the literature on TCP/IP used to refer to a router as a gateway at the network layer, and today many LANs use routers to access the network, so nowadays a gateway is often referred to as the IP of a router. Gateway is also often referred to as a device that converts from one protocol to another, such as a voice gateway.
In traditional TCP/IP terminology, there are only two types of network devices, gateways and hosts. A gateway can transfer packets across a network, but a host cannot. In the host (also known as the end system, end system), packets need to go through the TCP/IP four-layer protocol processing, but in the gateway (also known as the intermediary system, intermediate system) only need to reach the inter-network layer (Internet layer), after deciding on the path can be forwarded. At the time, there was no difference between a gateway and a router.
In modern networking terminology, a gateway is defined differently than a router. A gateway moves data across protocols, while a router moves data across networks and is the equivalent of what is traditionally called an IP gateway.
The gateway is a device that connects two networks, for voice gateway, he can connect the PSTN network and Ethernet, which is equivalent to VOIP, the analog signals from different phones through the gateway and converted to digital signals, and add protocols to transmit. At the receiving end, the gateway then reduces the signal to an analog phone signal, which can be heard on the phone.
For Ethernet, the gateway can only forward packets above Layer 3, which is the same as routing. The difference is that there is no routing table in the gateway, and it can only forward according to different predefined network segments. The most important aspect of a gateway is port mapping, which protects the users in the subnet by allowing them to see only the IP address of the external network corresponding to a different port.
What is the difference between a switch and a router?
(1) Different levels of operation
Initially, switches operated at the data link layer (Layer 2) of the OSI/RM open architecture, whereas routers were designed to operate at the network layer of the OSI model. Because switches work at the second (data link) layer of OSI, they are simpler, whereas routers work at the third (network) layer of OSI, where more information about the protocol is available and routers can make smarter forwarding decisions.
(2) Data forwarding is based on different objects
The switch uses the physical address or MAC address to determine the destination address of the forwarded data. Routers, on the other hand, use the ID numbers (i.e., IP addresses) of different networks to determine the address to which data is forwarded. IP addresses are implemented in software and describe the network on which the device is located, and are sometimes referred to as protocol addresses or network addresses in Layer 3. MAC addresses are usually proprietary to the hardware and are assigned by the manufacturer of the NIC, and are solidified into the NIC and are generally immutable. The MAC address is usually assigned by the manufacturer of the network card and has been solidified into the card. IP addresses, on the other hand, are usually assigned automatically by the network administrator or the system.
(3) Traditional switches can only split conflict domains, not broadcast domains; routers can split broadcast domains. Network segments connected by a switch still belong to the same broadcast domain, and broadcast packets are propagated across all network segments connected to the switch, which in some cases can lead to communication congestion and security breaches. Network segments connected to a router are assigned to a different broadcast domain, and broadcast data does not pass through the router.
Although Layer 3+ switches have VLAN capabilities and can split broadcast domains, the sub-broadcast domains do not communicate with each other, and routers are still required to communicate between them.
(4) The router provides the service of a firewall, which only forwards packets of a specific address, and does not transmit packet transmissions that do not support routing protocols and seeks to know the transmission of packets from the target network, thus preventing broadcast storms.
- Previous article:The Significance of Nine-year Compulsory Education
- Next article:What does the combat club do?
- Related articles
- Emil Wakin Chau's information
- The Road to Prosperity through Tourism in Millennium Ancient Villages | Millennium Ancient Villages
- Shanghai wonton where to eat Shanghai wonton store recommendations
- What are the dance characteristics of the famous dance "Pan Drum Dance" in Han Dynasty?
- The main characteristics of Gaojia opera
- What does the lotus tattoo mean?
- Three common page layout designs in 08 PPT
- What kinds of floor tiles do you usually have? What kind of decoration is better?
- Where is the local drama of pingtan?
- Where is Gao Peizhi's former residence?