Internet access channel switching method, gateway device, and internet access channel switching system
Patent Information
- Application Number
- PCT/CN2025/071483
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-03-08
- Filing Date
- 2025-01-09
- Publication Date
- 2025-10-02
AI Technical Summary
In the prior art, when the WAN interface of the ONT fails, the user device cannot universally switch to the NERG network to access the Internet, resulting in traffic interruption, especially when the user device does not support redialing or redirection instructions.
By maintaining high-priority and low-priority default routes on the gateway device, if dialing fails, it automatically switches to the backup gateway device, realizing the switching of Internet access channels without the need for user device response, and using bridge devices and link tracking tables to maintain symmetry of upstream and downstream messages.
This ensures that when an ONT interface fails, the user device can switch to NERG Internet access without any response, ensuring the continuity and versatility of traffic and solving the problem of non-universal switching in the prior art.
Smart Images

Figure CN2025071483_02102025_PF_FP_ABST
Abstract
Description
Internet access channel switching method, gateway device and Internet access channel switching system
[0001] This application claims priority to the Chinese patent application filed with the State Intellectual Property Office on March 8, 2024, with application number 202410285181.0 and application name “A method for switching Internet access channels, a gateway device and an Internet access channel switching system”, the entire contents of which are incorporated by reference into this application. Technical Field
[0002] The embodiments of the present application relate to the field of communication technology, and in particular to an Internet access channel switching method, a gateway device, and an Internet access channel switching system. Background Art
[0003] In edge-cloud convergence services, the edge cloud gateway (ECGW) creates a virtual network-enhanced residential gateway (NERG) for each user. The NERG is isolated by user and connects the optical network terminal (ONT) to the edge cloud. The ONT and NERG each assign addresses to user devices on the local area network (LAN). Each ONT and NERG has a wide area network (WAN) interface based on the Point-to-Point Protocol over Ethernet (PPPoE), and both WAN interfaces can dial normally.
[0004] For example, if the WAN interface of the ONT fails, the Internet traffic on the ONT needs to be switched to NERG. Taking the example of switching the ONT Internet traffic to NERG, due to the use of distributed dial-up, the user dials from the ONT through the user device on the LAN side of the ONT. The next hop of the user device's default route is the Internet Protocol (IP) address of the ONT's bridge interface. To switch the traffic to NERG, the dial-up function on the LAN side of the ONT can be disabled, and a redial instruction can be sent to the user device to make the user device redial and obtain an address from NERG. In this way, the user device's default route naturally switches to NERG, and the traffic also switches to NERG. Alternatively, a redirect instruction can be sent to the user device to change the next hop of the user device's default route to NERG.
[0005] However, since not all user equipment can fully support the above two instructions to perform switching, the above solution is not universal. Summary of the Invention
[0006] The present application provides an Internet access channel switching method, a gateway device, and an Internet access channel switching system for implementing Internet access channel switching between an ONT and a NERG.
[0007] The first aspect of the present application provides an Internet access channel switching method, which is applied to a first gateway device. A routing table is maintained on the first gateway device, and the routing table includes a first default route and a second default route. The first default route is used to instruct the first gateway device to send a first uplink message through the WAN side interface, and the next hop IP address of the second default route is the IP address of the BR0 interface of the second gateway device. Among them, the priority of the first default route is higher than the second default route. In this method, if the first gateway device fails to dial and the second gateway device dials successfully, the first gateway device can switch the Internet access channel to the second gateway device. Specifically, the first gateway device forwards the first uplink message used by the user device to access the Internet to the second gateway device according to the second default route, and the first user device is a user device connected to the first gateway device. The first gateway device then receives the first downlink message from the second gateway device, and the first downlink message is used to transmit information from the Internet to the first user device.
[0008] In this implementation, the Internet access channel is switched by switching the default route on the first gateway device, without requiring a response from the user device, and thus has universality.
[0009] A second aspect of the present application provides a gateway device, the gateway device comprising:
[0010] a forwarding module configured to forward the first uplink message to the second gateway device according to a second default route if the dialing of the first gateway device fails and the dialing of the second gateway device succeeds, the first uplink message being used for the first user device to access the Internet, and the first user device being connected to the first gateway device;
[0011] The receiving module is used to receive a first downlink message from the second gateway device, where the first downlink message is used to transmit information from the Internet to the first user equipment.
[0012] Based on the first aspect and the second aspect of the present application, in some possible implementations, if the first gateway device fails to dial, the first gateway device will delete the first default route.
[0013] In this embodiment, the first gateway device deletes the first default route so that the first gateway device no longer uses the first default route and uses the second default route remaining in the routing table, thereby ensuring accurate switching of the Internet access channel.
[0014] Based on the first and second aspects of the present application, in some possible implementations, the first gateway device further maintains a status information table of third gateway devices, including Internet access status information of multiple third gateway devices. Before forwarding the first uplink message, the first gateway device needs to determine which of the multiple third gateway devices has a normal dial-up function as the second gateway device.
[0015] In this embodiment, the first gateway device maintains the Internet access status information of multiple third gateway devices, so that when the first gateway device fails to dial, it can quickly determine an available second gateway device as a backup Internet access channel.
[0016] Based on the first and second aspects of this application, in some possible implementations, the Internet access status information of the third gateway device includes one or more of the IP address of the WAN interface of the third gateway device, the connection type of the third gateway device, the interface traffic, or the dynamic host configuration protocol (DHCP) information.
[0017] In this implementation, the first gateway device may determine whether the dial-up function of the third gateway device is normal based on the Internet access status information of the third gateway device.
[0018] Based on the first and second aspects of the present application, in some possible implementations, the first gateway device does not have a bridging function and needs to forward the first uplink message through a bridging device. Specifically, the first gateway device forwards the first uplink message to the first bridging device, the first bridging device forwards the first uplink message to the second bridging device, and the second bridging device then forwards the first uplink message to the second gateway device. The first bridging device is used to connect the first gateway device and the first user device, and the second bridging device is used to connect the second gateway device and the second user device.
[0019] In this embodiment, the first gateway device and the second gateway device are connected via a bridge device, so the first uplink message can be forwarded via the first bridge device and the second bridge device without the user device responding to instructions, which is universal.
[0020] Based on the first and second aspects of the present application, in some possible implementations, when the second gateway device forwards the first downlink message to the first gateway device, the second gateway device configures the destination media access control (MAC) address of the first downlink message to the MAC address of the first gateway device.
[0021] In this embodiment, since the destination MAC address of the first downlink message is the MAC address of the first gateway device, the destination MAC address of the first downlink message is the same as the source MAC address of the first uplink message, ensuring uplink and downlink symmetry during message transmission.
[0022] Based on the first and second aspects of the present application, in some possible implementations, if the second gateway device fails to dial and the first gateway device dials successfully, the first gateway device will also receive a second uplink message from the second gateway device, and the second uplink message is used for the second user device to access the Internet, and the second user device is connected to the second gateway device.
[0023] In this embodiment, the first gateway device can receive Internet access messages from other gateway devices when dialing normally, that is, the first gateway device can also serve as a backup Internet access channel for other gateway devices.
[0024] Based on the first aspect and the second aspect of the present application, in some possible implementations, after the first gateway device receives the second uplink message from the second gateway device, the first gateway device makes a judgment based on the source MAC address of the second uplink message. If the source MAC address of the second uplink message is the MAC address of the second gateway device, the first gateway device records the source MAC address of the second uplink message. Specifically, a link tracking table is stored on the first gateway device, and the first gateway device marks the second uplink message with a mark to record the message source of the second uplink message, and the mark is saved in the link tracking table. The first gateway device receives a second downlink message from the Internet, and the second downlink message is used to transmit information from the Internet to the second user device. Specifically, the first gateway device recovers the mark from the link tracking table and configures the destination MAC address of the second downlink message based on the mark.
[0025] In this embodiment, the first gateway device configures the destination MAC address of the second downlink message through the link tracking table, thereby ensuring uplink and downlink symmetry during message transmission and being independent of specific hardware and IP address configuration.
[0026] Based on the first and second aspects of the present application, in some possible implementations, when the second gateway device sends the second uplink message to the first gateway device, the second gateway device modifies the source MAC address to the MAC address of the second user equipment.
[0027] In this implementation, the second gateway device ensures uplink and downlink symmetry during message transmission by modifying the source MAC address of the second uplink message.
[0028] Based on the first and second aspects of the present application, in some possible implementations, if the first gateway device fails to dial, the first gateway device further forwards a domain name system (DNS) query request from the first user device to a second gateway device, where the DNS query request is used for domain name resolution. The first gateway device receives a response message from the second gateway device, the response message including a result of the domain name resolution, and forwards the response message to the first user device.
[0029] In this embodiment, the first gateway device solves the problem that when the first gateway device fails to dial, the first gateway device cannot normally proxy the DNS request to the original WAN-side DNS server by forwarding the DNS query request to the second gateway device.
[0030] Based on the first and second aspects of the present application, in some possible implementations, if the first gateway device fails to dial, the first gateway device changes the IP address of the upstream DNS server of the first proxy server to the IP address of the second gateway device, wherein the IP address of the first proxy server is the IP address of the first gateway device, and the first proxy server is used to forward the DNS query request from the first user device to the upstream DNS server.
[0031] In this embodiment, the first gateway device changes the IP address of the upstream DNS server to the IP address of the second gateway device, so that the first gateway device forwards the DNS query request to the second gateway device, thereby solving the problem that when the first gateway device fails to dial, the first gateway device cannot normally proxy the DNS request to the original WAN side DNS server.
[0032] The third aspect of the present application provides an Internet access channel switching method, which is applied to a second gateway device, and a routing table is maintained on the second gateway device, which includes a third default route and a fourth default route. The third default route is used to instruct the second gateway device to send a second uplink message through the WAN interface, and the next hop IP address of the fourth default route is the IP address of the BR0 interface of the first gateway device. Among them, the priority of the third default route is higher than the fourth default route. In this method, if the second gateway device fails to dial and the first gateway device dials successfully, the second gateway device can switch the Internet access channel to the first gateway device. Specifically, the second gateway device forwards the second uplink message used by the user device to access the Internet to the first gateway device according to the first default route, and the second user device is a user device connected to the second gateway device. The second gateway device then receives a second downlink message from the first gateway device, and the second downlink message is used to transmit information from the Internet to the second user device.
[0033] A fourth aspect of the present application provides a gateway device, the gateway device comprising:
[0034] a forwarding module configured to forward the second uplink message to the first gateway device according to a fourth default route if the second gateway device fails to dial and the first gateway device succeeds in dialing, the second uplink message being used for the second user device to access the Internet, and the second user device being connected to the second gateway device;
[0035] The receiving module is used to receive a second downlink message from the first gateway device, where the second downlink message is used to transmit information from the Internet to the second user equipment.
[0036] Based on the third aspect and the fourth aspect of the present application, in some possible implementations, if the second gateway device fails to dial, the second gateway device will delete the second default route.
[0037] Based on the third and fourth aspects of the present application, in some possible implementations, the second gateway device further maintains a status information table of third gateway devices, including Internet access status information of multiple third gateway devices. Before forwarding the second uplink message, the second gateway device needs to determine that the third gateway device with normal dial-up function among the multiple third gateway devices is the first gateway device.
[0038] Based on the third and fourth aspects of this application, in some possible implementations, the Internet status information of the third gateway device includes one or more of the IP address of the WAN interface of the third gateway device, the connection type of the third gateway device, the interface traffic or DHCP information.
[0039] Based on the third and fourth aspects of the present application, in some possible implementations, the second gateway device does not have a bridging function and needs to forward the second uplink message through a bridging device. Specifically, the second gateway device forwards the second uplink message to the second bridging device, the second bridging device forwards the second uplink message to the first bridging device, and the first bridging device then forwards the second uplink message to the first gateway device. The second bridging device is used to connect the second gateway device and the second user device, and the first bridging device is used to connect the first gateway device and the first user device.
[0040] Based on the third and fourth aspects of the present application, in some possible implementations, when the first gateway device forwards the second downlink message to the second gateway device, the first gateway device configures the destination MAC address of the second downlink message as the MAC address of the second gateway device.
[0041] Based on the third and fourth aspects of the present application, in some possible implementations, if the first gateway device fails to dial and the second gateway device dials successfully, the second gateway device will also receive a first uplink message from the first gateway device, which is used for the first user device to access the Internet, and the first user device is connected to the first gateway device.
[0042] Based on the third and fourth aspects of the present application, in some possible implementations, after the second gateway device receives the first uplink message from the first gateway device, the second gateway device makes a judgment based on the source MAC address of the first uplink message. If the source MAC address of the first uplink message is the MAC address of the first gateway device, the second gateway device records the source MAC address of the first uplink message. Specifically, a link tracking table is stored on the second gateway device, and the second gateway device marks the first uplink message with a mark to record the source MAC address of the first uplink message. The second gateway device receives a first downlink message from the Internet, and the first downlink message is used to transmit information from the Internet to the first user device. The second gateway device sends the first downlink message to the first gateway device based on the source MAC address of the first uplink message. Specifically, the second gateway device recovers the mark from the link tracking table and configures the destination MAC address of the first downlink message based on the source MAC address of the first uplink message.
[0043] Based on the third and fourth aspects of the present application, in some possible implementations, when the first gateway device sends the first uplink message to the second gateway device, the first gateway device modifies the source MAC address to the MAC address of the first user device.
[0044] Based on the third and fourth aspects of the present application, in some possible implementations, if the second gateway device fails to dial, the second gateway device further forwards the DNS query request of the second user device to the first gateway device, where the DNS query request is used for domain name resolution. The second gateway device receives a response message from the first gateway device, the response message including the result of the domain name resolution, and forwards the response message to the second user device.
[0045] Based on the third and fourth aspects of the present application, in some possible implementations, if the second gateway device fails to dial, the second gateway device changes the IP address of the upstream DNS server of the second proxy server to the IP address of the first gateway device, wherein the IP address of the second proxy server is the IP address of the second gateway device, and the second proxy server is used to forward the DNS query request from the second user device to the upstream DNS server.
[0046] A fifth aspect of the present application provides a gateway device, comprising: a processor and a communication interface,
[0047] The communication interface is used to receive a signal from the second gateway device and transmit it to the processor or send a signal from the processor to the second gateway device. The processor uses a logic circuit or executes code instructions for the gateway device to implement the method as described in the first aspect above.
[0048] A sixth aspect of the present application provides a gateway device, characterized in that it includes: a processor and a communication interface,
[0049] The communication interface is used to receive a signal from the first gateway device and transmit it to the processor or send a signal from the processor to the first gateway device. The processor uses a logic circuit or executes code instructions for the gateway device to implement the method as described in the third aspect above.
[0050] A seventh aspect of the present application provides an Internet access channel switching system, characterized by comprising:
[0051] A gateway device for executing the method according to the first aspect and a gateway device for executing the method according to the third aspect;
[0052] or,
[0053] A first bridging device, a second bridging device, a gateway device for executing the method according to the first aspect, and a gateway device for executing the method according to the third aspect.
[0054] In an eighth aspect, the present application provides a computer-readable storage medium comprising instructions. When the instructions are executed on a computer, the computer executes the method as described in the first aspect, or the computer executes the method as described in the third aspect.
[0055] In a ninth aspect, the present application provides a computer program product comprising instructions, which, when executed on a computer, enables the computer to execute the method as described in the first aspect above, or enables the computer to execute the method as described in the third aspect above.
[0056] The beneficial effects of the third aspect to the ninth aspect can be understood by referring to the beneficial effects of the first aspect and the second aspect and their corresponding implementation methods, and will not be described in detail here. BRIEF DESCRIPTION OF THE DRAWINGS
[0057] FIG1 is a schematic diagram of an embodiment of the system architecture in the embodiment of the present application;
[0058] FIG2 is a schematic diagram of another embodiment of the system architecture in the embodiment of the present application;
[0059] FIG3 is a possible application scenario of the Internet access channel switching method according to an embodiment of the present application;
[0060] FIG4 is a schematic diagram of an embodiment of a method for switching an Internet access channel according to an embodiment of the present application;
[0061] FIG5 is a schematic diagram of another embodiment of the Internet access channel switching method according to an embodiment of the present application;
[0062] FIG6 is a schematic diagram of an embodiment of a domain name system query request forwarding path according to an embodiment of the present application;
[0063] FIG7 is a schematic diagram of another embodiment of the Internet access channel switching method according to an embodiment of the present application;
[0064] FIG8 is a schematic diagram of another embodiment of the Internet access channel switching method according to an embodiment of the present application;
[0065] FIG9 is a schematic diagram of another embodiment of a domain name system query request forwarding path according to an embodiment of the present application;
[0066] FIG10 is a schematic diagram of an embodiment of a gateway device in an embodiment of the present application;
[0067] FIG11 is a schematic diagram of another embodiment of a gateway device according to an embodiment of the present application;
[0068] FIG12 is a schematic diagram of another embodiment of a gateway device according to an embodiment of the present application;
[0069] FIG13 is a schematic diagram of another embodiment of a gateway device in an embodiment of the present application. DETAILED DESCRIPTION
[0070] The embodiments of the present application are described below in conjunction with the accompanying drawings. Those skilled in the art will appreciate that, with the development of technology and the emergence of new scenarios, the technical solutions provided in the embodiments of the present application are also applicable to similar technical problems.
[0071] The terms "first", "second" etc. in the specification, claims and drawings of the present application are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequential order. It should be understood that the terms used in this way can be interchangeable under appropriate circumstances, and this is merely a way of distinguishing the objects of the same attributes when describing them in the embodiments of the present application. In addition, the terms "including" and "having" and any of their variations are intended to cover non-exclusive inclusions, so that the process, method, system, product or equipment comprising a series of units need not be limited to those units, but may include other units that are not clearly listed or inherent to these processes, methods, products or equipment.
[0072] First, some technical terms involved in the embodiments of this application are introduced.
[0073] The converged edge solution combines cloud computing, edge computing, and the Internet of Things (IoT). It brings computing power to the edge of the network to enable faster and more reliable data processing and analysis. The core concept of the converged edge solution is to deploy computing, storage, and network resources at the edge, thereby reducing data transmission latency, improving data processing efficiency, and alleviating pressure on central cloud services. This solution is suitable for applications requiring real-time response, high bandwidth, and low latency, such as smart manufacturing, smart transportation, smart homes, and smart security. In the converged edge solution, edge devices are responsible for data collection and processing, and perform preliminary data analysis and processing through edge computing. Furthermore, edge devices can collaborate with the cloud, transmitting some data to the cloud for further analysis and processing. The cloud is responsible for global data management, model training, and advanced analytics.
[0074] Edge cloud is a cloud computing platform built on edge infrastructure, leveraging the core capabilities of cloud computing and edge computing. It extends some cloud services or capabilities (including but not limited to storage, computing, networking, artificial intelligence, big data, and security) to edge infrastructure. By offloading network forwarding, storage, computing, and intelligent data analysis to the edge, edge cloud can reduce response latency, alleviate pressure on the cloud, lower bandwidth costs, and provide cloud services such as network-wide scheduling and distributed computing power.
[0075] ECGW is a gateway device running on the edge cloud, primarily responsible for connecting and managing communications between IoT devices and the cloud. Specifically, ECGW can be considered a bridge device, connecting IoT devices and cloud computing centers, enabling efficient and secure data transmission between the two.
[0076] A new metropolitan area network (MAN), also known as a new metropolitan area network (NMN), is a computer communication network established within a city. It lies somewhere between a local area network (LAN) and a wide area network (WAN), typically covering a single city or several cities. This network provides high-speed data transmission and seamless connectivity, supporting a wide range of applications such as large-scale file sharing, video conferencing, and online gaming. NMNs typically use high-speed media such as optical fiber for data transmission, resulting in faster transmission speeds. They also employ LAN technology with active switching elements, minimizing transmission latency within the network.
[0077] A dual-WAN active-active solution is a network architecture design that achieves high network availability and load balancing by using two WAN interfaces to simultaneously access the internet. In this solution, both WAN interfaces can operate simultaneously, sharing network traffic. If one WAN interface fails or network quality degrades, the other WAN interface can take over traffic, ensuring network continuity and stability. This effectively avoids single points of failure and improves network reliability and performance. The dual-WAN active-active solution also achieves load balancing, distributing network traffic across both WAN interfaces to prevent overloading of a single interface. This helps improve overall network throughput and responsiveness, enhancing the user experience.
[0078] Please refer to FIG1 . The following briefly describes the system architecture based on which the Internet access channel switching method in the embodiment of the present application is based:
[0079] As shown in Figure 1, a first gateway device 101 includes a bridging module 101-1 and a routing module 101-2, while a second gateway device 103 includes a bridging module 103-1 and a routing module 103-2. Bridging modules 101-1 and 103-1 are used to forward data based on MAC addresses, while routing modules 101-2 and 103-2 are used to forward data based on IP addresses. A first user device 102 is connected to the first gateway device 101 and accesses the Internet 105 through the first gateway device 101. A second user device 104 is connected to the second gateway device 103 and accesses the Internet 105 through the second gateway device 103. Communication between the first and second gateway devices 101 and 103 is performed via the bridging modules 101-1 and 103-1. The first gateway device 101 accesses the Internet 105 via the routing module 101-2, while the second gateway device 103 accesses the Internet 105 via the routing module 103-2.
[0080] In one possible implementation, the first and second gateway devices only have routing functions, with the bridging functions implemented by the bridge devices, as shown in Figure 2. First bridge device 202 is used to connect first gateway device 201 and first user device 203, and second bridge device 205 is used to connect second gateway device 204 and second user device 206. First user device 203 connects to first gateway device 201 and accesses the Internet 207 through first gateway device 201. Second user device 206 connects to second gateway device 204 and accesses the Internet 207 through second gateway device 204. First bridge device 102 and second bridge device 105 forward data based on MAC addresses, while first gateway device 101 and second gateway device 104 forward data based on IP addresses.
[0081] In one possible implementation, the first gateway device 101 shown in FIG1 is a virtual gateway (NERG) on the ECGW, and the second gateway device 103 is an ONT with routing functionality. The first gateway device 201 and the first bridge device 202 shown in FIG2 are both virtual devices on the ECGW, the second gateway device 204 is a router or switch, and the second bridge device 205 is an ONT without routing functionality.
[0082] Figure 3 illustrates a possible application scenario for a method for switching Internet access channels. As shown in Figure 3, a user has two ONTs and one NERG. The ONTs and NERGs communicate via a LAN interface. Segment Routing IPv6 (SRv6) based on the IPv6 forwarding plane is used in the new city network for networking. Traffic between the ONTs and NERGs may pass through multiple forwarding devices, including optical line terminals (OLTs), leaf switches, and data processing units (DPUs). The ONTs are registered with the NERGs and are centrally managed by them. The ONTs are located on the access side, and the NERGs are located on the edge cloud gateway. User devices connected to the ONTs dial up to the Internet via the ONTs. The next-hop address of the user device's default route is the IP address of the ONT's bridge interface, which is used to connect to the user device. Internet traffic first reaches the ONT's bridge interface and is then forwarded by the ONT device to the WAN interface. When the ONT's WAN interface fails or the PPPoE link fails, the Internet traffic on the ONTs needs to be switched to the NERGs, allowing access to the Internet via the NERG's WAN interface. There are several possible solutions to switch traffic to NERG:
[0083] In one possible implementation, the DHCP dial-up function on the LAN side of the ONT is disabled, and a DHCP force renew command is sent to the user device to trigger the user device to dial up. The DHCP force renew command is used to force the user device to re-obtain an IP address and other network configuration parameters from the DHCP server.
[0084] In another possible implementation, an ICMP redirect command is sent to the user device to modify the next hop of the user device's default route to NERG. When a router receives a packet from an interface and then sends the packet to the destination through the same interface (that is, the interface on which the router received the packet is the egress to the destination), it sends an ICMP redirect to the source address of the packet, instructing the router to send the packet directly to its next hop, rather than to itself. Because the router must receive the packet before sending the ICMP redirect command, the first message does not take effect immediately.
[0085] The implementation of the above two instructions depends on the response of the user equipment. However, in actual applications, the user equipment may not be able to respond to the above instructions, so they are not universal.
[0086] In view of this, embodiments of the present application provide an Internet access channel switching method, a gateway device, and an Internet access channel switching system for implementing active / standby switching between an ONT and a NERG.
[0087] As shown in FIG4 , a WAN interface failure or a PPPoE link failure occurs on the first gateway device 101, and the first gateway device 101 needs to switch to the second gateway device 103 to access the Internet. Referring to FIG5 , an Internet access channel switching method in an embodiment of the present application includes:
[0088] 501. The first gateway device detects an Internet link failure;
[0089] The first gateway device receives a first uplink message from the first user device, where the first uplink message is used by the first user device to access the Internet. The routing module of the first gateway device periodically sends Link Control Protocol (LCP) messages through the PPPoE port to detect the link status of the PPPoE link. When the PPPoE link fails, the first gateway device fails to dial up, and the first gateway device needs to switch to an Internet access channel.
[0090] 502. The first gateway device forwards the first uplink message to the second gateway device;
[0091] A routing table is stored on the first gateway device, which includes a first default route and a second default route, and the priority of the first default route is higher than that of the second default route. In one possible implementation, the first default route is called a high-priority default route, and the second default route is called a low-priority default route. The first default route is used to instruct the gateway device to access the Internet through a designated interface using the PPPoE protocol, and the next-hop address of the second default route is the IP address of the second gateway device. In one possible implementation, the next-hop address of the second default route is the IP address of the BR0 interface of the second gateway device. The IP address of the BR0 interface of the second gateway device is obtained by information synchronization between the first gateway device and the second gateway device. When the first gateway device detects a PPPoE link failure, that is, when the first gateway device fails to dial, the first gateway device deletes the first default route and forwards the first uplink message to the second gateway device according to the second default route.
[0092] In one possible implementation, a plurality of third gateway devices are registered on the first gateway device, and the first gateway device selects a third gateway device from the plurality of third gateway devices as a backup Internet access channel. Specifically, the first gateway device maintains a status list of the third gateway devices, which includes the Internet access channel status of one or more third gateway devices. The first gateway device traverses all third gateway devices, determines that the first retrieved third gateway device with normal Internet Protocol version 4 (internet protocol version 4, IPv4) and Internet Protocol version 6 (internet protocol version 6, IPv6) dual stack dialing is the second gateway device, and stops traversing. If it cannot be retrieved, traverse again, determine that the first retrieved third gateway device with normal IPv4 dialing is the second gateway device, and stop traversing.
[0093] In the embodiment of the present application, since the first gateway device switches the Internet access channel by changing the forwarding route, it no longer depends on the response of the user device. That is, regardless of whether the user device has the ability to respond to instructions, the Internet access channel can be switched, so it has universality.
[0094] In one possible implementation, when the first gateway device forwards the first uplink message to the second gateway device, the bridging module of the first gateway device changes the source MAC address of the first uplink message from the MAC address of the first user device to the MAC address of the BR0 interface of the first gateway device. At the same time, since the destination MAC address of the first downlink message is the MAC address of the first user device, the destination MAC address of the first downlink message is asymmetric with the source MAC address of the first uplink message. Therefore, the first gateway device needs to change the source MAC address of the first uplink message from the MAC address of the BR0 interface of the first gateway device to the MAC address of the first user device. In other words, when the first gateway device forwards the first uplink message to the second gateway device, it keeps the source MAC address of the first uplink message unchanged, that is, the source MAC address of the first uplink message is still the MAC address of the first user device.
[0095] In one possible implementation, when the first gateway device fails to dial, the first gateway device will also modify the address of the upstream server of the DNS proxy service to the IP address of the second gateway device. Specifically, when the first gateway device is normal, the first user device dials from the first gateway device, and the IP address of its proxy server is the IP address of the first gateway device. The first gateway device proxies the DNS request with the destination IP address being the local IP address to the upstream server, that is, the DNS server on the WAN side. When the first gateway device fails to dial, the first gateway device cannot proxy the DNS request to the original WAN-side DNS server, so it is necessary to switch the IP address of the upstream server to the IP address of the second gateway device, so that the DNS request is sent from the first gateway device to the second gateway device, and then proxied to the DNS server by the second gateway device.
[0096] Figure 6 illustrates a possible DNS request routing path. As shown in Figure 6, the proxy server address of the first gateway device is 192.168.31.1, the IP address of the first gateway device, and the proxy server address of the second gateway device is 192.168.16.1, the IP address of the second gateway device. The first gateway device changes the IP address of the upstream server from the DNS server on the WAN side of the first gateway device to the IP address of the second gateway device. Therefore, the DNS request will be forwarded from the first gateway device to the second gateway device, which will then proxy the request to the DNS server.
[0097] The second gateway device receives the first uplink message from the first gateway device, and forwards the first uplink message to the Internet.
[0098] In one possible implementation, the second gateway device maintains a link tracking table. Upon receiving a first uplink message, the second gateway device determines whether the source MAC address of the first uplink message is the MAC address of the first gateway device. If so, the second gateway device marks the message and records the mark value in the link tracking table. The link tracking table is used to ensure that the destination MAC address of the first downlink message is consistent with the source MAC address of the first uplink message.
[0099] In the embodiment of the present application, the bridging module of the first gateway device changes the source MAC address of the first uplink message when sending the first uplink message, while the destination MAC address of the first downlink message is the MAC address of the first user device, resulting in uplink and downlink asymmetry. The link tracking table can be used to modify the destination MAC address of the first downlink message to be the same as the source MAC address of the first uplink message, thereby resolving the uplink and downlink asymmetry problem.
[0100] It should be noted that the mark value is used to indicate the source of a message. Taking an ONT and a NERG as an example, in one possible implementation, the first ONT sends an uplink message to the NERG, which then forwards the uplink message to the second ONT. In this case, the source of the uplink message is the first ONT. The second ONT adds a mark to the uplink message to indicate that it originated from the first ONT. When the second ONT receives a downlink message, it configures the destination MAC address of the downlink message to be the first ONT based on the mark.
[0101] 503. The second gateway device forwards the first downlink message to the first gateway device;
[0102] The second gateway device forwards the first uplink message to the Internet and receives a first downlink message from the Internet. In one possible implementation, the first downlink message is a response message to the first uplink message. The first downlink message is used to transmit information from the Internet to the first user equipment. The second gateway device sends the first downlink message to the first gateway device.
[0103] In one possible implementation, after receiving the first downlink message, the second gateway device recovers the mark value according to the link tracking table, determines the destination MAC address of the first downlink message in the routing table according to the mark value, and modifies the destination MAC address of the first downlink message to the MAC address of the gateway device.
[0104] In an embodiment of the present application, by recording the source MAC address corresponding to the first uplink message, the destination MAC address of the first downlink message is modified according to the source MAC address when sending the first downlink message, so that the first uplink message and the first downlink message are symmetrical.
[0105] It should be noted that this embodiment takes the failure of the PPPoE link of the first gateway device as an example. Similarly, the implementation method when the PPPoE link of the second gateway device fails can refer to this embodiment, and the details will not be repeated here.
[0106] In another possible implementation, the first gateway device and the second gateway device do not have a bridging function, and the bridging function is implemented by the first bridging device and the second bridging device, as shown in Figure 7. Referring to Figure 8, an Internet access channel switching method in an embodiment of the present application includes:
[0107] 801. The first gateway device detects an Internet link failure;
[0108] Step 801 in this embodiment is similar to step 501 in the embodiment shown in FIG. 5 , and will not be described in detail here.
[0109] 802. The first gateway device forwards the first uplink message to the second gateway device through the first bridge device.
[0110] A routing table is stored on the first gateway device, which includes a first default route and a second default route, and the first default route has a higher priority than the second default route. The first default route is used to instruct the gateway device to access the Internet through a specified interface using the PPPoE protocol, and the next hop address of the second default route is the IP address of the second gateway device. In a possible implementation, the next hop address of the second default route is the IP address of the BR0 interface of the second gateway device. The IP address of the BR0 interface of the second gateway device is obtained by information synchronization between the first gateway device and the second gateway device. When the Internet link of the first gateway device fails, that is, the first gateway device fails to dial, the first gateway device obtains the MAC address corresponding to the IP address of the next hop of the second route according to the low-priority default route in the routing table, that is, the second route. Specifically, the first gateway device obtains the MAC address of the BR0 interface of the second gateway device according to the address resolution protocol (ARP), and determines the transmission path of the first uplink message according to the MAC address table on the first gateway device. As shown in Figure 7, the first uplink message needs to be sent from the first gateway device to the second bridge device via the first bridge device, and then forwarded by the second bridge device to the second gateway device. It should be understood that the IP address of the second gateway device corresponds to the MAC address of the BR0 interface of the second gateway device.
[0111] In one possible implementation, when the first bridging device forwards the first uplink message to the second bridging device, the first bridging device changes the source MAC address of the first uplink message from the MAC address of the first bridging device to the MAC address of the first user device. Alternatively, when the first bridging device forwards the first uplink message to the second bridging device, the first bridging device maintains the source MAC address of the first uplink message unchanged; in this case, the source MAC address of the first uplink message remains the MAC address of the first user device.
[0112] In one possible implementation, when the first gateway device fails to dial, the first gateway device will also modify the address of the upstream server of the Domain Name System (DNS) proxy service to the address of the second gateway device. Specifically, when the first gateway device dials normally, the first user device dials from the first gateway device, and its proxy server is the IP address of the first gateway device. The first gateway device proxies the DNS request to the upstream server, that is, the DNS server on the WAN side. When the first routing dial fails, the first gateway device cannot proxy the DNS request to the original WAN-side DNS server. Therefore, it is necessary to switch the address of the upstream server to the IP address of the second gateway device, so that the DNS request is transmitted from the first gateway device to the first bridge device, through the second bridge device to the second gateway device, and then proxied by the second gateway device to the DNS server.
[0113] Figure 9 illustrates a possible DNS request routing path. As shown in Figure 9, the proxy server address of the first gateway device is 192.168.31.1, the IP address of the first gateway device, and the proxy server address of the second gateway device is 192.168.16.1, the IP address of the second gateway device. The first gateway device changes the upstream server address from the DNS server on the WAN side of the first gateway device to the IP address of the second gateway device. Therefore, the DNS request will be routed from the first gateway device to the first bridge device, then to the second gateway device via the second bridge device, and then proxied by the second gateway device to the DNS server.
[0114] In one possible implementation, the second gateway device maintains a link tracking table. Upon receiving the first uplink message, the second gateway device determines whether the source MAC address of the first uplink message is the gateway device's MAC address. If so, the second gateway device marks the message and records the mark value in the link tracking table. The link tracking table ensures that the destination MAC address of the first downlink message is consistent with the source MAC address of the first uplink message.
[0115] 803. The second gateway device forwards the first downlink message to the first gateway device through the second bridge device.
[0116] The second gateway device forwards the first uplink message to the Internet, and receives a first downlink message from the Internet, the first downlink message being a response message to the first uplink message and used to transmit information from the Internet to the first user device. The second gateway device sends the first downlink message to the second bridge device.
[0117] In one possible implementation, after receiving the first downlink message, the second gateway device recovers the mark value according to the link tracking table and determines the destination MAC address of the first downlink message in the routing table according to the mark value. The second bridge device modifies the destination MAC address of the first downlink message to the MAC address of the gateway device.
[0118] It should be understood that the actual functions of the IP address and MAC address in the embodiments of the present application are not limited to specific names and can also be other names, which are not specifically limited here.
[0119] The above describes the information synchronization method in the embodiment of the present application. The following describes the gateway device in the embodiment of the present application. Please refer to Figure 10. An embodiment of the gateway device 1000 in the embodiment of the present application includes:
[0120] Forwarding module 1001, configured to forward a first uplink message to the second gateway device according to a second default route if the first gateway device fails to dial and the second gateway device succeeds in dialing, the first uplink message being used for the first user device to access the Internet, and the first user device being connected to the first gateway device;
[0121] The receiving module 1002 is configured to receive a first downlink message from a second gateway device, where the first downlink message is used to transmit information from the Internet to the first user equipment.
[0122] Referring to FIG. 11 , an embodiment of a gateway device 1100 in an embodiment of the present application includes:
[0123] Forwarding module 1101, configured to forward a second uplink message to the first gateway device according to a fourth default route if the second gateway device fails to dial and the first gateway device succeeds in dialing, the second uplink message being used for the second user device to access the Internet, and the second user device being connected to the second gateway device;
[0124] The receiving module 1102 is configured to receive a second downlink message from the first gateway device, where the second downlink message is used to transmit information from the Internet to the second user equipment.
[0125] Next, a gateway device provided in an embodiment of the present application will be introduced. Please refer to Figure 12, which is a structural diagram of the gateway device provided in an embodiment of the present application.
[0126] The gateway device is specifically a communication device, including: a receiver 1201, a transmitter 1202, a processor 1203, and a memory 1204 (wherein the number of processors 1203 in the gateway device can be one or more), wherein the processor 1203 may include an application processor 1203-1 and a communication processor 1203-2. In some embodiments of the present application, the receiver 1201, the transmitter 1202, the processor 1203, and the memory 1204 may be connected via a bus or other means.
[0127] If it is wireless communication, the receiver 1201 and the transmitter 1202 can be connected to an antenna. If it is wired communication, the receiver 1201 and the transmitter 1202 can be connected to a cable.
[0128] The memory 1204 may include a read-only memory and a random access memory, and provides instructions and data to the processor 1203. A portion of the memory 1204 may also include non-volatile random access memory (NVRAM). The memory 1204 stores processor and operation instructions, executable modules, or data structures, or subsets or extended sets thereof. The operation instructions may include various operation instructions for implementing various operations.
[0129] Processor 1203 controls the operation of the gateway device. In specific applications, the various components of the gateway device are coupled together via a bus system. In addition to a data bus, the bus system may also include a power bus, a control bus, and a status signal bus. However, for clarity, the various buses are collectively referred to as a bus system in the figure.
[0130] The method of the foregoing embodiment can be applied to the processor 1203, or implemented by the processor 1203. The processor 1203 can be an integrated circuit chip with signal processing capabilities. During the implementation process, the steps of the foregoing method can be completed by the integrated logic circuit of the hardware in the processor 1203 or the instructions in the form of software. The above-mentioned processor 1203 can be a general-purpose processor, a digital signal processor (digital signal processing, DSP), a microprocessor or a microcontroller, and a vision processor (vision processing unit, VPU), a tensor processor (tensor processing unit, TPU) and other processors suitable for AI computing, and can further include an application specific integrated circuit (ASIC), a field programmable gate array (field-programmable gate array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The processor 1203 can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in conjunction with the embodiments of this application can be directly implemented as being executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium well-known in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. The storage medium is located in memory 1204, and processor 1203 reads the information in memory 1204 and, in conjunction with its hardware, executes the method based on the aforementioned embodiments.
[0131] Receiver 1201 can be used to receive input digital or character information and generate signal input related to executing device-related settings and function control. Transmitter 1202 can be used to output digital or character information through the first interface. Transmitter 1202 can also be used to send instructions to the disk pack through the first interface to modify data in the disk pack. Transmitter 1202 can also include a display device such as a display screen.
[0132] Next, a gateway device provided in an embodiment of the present application will be introduced. Please refer to Figure 13, which is a structural diagram of the gateway device provided in an embodiment of the present application.
[0133] The gateway device is specifically a communication device, including: a receiver 1301, a transmitter 1302, a processor 1303, and a memory 1304 (wherein the number of processors 1303 in the gateway device can be one or more), wherein the processor 1303 may include an application processor 1303-1 and a communication processor 1303-2. In some embodiments of the present application, the receiver 1301, the transmitter 1302, the processor 1303, and the memory 1304 may be connected via a bus or other means.
[0134] If it is wireless communication, the receiver 1301 and the transmitter 1302 can be connected to an antenna. If it is wired communication, the receiver 1301 and the transmitter 1302 can be connected to a cable.
[0135] Memory 1304 may include read-only memory and random access memory, and provides instructions and data to processor 1303. A portion of memory 1304 may also include non-volatile random access memory (NVRAM). Memory 1304 stores processor and operation instructions, executable modules, or data structures, or subsets or extended sets thereof. The operation instructions may include various operation instructions for implementing various operations.
[0136] Processor 1303 controls the operation of the gateway device. In specific applications, the various components of the gateway device are coupled together via a bus system. In addition to a data bus, the bus system may also include a power bus, a control bus, and a status signal bus. However, for clarity, the various buses are collectively referred to as a bus system in the figure.
[0137] The method of the foregoing embodiment can be applied to the processor 1303, or implemented by the processor 1303. The processor 1303 can be an integrated circuit chip with signal processing capabilities. During the implementation process, the steps of the foregoing method can be completed by the integrated logic circuit of the hardware in the processor 1303 or the instructions in the form of software. The above-mentioned processor 1303 can be a general-purpose processor, a digital signal processor (digital signal processing, DSP), a microprocessor or a microcontroller, and a vision processor (vision processing unit, VPU), a tensor processor (tensor processing unit, TPU) and other processors suitable for AI computing, and can further include an application specific integrated circuit (ASIC), a field programmable gate array (field-programmable gate array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The processor 1303 can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc. The steps of the method disclosed in conjunction with the embodiments of this application can be directly implemented as being executed by a hardware decoding processor, or by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium well-known in the art, such as random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, etc. The storage medium is located in memory 1304, and processor 1303 reads the information in memory 1304 and, in conjunction with its hardware, executes the method based on the aforementioned embodiments.
[0138] Receiver 1301 can be used to receive input digital or character information and generate signal input related to executing device-related settings and function control. Transmitter 1302 can be used to output digital or character information through the first interface. Transmitter 1302 can also be used to send instructions to the disk pack through the first interface to modify data in the disk pack. Transmitter 1302 can also include a display device such as a display screen.
[0139] Those skilled in the art will clearly understand that, for the convenience and brevity of description, the specific working processes of the systems, devices and units described above can refer to the corresponding processes in the aforementioned method embodiments and will not be repeated here.
[0140] In the several embodiments provided in this application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are merely schematic. For example, the division of the units is merely a logical function division. In actual implementation, there may be other division methods, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be an indirect coupling or communication connection through some interfaces, devices or units, which can be electrical, mechanical or other forms.
[0141] The units described as separate components may or may not be physically separate, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0142] In addition, the functional units in the various embodiments of the present application may be integrated into a single processing unit, or each unit may exist physically separately, or two or more units may be integrated into a single unit. The aforementioned integrated units may be implemented in the form of hardware or software functional units.
[0143] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application is essentially or the part that contributes to the prior art or all or part of the technical solution can be embodied in the form of a software product, and the computer software product is stored in a storage medium, including a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.
Claims
1. A method for switching Internet access channels, characterized in that: The method is applied to a first gateway device, the first gateway device maintains a routing table, the routing table includes a first default route and a second default route, the first default route is used to instruct the first gateway device to forward a first uplink message to the Internet, the second default route is used to instruct the first gateway device to forward the first uplink message to a second gateway device, the priority of the first default route is higher than the priority of the second default route, the method includes: If the dialing of the first gateway device fails and the dialing of the second gateway device succeeds, forwarding the first uplink message to the second gateway device according to the second default route, where the first uplink message is used for the first user device to access the Internet, and the first user device is connected to the first gateway device; A first downlink message is received from the second gateway device, where the first downlink message is used to transmit information from the Internet to the first user equipment.
2. The method according to claim 1, characterized in that The method further comprises: If the dialing of the first gateway device fails, the first default route is deleted.
3. The method according to claim 1 or 2, characterized in that The first gateway device stores online status information of multiple third gateway devices; Before forwarding the first uplink message to the second gateway device according to the second route, the method further includes: The first gateway device determines, according to the Internet access status information, the third gateway device with a normal dial-up function among the plurality of third gateway devices as the second gateway device.
4. The method according to any one of claims 1 to 3, characterized in that The forwarding the first uplink message to the second gateway device according to the second default route includes: The first uplink message is forwarded to a first bridging device according to the second default route, where the first bridging device is used to connect the first user device and the first gateway device, and the first bridging device is used to forward the first uplink message to a second bridging device, where the second bridging device is used to connect the second user device and the second gateway device, and the second bridging device is used to forward the first uplink message to the second gateway device.
5. The method according to any one of claims 1 to 3, characterized in that The destination media access control address of the first downlink message is the media access control address of the first gateway device.
6. The method according to any one of claims 1 to 5, characterized in that The method further comprises: If the second gateway device fails to dial and the first gateway device dials successfully, a second uplink message from the second gateway device is received, where the second uplink message is used for the second user device to access the Internet, and the second user device is connected to the second gateway device.
7. The method according to claim 6, characterized in that After receiving the second uplink message from the second gateway device, the method further includes: If the source media access control address of the second uplink message is the media access control address of the second gateway device, recording the message source of the second uplink message; receiving a second downlink message, where the second downlink message is used to transmit information from the Internet to the second user equipment; The second downlink message is sent to the second gateway device according to the message source of the second uplink message.
8. The method according to claim 6 or 7, characterized in that The source media access control address of the second uplink message is the media access control address of the second user equipment.
9. The method according to any one of claims 1 to 8, characterized in that The method comprises: If the first gateway device fails to dial, forwarding the domain name system query request from the first user device to the second gateway device, where the domain name system query request is used for domain name resolution; receiving a response message from the second gateway device, the response message including a result of the domain name resolution; Forward the response message to the first user equipment.
10. The method according to claim 9, characterized in that Before forwarding the domain name system query request from the first user equipment to the second gateway device, the method further includes: If the first gateway device fails to dial, the Internet Protocol address of the upstream domain name server of the first proxy server is changed to the Internet Protocol address of the second gateway device. The Internet Protocol address of the first proxy server is the Internet Protocol address of the first gateway device. The first proxy server is used to forward the domain name system query request from the first user device to the upstream domain name server.
11. A method for switching Internet access channels, characterized in that: The method is applied to a second gateway device, where the second gateway device maintains a routing table, where the routing table includes a third default route and a fourth default route, where the third default route is used to instruct the second gateway device to forward a second uplink message to the Internet, and the fourth default route is used to instruct the second gateway device to forward the second uplink message to the first gateway device, where the priority of the third default route is higher than the priority of the fourth default route, and the method includes: If the second gateway device fails to dial and the first gateway device dials successfully, forwarding the second uplink message to the first gateway device according to the fourth route, the second uplink message is used for the second user device to access the Internet, and the second user device is connected to the second gateway device; A second downlink message is received from the first gateway device, where the second downlink message is used to transmit information from the Internet to the second user equipment.
12. The method according to claim 11, characterized in that The method further comprises: If the second gateway device fails to dial, the third default route is deleted.
13. The method according to claim 11 or 12, characterized in that The forwarding the second uplink message to the first gateway device according to the fourth route includes: The second uplink message is forwarded to a second bridging device according to the fourth route, where the second bridging device is used to connect the second user equipment and the second gateway device, and the second bridging device is used to forward the second uplink message to a first bridging device, where the first bridging device is used to connect the first user equipment and the first gateway device, and the first bridging device is used to forward the second uplink message to the first gateway device.
14. The method according to claim 11 or 12, characterized in that The destination media access control address of the second downlink message is the media access control address of the second gateway device.
15. The method according to any one of claims 11 to 14, characterized in that The method further comprises: If the first gateway device fails to dial and the second gateway device dials successfully, a first uplink message from the first gateway device is received, where the first uplink message is used for the first user device to access the Internet, and the first user device is connected to the first gateway device.
16. The method according to claim 15, characterized in that After the second gateway device receives the first uplink message from the first gateway device, the method further includes: If the source media access control address of the first uplink message is the media access control address of the first gateway device, recording the message source of the first uplink message; receiving a first downlink message, where the first downlink message is used to transmit information from the Internet to the first user equipment; The first downlink message is sent to the first gateway device according to the message source of the first uplink message.
17. The method according to claim 15 or 16, characterized in that The source media access control address of the first uplink message is the media access control address of the first user equipment.
18. The method according to any one of claims 11 to 17, characterized in that The method comprises: If the second gateway device fails to dial, forwarding the domain name system query request from the second user device to the first gateway device, where the domain name system query request is used for domain name resolution; receiving a response message from the first gateway device, the response message including a result of the domain name resolution; Forward the response message to the second user equipment.
19. The method according to claim 18, characterized in that Before forwarding the domain name system query request from the second user equipment to the first gateway device, the method further includes: If the second gateway device fails to dial, the Internet Protocol address of the upstream domain name server of the second proxy server is changed to the Internet Protocol address of the first gateway device. The Internet Protocol address of the second proxy server is the Internet Protocol address of the second gateway device. The second proxy server is used to forward the domain name system query request from the second user device to the upstream domain name server.
20. A gateway device, characterized in that: The method comprises modules or units for executing the method according to any one of claims 1 to 10.
21. A gateway device, characterized in that: The method comprises modules or units for performing the method according to any one of claims 11 to 19.
22. A gateway device, characterized in that: include: processor and communication interfaces, The communication interface is used to receive a signal from a second gateway device and transmit it to the processor or send a signal from the processor to the second gateway device. The processor uses a logic circuit or executes code instructions for the gateway device to implement the method as described in any one of claims 1 to 10.
23. A gateway device, characterized in that: include: processor and communication interfaces, The communication interface is used to receive a signal from the first gateway device and transmit it to the processor or send a signal from the processor to the first gateway device. The processor uses a logic circuit or executes code instructions for the gateway device to implement the method as described in any one of claims 11 to 19.
24. An Internet access channel switching system, characterized in that: include: A gateway device for performing the method according to any one of claims 1 to 10 and a gateway device for performing the method according to any one of claims 11 to 19; or, A first bridging device, a second bridging device, a gateway device for executing the method according to any one of claims 1 to 10, and a gateway device for executing the method according to any one of claims 11 to 19.
25. A computer-readable storage medium comprising instructions, which, when executed on a computer, cause the computer to execute the method according to any one of claims 1 to 10, or cause the computer to execute the method according to any one of claims 11 to 19.
26. A computer program product comprising instructions which, when run on a computer, cause the computer to perform the method according to any one of claims 1 to 10, or cause the computer to perform the method according to any one of claims 11 to 19.