FTTR multi-uplink fast switching method, equipment and medium

By acquiring and processing multiple uplink states of the FTTR subgateway, quickly switch to the backup link and detecting the ETH port, the long uplink switching time and loop problems in the FTTR network are solved, and fast service recovery and loop are achieved Road prevention.

CN119094434AActive Publication Date: 2024-12-06FIBERHOME TELECOMMUNICATION TECHNOLOGIES CO LTD
View PDF 10 Cites 0 Cited by

Patent Information

Application Number
CN202411242981.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-05
Publication Date
2024-12-06
Estimated Expiration
2044-09-05

AI Technical Summary

Technical Problem

In the FTTR networking scenario, when the uplink between the main sub-gateways is abnormal, it is difficult for the prior art to quickly switch to the backup link, resulting in a long service recovery time and loop problems are prone to occur during the switching process.

Method used

By obtaining the PON, ETH and WIFI link status on the subgateway, switching to the backup link according to the uplink priority, and by quickly probing the ETH port, the WAN management module is notified to delete the old forwarding network card interface and create a new interface to achieve rapid development Switch to prevent loop formation.

Benefits of technology

The FTTR gateway is implemented to complete the service recovery time of WIFI to ETH switching and PON to ETH switching within 10 seconds, and avoid loop problems during the switching process, improving the efficiency and reliability of uplink switching.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119094434A_ABST
    Figure CN119094434A_ABST
Patent Text Reader

Abstract

The invention discloses an FTTR multi-uplink fast switching method and device and a medium, and belongs to the technical field of FTTR uplink link switching, and the method comprises the steps: switching a current uplink of an FTTR sub-gateway to a standby link according to the priority of the uplink by obtaining the state of a PON link identified by an LOS signal on the sub-gateway; calculating and selecting an uplink port according to a received detection result generated by detecting the ETH port of the sub-gateway, notifying a WAN management module to delete a forwarding network card interface of an uplink, and creating a forwarding network card interface corresponding to the switched uplink; and opening a user side ETH port, and triggering the DHCPC module to send a DHCP request message to a network side to obtain an interface address. According to the invention, services of switching from WIFI to ETH and switching from PON to ETH of the FTTR sub-gateway can be quickly recovered, and a loop can be prevented.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of FTTR uplink switching, and in particular, relates to a FTTR multi-uplink fast switching method, device and medium. Background Art

[0002] In the FTTR networking scenario, the master and slave gateways can be networked through optical fiber, network cable, and WIFI. In actual deployment, there will be multiple networks in the FTTR network at the same time, and the network will change dynamically, such as networking through optical fiber, WIFI as a backup link, or networking through network cable, WIFI as a backup link, etc. In actual networking, the networking between the master and the slave is very complicated. There may be switches in the master and slave networks, cascade networking between the slave gateways, and networking between different slave gateways through WIFI. FTTR is currently widely used in home, enterprise and other scenarios. In order to ensure that user services are not affected when the current uplink is abnormal, it is necessary to dynamically switch to the backup link in time.

[0003] Among the three networking modes of the main and sub-gateways, namely optical fiber, network cable, and WIFI uplink, in actual deployment, there will be multiple networking modes at the same time. The FTTR sub-gateway needs to select a route to avoid loops between the same sub-gateway and the main gateway. In addition, the number of ETH ports on some FTTR sub-gateways is very limited, with only two. When the ETH port of the sub-gateway is configured as an uplink networking port, it can also be used as a user port. Mixed insertion of ETH ports is common. Whether the uplink networking port of the sub-gateway is networked through the ETH port needs to be detected. The existing detection method for the FTTR uplink ETH port is usually to send a DHCP or PPPoE (server) request message through the sub-gateway for detection. If the above server responds to the message, the port is an uplink networking port, otherwise it is a user port.

[0004] However, when the main gateway is in bridge mode, the sub-gateway is assigned an address by the DHCP server above, and the external network DHCP server responds to the DHCP request message with a delay of 3s, and the detection time is close to 5s. In addition, when ETH is networked upstream, the devices in the network usually turn on the STP protocol to prevent loops. For example, when the main and sub-gateways are networked through network cables, switches are usually connected in the middle for networking. When the ETH port is UP, it will trigger the recalculation of the ports in the network. During the STP protocol calculation process, the ETH port only allows loop detection messages to be released, and the DHCP detection message of the sub-gateway cannot be sent successfully, which will cause the detection time to be as long as 20s, affecting the upstream switching time, and then affecting the service recovery time when PON, ETH and other upstream switches are switched. When the ETH port detects for too long, WIFI will automatically network, and a loop will be formed between the WIFI and ETH ports. Summary of the invention

[0005] In view of the above problems, the present disclosure proposes a FTTR multi-uplink fast switching method, electronic device and medium. It can realize fast switching under multiple FTTR uplink modes, and the ETH multiplexing port detection time reaches millisecond level, thereby realizing the FTTR gateway WIFI to ETH switching and PON-ETH switching service time recovery within 10s, and can prevent loops from occurring during the switching process.

[0006] The present application embodiment provides a FTTR multi-uplink fast switching method, which is applied to a sub-gateway, including:

[0007] Get the PON link status, ETH link status and WIFI link status marked by LOS signal on the sub-gateway;

[0008] When the sub-gateway receives a failure in sending any of the PON link status, ETH link status and WIFI link status, the current uplink of the FTTR sub-gateway is switched to the backup link according to the uplink priority;

[0009] According to the detection result generated by detecting the ETH port of the sub-gateway, the uplink port is calculated, the WAN management module is notified to delete the forwarding network card interface of the uplink, and the forwarding network card interface corresponding to the switched uplink is created;

[0010] Open the user-side ETH port, trigger the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notify OMCI.

[0011] Further, the obtaining of the PON link status identified by the LOS signal on the sub-gateway includes:

[0012] When the PON link generates a LOS signal, the PON link is marked as DOWN and the link status is faulty;

[0013] When the PON link LOS signal disappears, the PON link is marked as UP, and the link status is normal.

[0014] Further, the detection result generated by detecting the ETH port of the sub-gateway includes:

[0015] Anti-shake detection is performed on the ETH port status, wherein the received ETH port status change message is delayed;

[0016] When the delay time is greater than the anti-jitter time, it is determined that the ETH port state of the sub-gateway is stable.

[0017] Further, the calculating the uplink port according to the received detection result generated by detecting the ETH port of the sub-gateway includes:

[0018] According to the state machine transition change and anti-shake processing, the received timer message, link state change message and ETH port detection result, etc., the FTTR sub-gateway uplink is selected and controlled;

[0019] Define the ETH port roles, including uplink networking port, user port, and multiplexing port; detect whether the ETH port is a multiplexing port.

[0020] Further, the detecting that the ETH port is a multiplexed port includes:

[0021] In the initial state of the ETH port as a multiplexed port, when the sub-gateway is detected to switch from the PON link to the ETH link or from the WIFI link to the ETH link; the WAN management module first closes and then opens all ETH ports;

[0022] After the sub-gateway receives the UP message of the upstream networking ETH port, the ETH port detection is triggered. The FTTR sub-gateway receives the ETH port detection message response from the main gateway or the detection times out, and the ETH multiplexing port detection ends.

[0023] Furthermore, the method further comprises:

[0024] If the ETH port in the detection result is a user port, the loop detection module is notified to run the loop detection protocol on the user port;

[0025] If the ETH port in the detection result is an uplink networking port, the loop detection module is notified to stop running the loop detection protocol on the uplink networking port;

[0026] During the detection period, the ETH multiplexing port does not run the loop detection protocol.

[0027] Furthermore, the method further comprises:

[0028] The detection result is sent to the multi-uplink detection module, and the multi-uplink detection module starts a state machine to calculate the port status and selects an uplink port according to the port status calculation result.

[0029] Furthermore, the method further comprises:

[0030] Notify the WAN management module to delete the forwarding network card port of the previous uplink and create a forwarding network card port corresponding to the uplink after the switch;

[0031] The WAN management module closes the opened user-side ETH port, triggering the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notifies OMCI and device management to turn on the light.

[0032] Based on the same inventive concept, another aspect of the embodiment of the present disclosure further provides an electronic device, comprising: a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus;

[0033] a memory storing a computer program;

[0034] The processor implements a FTTR multi-uplink fast switching method when executing the program stored in the memory.

[0035] Based on the same inventive concept, the embodiment of the present disclosure further provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements a FTTR multi-uplink fast switching method.

[0036] Beneficial effects of the present disclosure: The present application obtains the PON link status, ETH link status and WIFI link status after being identified by the LOS signal on the sub-gateway; when any of the PON link status, ETH link status and WIFI link status of the sub-gateway fails, the current uplink of the FTTR sub-gateway is switched to the backup link according to the uplink priority; the detection result generated by the detection of the ETH port of the sub-gateway is calculated, the uplink port is notified, the WAN management module is notified to delete the forwarding network card interface of the uplink, and the forwarding network card interface corresponding to the uplink after the switch is created; the user-side ETH port is opened, and the DHCPC module is triggered to send a DHCP request message to the network side to obtain the interface address. It can be seen that fast switching under multiple uplink modes of FTTR is realized, and the detection time of the ETH multiplexing port reaches the millisecond level, thereby realizing that the FTTR gateway WIFI to ETH switching and PON to ETH switching service time recovery is completed within 10s, and it can prevent loops from occurring during the switching process.

[0037] Other features and advantages of the present disclosure will be described in the following description, and partly become apparent from the description, or be understood by implementing the present disclosure. The purpose and other advantages of the present disclosure can be realized and obtained by the structures indicated in the description and the drawings. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] In order to more clearly illustrate the embodiments of the present disclosure or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced one by one below. Obviously, the drawings described below are some embodiments of the present disclosure. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0039] Figure 1This is a flow chart of a FTTR multi-uplink fast switching method in an embodiment of the present application;

[0040] Figure 2 This is a schematic diagram of a multi-uplink detection and control system model in an embodiment of the present application;

[0041] Figure 3 This is a flowchart of a PON switching ETH uplink example in an embodiment of the present application;

[0042] Figure 4 This is a transition diagram of a multi-uplink detection state machine in an embodiment of the present application;

[0043] Figure 5 This is a schematic diagram of the FTTR networking scenario in the embodiment of this application;

[0044] Figure 6 This is a flowchart of a WIFI switching ETH uplink example in an embodiment of the present application;

[0045] Figure 7 This is a schematic diagram of an electronic device in an embodiment of the present application. DETAILED DESCRIPTION

[0046] In order to make the purpose, technical solution and advantages of the embodiments of the present disclosure clearer, the technical solution in the embodiments of the present disclosure will be clearly and completely described below in conjunction with the drawings in the embodiments of the present disclosure. Obviously, the described embodiments are part of the embodiments of the present disclosure, not all of the embodiments. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present disclosure.

[0047] It should be noted that the terms "first", "second" etc. in 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 data used in this way can be interchanged in appropriate circumstances, so that the embodiments of the present application described here. In the present application, the orientation or positional relationship indicated by the terms "upper", "lower", "left", "right", "front", "back", "top", "bottom", "inside", "outside", "middle", "vertical", "horizontal", "lateral", "longitudinal" etc. are based on the orientation or positional relationship shown in the accompanying drawings.

[0048] In view of the coexistence of multiple uplink modes of the FTTR master and sub-gateways, when the ETH port is a reused port, the ETH port detection time is too long, resulting in slow recovery of user service switching and loops during the ETH detection process and the ETH and WIFI switching process. This application proposes a FTTR multi-uplink fast switching method, electronic device and medium.

[0049] It should be understood that the FTTR involved in this application is fiber to the room, OMCI represents optical network unit management control interface, DHCPC is configuration server, and similar abbreviations in this application are technical terms that can be understood by those skilled in the art or through learning conventional technologies. Therefore, the abbreviations in this application will not be described in detail.

[0050] The present application embodiment provides a FTTR multi-uplink fast switching method, see Figure 1 ,include:

[0051] S101: Obtain the PON link status, ETH link status and WIFI link status identified by the LOS signal on the sub-gateway;

[0052] S102: When the sub-gateway receives a transmission failure of any one of the PON link status, the ETH link status and the WIFI link status, the current uplink of the FTTR sub-gateway is switched to a backup link according to the uplink priority;

[0053] S103: Calculate the uplink port according to the detection result generated by detecting the ETH port of the sub-gateway, notify the WAN management module to delete the forwarding network card interface of the uplink, and create a forwarding network card interface corresponding to the switched uplink;

[0054] S104: Open the user-side ETH port, trigger the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notify OMCI.

[0055] Specifically, obtaining the PON link status identified by the LOS signal on the sub-gateway includes:

[0056] When the PON link generates a LOS signal, the PON link is marked as DOWN and the link status is faulty;

[0057] When the PON link LOS signal disappears, the PON link is marked as UP, and the link status is normal.

[0058] In step S102, the current uplink of the FTTR sub-gateway is switched to the standby link according to the uplink priority. The uplink priority is configured on the sub-gateway.

[0059] Specifically, the LOS signal is used to identify the PON link status. When the PON link generates the LOS signal, it indicates that the PON link is DOWN. When the PON link LOS signal disappears, it indicates that the PON link status is normal.

[0060] In step S102, switching the current uplink of the FTTR sub-gateway to the standby link according to the uplink priority includes:

[0061] The FTTR sub-gateway switches the current uplink of the sub-gateway according to the priority order of the PON link as the first link, the ETH link as the second link, and the WIFI link as the third link.

[0062] Specifically, see Figure 2 , deploy a multi-uplink detection module on the sub-gateway, turn on the adaptive switch, and dynamically monitor the status of the PON link, ETH link or WIFI link between the main gateway and the sub-gateway. When a link between the FTTR sub-gateway and the FTTR main gateway fails, such as a link status sending failure of the PON link or ETH link, according to the uplink priority configured on the FTTR sub-gateway (such as PON link>ETH link>WIFI link, etc.), promptly switch the current uplink of the FTTR sub-gateway to a backup link such as ETH or WIFI with a low priority.

[0063] See also Figure 4 ,Multiple uplink detection and switching require the coordinated ,processing of multiple modules. In order to ensure the processing ,sequence, etc., the multiple uplink detection module sets up a state ,machine and anti-shake.

[0064] In step S103, the detection result generated by detecting the ETH port of the sub-gateway includes:

[0065] Anti-shake detection is performed on the status, wherein the received ETH port status change message is delayed;

[0066] When the delay time is greater than the anti-jitter time, it is determined that the ETH port state of the sub-gateway is stable.

[0067] Specifically, anti-shake mainly involves delayed processing of port status change messages received by the FTTR multi-uplink detection module to avoid frequent UP / DOWN and repeated link switching when the link status is unstable.

[0068] In step S103, the calculation of the uplink port according to the received detection result generated by detecting the ETH port of the sub-gateway includes:

[0069] According to the state machine transition change and anti-shake processing, the received timer message, link state change message and ETH uplink detection result are used to select and control the FTTR sub-gateway uplink;

[0070] It should be noted that the uplink channel link status of the FTTR sub-gateway is identified by defining the PON link status, ETH link status, and WIFI link status, where 1 indicates that the link status is UP and 0 indicates that the link status is DOWN; the multi-uplink detection module performs FTTR sub-gateway uplink selection and control based on the timer message, link status change message, and ETH uplink detection result received by the multi-uplink detection module according to the state machine transition change and anti-shake processing.

[0071] Define the ETH port roles, including uplink networking port, user port, and multiplexing port; detect whether the ETH port is a multiplexing port.

[0072] For the multiplexed port, this application uses a private protocol to detect the ETH port of the user's FTTR sub-gateway. The type of message sent by the sub-gateway is a detection message; the type of message sent by the main gateway after receiving the detection message is a response message.

[0073] Specifically, detecting that the ETH port is a multiplexed port includes:

[0074] In the initial state of the ETH port as a multiplexed port, when the sub-gateway is detected to switch from the PON link to the ETH link or from the WIFI link to the ETH link; the WAN management module first closes and then opens all ETH ports;

[0075] After the sub-gateway receives the UP message of the upstream networking ETH port, the ETH port detection is triggered. The FTTR sub-gateway receives the ETH port detection message response from the main gateway or the detection times out, and the ETH multiplexing port detection ends.

[0076] It should be noted that the ETH port role is defined and the ETH port of FTTR is divided into three categories: uplink networking port, user port, and multiplexing port.

[0077] Specifically, see Figure 2 , an ETH networking port detection module is set on the sub-gateway. When the ETH port role of the sub-gateway is configured as a reused port, this is the initial state of the ETH reused port, that is, when the ETH port detection module of the sub-gateway detects that the ETH port is a reused port;

[0078] When the multi-uplink detection module of the FTTR sub-gateway detects that the sub-gateway switches the PON link, ETH link or the WIFI link to the ETH link, this is the transition state before the ETH multiplexing port detection when the FTTR sub-gateway switches the uplink; the WAN management module first closes and then opens all ETH ports. After the sub-gateway receives the UP message of the uplink networking ETH port, the ETH multiplexing port starts the detection state, triggering the ETH port detection. The FTTR sub-gateway receives the ETH port detection message response from the main gateway or the detection times out, the ETH multiplexing port detection ends, and the ETH multiplexing port detection is completed.

[0079] Further, the method further includes: if the ETH port in the detection result is a user port, then notifying the sub-gateway loop detection module to run a loop detection protocol on the user port;

[0080] If the ETH port in the detection result is an uplink networking port, the loop detection module of the sub-gateway is notified to stop running the loop detection protocol on the uplink networking port;

[0081] During the detection period, the ETH multiplexing port does not run the loop detection protocol.

[0082] In some implementations, the detection result is sent to a multiple uplink detection module, and the multiple uplink detection module starts a state machine to calculate the port status and selects an uplink port according to the port status calculation result.

[0083] Notify the WAN management module to delete the forwarding network card port of the previous uplink and create a forwarding network card port corresponding to the uplink after the switch;

[0084] The WAN management module closes the opened user-side ETH port, triggering the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notifies OMCI and device management to turn on the light.

[0085] The following is a detailed description of the detection steps for the sub-gateway.

[0086] The specific detection steps of the sub-gateway are as follows:

[0087] (1) The sub-gateway detection port calls the driver interface to set a blocked port, and does not allow messages to pass through; only ETH port detection messages and ETH detection response messages are allowed to pass;

[0088] (2) The sub-gateway sends a custom private protocol detection message to the main gateway;

[0089] (3) After receiving the probe request message, the primary gateway responds to the probe request message;

[0090] (4) After the sub-gateway receives the detection response message within the specified time, it determines that the ETH port is an uplink networking port. If no response message is received within the specified time, the ETH port is a user port.

[0091] (5) After the detection is completed, the ETH detection module of the sub-gateway calls the driver interface to release the blocked port, completing the entire detection process. If the detection result shows that the ETH port is a user port, the loop detection module is notified to run the loop detection protocol on the port; if the detection result shows that the ETH port is an uplink networking port, the loop detection module is notified to stop running the loop detection protocol on the port. During the detection period, the ETH multiplexing port does not run the loop detection protocol;

[0092] (6) The detection result is notified to the multi-uplink detection module, and the multi-uplink detection module starts the state machine to calculate and select the uplink port; and the WAN management module is notified to delete the forwarding network card interface of the previous uplink and create a forwarding network card interface corresponding to the uplink after the switch. The WAN management module closes and then opens the user-side ETH port, triggering the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notifies OMCI and device management to turn on the light.

[0093] The present application uses LOS signals to identify the PON link status, accurately describes the PON link status of the FTTR sub-gateway, and selects the uplink by deploying a multi-uplink detection module. In particular, when the port role is an ETH multiplexing port, a private protocol is defined for the detection of the ETH port, which can complete the ETH port detection in a short time (within 1 second), thereby realizing fast switching of different uplink modes from PON, ETH or WIFI to ETH, and linking the ETH port detection result with the loop detection module to avoid loops.

[0094] The following is a detailed description of the FTTR sub-gateway PON to ETH uplink switching implementation method of the present invention in conjunction with the accompanying drawings and specific implementation methods:

[0095] See also Figure 5 , the FTTR networking scenario diagram applicable to the present application, for example, the adaptive switch of the FTTR sub-gateway 1 is enabled, ETH port 1 is the configured uplink networking port, the multiplexing enable switch of ETH port 1 is enabled, the uplink priority of the FTTR sub-gateway is configured as PON>ETH>WIFI, the FTTR sub-gateway is connected to the FTTR main gateway through optical fiber and network cable, and the downstream PON port, ETH port, and WIFI port of the FTTR main gateway run the loop detection protocol.

[0096] During operation, the FTTR main gateway detects a loop between PON and ETH, and shuts down the ETH port of the FTTR main gateway;

[0097] See also Figure 3 , which is a flowchart of an example of multi-uplink detection and control of PON switching ETH uplink. The multi-uplink detection module of the sub-gateway monitors the LOS signal of the PON link, and the PON link is abnormal. The multi-uplink detection module monitors the PON link DOWN message, triggering the sub-gateway uplink switching; the loop detection module of the FTTR main gateway monitors the abnormal link status corresponding to the downlink PON port, starts the loop detection module for loop detection, and the loop detection module detects that the loop disappears, and opens the main gateway ETH port connected to the ETH1 port;

[0098] See also Figure 4 , is the state machine transition diagram of the multi-uplink detection module. In order to describe in detail the three uplink states of PON, ETH, and WIFI and the switching between different uplink modes, the three uplink states of the sub-gateway are identified by the PON link state, ETH link state, and WIFI port state. For each link state, 1 indicates that the link state is normal, 0 indicates that the link state is DOWN, and 2 is used to identify the initialization state of the WIFI module. The link states of the sub-gateway in different uplink modes include 7 states: PON uplink transition state, PON uplink stable state; ETH uplink transition state, ETH uplink stable state; WIFI initial state, WIFI uplink transition state, WIFI uplink stable state; the transition between different states is affected by the link state change message, port anti-jitter and ETH port detection results, see for details. Figure 4 When the multi-uplink detection module monitors the link status of PON, ETH, WIFI, etc., sends changes and timer messages, ETH networking port detection result messages, etc., it triggers the multi-uplink detection module state machine to transition to a stable state.

[0099] Specifically, see Figure 4 , PON link status ETH link status WIFI port status to identify the uplink status of the sub-gateway, 1 means the link status is normal, 0 means the link status is DOWN, 2 is used to identify the initialization status of the WIFI module, for example (010) means the current PON link status is DOWN, WIFI link status is DOWN, ETH link status is UP, and the uplink networking mode is ETH uplink.

[0100] The relationship between different state machines is as follows:

[0101] The transition between states is affected by link state change messages, port anti-jitter and ETH port detection results. For details, see Figure 4The multi-uplink detection module of the sub-gateway monitors the link status changes and timer messages of PON, ETH, WIFI, etc., ETH networking port detection result messages, etc., triggering the sub-gateway multi-uplink detection module state machine to transition to a stable state. For example, the PON to ETH switching mentioned in this patent, after receiving the PON link DOWN message, the state machine transitions from the PON upstream stable state (100) to the ETH transition state (000), and then starts the detection transition to the ETH stable state (010); WIFI switches to ETH, after receiving the ETH networking port UP message, it transitions from the WIFI stable state (001) to the ETH transition state (000), and then starts the ETH multiplexing port detection. After the ETH port detection is successful, it transitions to the ETH stable state (010); from PON to WIFI, after receiving the PON link status DOWN message, after starting the ETH port detection and failing, it switches to the WIFI initialization state (002), and after the initialization is completed, it transitions to the WIFI transition state (000), and then transitions to the WIFI stable state (001).

[0102] See also Figure 3 , is a flowchart of the PON switching ETH uplink instance, the specific steps are as follows:

[0103] Step S1: configure the multi-uplink adaptive switch to enable, configure ETH port 1 as the uplink networking port, and enable the ETH port multiplexing function; the loop detection module of the main gateway detects the loop, closes the ETH port of the main gateway according to the configured uplink priority, and breaks the loop;

[0104] The configured uplink priority refers to the uplink priority of the corresponding FTTR sub-gateway, that is, the priority of the PON link, ETH link, and WIFI link. The links correspond to the ports of the FTTR main gateway one by one. The priority is saved in the device through the node, and supports the configuration of the default priority from high to low (PON>uplink ETH port>WIFI port).

[0105] Step S2: The PON link is abnormal (cause), a LOS signal is generated (effect), and the multi-uplink detection module monitors the PON link DOWN message; the LOS signal is detected by the detection module, that is, the LOS signal is detected and marked as a DOWM message.

[0106] Step S3: The link corresponding to the downlink PON port of the main gateway is abnormal, triggering the main gateway device to start loop detection. The loop is detected and the loop disappears. The ETH port of the main gateway is opened, and the sub-gateway monitors the ETH1 networking port UP message;

[0107] Among them, the loop detection runs periodically. At the same time, when the PON link status changes, the loop detection will be notified to restart the detection. When the PON link and ETH link are online at the same time, the ETH port will be closed according to the configuration with low ETH priority to break the loop; when the PON link is abnormal, the PON port channel is blocked, the loop detection module detects that the loop detection has disappeared, and reopens the ETH port.

[0108] Step S4: Determine whether the port receiving the port UP message is an uplink networking port.

[0109] Step S5: If the port is not an uplink networking port and is a user port, the port starts a loop detection protocol;

[0110] The loop detection protocol is specifically as follows: when the ETH port is a user port, the loop detection protocol is started;

[0111] If the port is an uplink networking port, it is necessary to detect whether it is connected to the main gateway as a networking port or connected to the user PC as a user port;

[0112] According to different user configurations, the ETH port has three roles (user port, multiplexed port, and uplink networking port). Among them, the user port can only be connected to the user's PC;

[0113] Multiplexing port: only available when the ETH port multiplexing switch is enabled;

[0114] Uplink networking port: can only be used as a networking port and cannot be connected to a user PC.

[0115] Step S6: Then determine whether the ETH port multiplexing switch is enabled. If enabled, trigger ETH port 1 to start ETH port detection.

[0116] Step S7: Before starting the ETH port detection, the ETH detection module first calls the driver interface to set the STP state of ETH port 1 to block; then the ETH detection module calls the driver's dedicated packet sending interface to send the detection message of the ETH1 port to the main gateway for detection, and starts the packet receiving timer and message counting. After the main gateway receives the port detection message sent by the sub-gateway port 1, it parses the message content and immediately responds to the message.

[0117] Step S8: If the sub-gateway receives a response message to the detection message of the ETH1 port within the specified time, the detection is successful. The port is an uplink networking port. If the sub-gateway does not receive a response message to the detection message within the specified time, the detection is re-triggered.

[0118] Step S9: Determine whether the detection of the ETH1 port is successful, and notify the detection result to the multi-uplink detection module; if the detection fails, go to step S5, and the corresponding ETH1 port starts the loop detection protocol.

[0119] Step 10: Notify the multi-uplink detection module of the successful detection result of the ETH1 port for relevant processing;

[0120] The relevant processing includes: the multi-uplink module selects the route, the ETH port is detected successfully, and the port is the uplink networking port, then the multi-uplink module sets the uplink node to the ETH port, closes the WIFI port, creates the corresponding network card, and re-acquires the IP address and other operations;

[0121] At the same time, set the STP status of the ETH port to forward and open the port.

[0122] Step S11: The multi-uplink detection module selects the uplink routing by running the state machine according to the uplink status, timer message, configured uplink priority, etc., and finally selects ETH port 1 as the uplink networking port, writes ETH port 1 to the uplink mode node, and notifies the WAN management module, device management, OMCI and other modules to complete the interface creation, obtain the IP address, turn on the light and other operations.

[0123] The following is a detailed description of the steps for switching from Wi-Fi to ETH uplink.

[0124] See also Figure 6 , step S12: configure the multi-uplink adaptive switch to enable, configure ETH port 1 as the uplink networking port, and enable the ETH port multiplexing function; the PON port and the uplink ETH port are not connected by default, and the link status is DOWN; the multi-uplink selection module selects the WIFI link as the uplink;

[0125] The configured uplink priority refers to the uplink priority of the corresponding FTTR sub-gateway, that is, the priority of the PON link, ETH link, and WIFI link. The links correspond to the ports of the FTTR main gateway one by one. The priority is saved in the device through the node, and supports the configuration of the default priority from high to low (PON>uplink ETH port>WIFI port).

[0126] Step S13: ETH port 1 is connected to an Internet cable to form a network with the main gateway device of the FTTR, the ETH link status changes to UP, and the multi-uplink detection module monitors the ETH link UP message;

[0127] Step S14: The sub-gateway device receives the UP message of ETH port 1;

[0128] Step S15: Determine whether the port of the received port UP message is an uplink networking port.

[0129] Step S16: If the port is not an uplink networking port and is a user port, the port starts a loop detection protocol;

[0130] The loop detection protocol is specifically as follows: when the ETH port is a user port, the loop detection protocol is started;

[0131] If the port is an uplink networking port, it is necessary to detect whether it is connected to the main gateway as a networking port or connected to the user PC as a user port;

[0132] According to different user configurations, the ETH port has three roles (user port, multiplexed port, and uplink networking port). Among them, the user port can only be connected to the user's PC;

[0133] Multiplexing port: only available when the ETH port multiplexing switch is enabled;

[0134] Uplink networking port: can only be used as a networking port and cannot be connected to a user PC.

[0135] Step S17: Then determine whether the ETH port multiplexing switch is enabled. If enabled, trigger ETH port 1 to start ETH port detection.

[0136] Step S18: Before starting the ETH port detection, the ETH detection module first calls the driver interface to set the STP state of ETH port 1 to block; then the ETH detection module calls the driver's dedicated packet sending interface to send the detection message of ETH1 port to the main gateway for detection, and starts the packet receiving timer and message counting. After the main gateway receives the port detection message sent by the sub-gateway port 1, it parses the message content and immediately responds to the message.

[0137] Step S19: The sub-gateway receives a response message to the detection message of the ETH1 port within the specified time, and the detection is successful. The port is an uplink networking port. If the sub-gateway does not receive a response message to the detection message within the specified time, the detection is re-triggered.

[0138] Step S20: Determine whether the detection of the ETH1 port is successful, and notify the detection result to the multi-uplink detection module; if the detection fails, go to step S16, and the corresponding ETH port starts the loop detection protocol.

[0139] Step 21: Notify the multi-uplink detection module of the successful detection result of the ETH1 port to close the WIFI port and select the ETH1 port as the uplink networking port;

[0140] Step 22: The multi-uplink module selects the ETH1 port as the uplink port and writes it into the node, notifying the WAN connection management module and other modules.

[0141] Based on the same inventive concept, the present disclosure also provides an electronic device 161, see Figure 6 , including a processor 164, a communication interface 165, a memory 162 and a communication bus, wherein the processor 164, the communication interface 165 and the memory 162 communicate with each other through the communication bus;

[0142] A memory 162 storing a computer program 163;

[0143] When the processor 164 executes the program stored in the memory 162, the FTTR multi-uplink fast switching method is implemented.

[0144] The above communication bus may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The communication bus may be divided into an address bus, a data bus, a control bus, etc.

[0145] The communication interface 165 is used for communication between the electronic device 161 and other devices.

[0146] The memory 162 may include a random access memory 162 (RAM), or may include a non-volatile memory 162 (non-volatile memory), such as at least one disk memory 162. Optionally, the memory 162 may also be at least one storage device located away from the processor 164.

[0147] The above-mentioned processor 164 can be a general-purpose processor 164, including a central processing unit 164 (CPU), a network processor 164 (NP), etc.; it can also be a digital signal processor 164 (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components.

[0148] Based on the same inventive concept, the embodiment of the present disclosure further provides a computer-readable storage medium storing a computer program 163 , which implements a FTTR multi-uplink fast switching method when executed by a processor 164 .

[0149] The computer-readable storage medium may be included in the device / apparatus described in the above embodiment; or it may exist independently without being assembled into the device / apparatus. The above computer-readable storage medium carries one or more programs. When the above one or more programs are executed, the FTTR multi-uplink fast switching method according to the embodiment of the present disclosure is implemented.

[0150] The above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. A FTTR multi-uplink fast switching method, applied to a sub-gateway, characterized in that: include: Get the PON link status, ETH link status and WIFI link status marked by LOS signal on the sub-gateway; When the sub-gateway receives a failure in sending any of the PON link status, ETH link status and WIFI link status, the current uplink of the FTTR sub-gateway is switched to the backup link according to the uplink priority; According to the detection result generated by detecting the ETH port of the sub-gateway, the uplink port is calculated, the WAN management module is notified to delete the forwarding network card interface of the uplink, and the forwarding network card interface corresponding to the switched uplink is created; Open the user-side ETH port, trigger the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notify OMCI.

2. The method according to claim 1, characterized in that The obtaining of the PON link status identified by the LOS signal on the sub-gateway includes: When the PON link generates a LOS signal, the PON link is marked as DOWN and the link status is faulty; When the PON link LOS signal disappears, the PON link is marked as UP, and the link status is normal.

3. The method according to claim 1, characterized in that The detection result generated by detecting the ETH port of the sub-gateway includes: Anti-shake detection is performed on the ETH port status, wherein the received ETH port status change message is delayed; When the delay time is greater than the anti-jitter time, it is determined that the ETH port state of the sub-gateway is stable.

4. The method according to claim 1, characterized in that: The calculating the uplink port according to the received detection result generated by detecting the ETH port of the sub-gateway includes: According to the state machine transition change and anti-shake processing, the received timer message, link state change message and ETH port detection result, etc., the FTTR sub-gateway uplink is selected and controlled; Define the ETH port roles, including uplink networking port, user port, and multiplexing port; detect whether the ETH port is a multiplexing port.

5. The method according to claim 4, characterized in that The detecting that the ETH port is a multiplexed port includes: In the initial state of the ETH port as a multiplexed port, when the sub-gateway is detected to switch from the PON link to the ETH link or from the WIFI link to the ETH link; the WAN management module first closes and then opens all ETH ports; After the sub-gateway receives the UP message of the upstream networking ETH port, the ETH port detection is triggered. The FTTR sub-gateway receives the ETH port detection message response from the main gateway or the detection times out, and the ETH multiplexing port detection ends.

6. The method according to claim 5, characterized in that The method further comprises: If the ETH port in the detection result is a user port, the loop detection module is notified to run the loop detection protocol on the user port; If the ETH port in the detection result is an uplink networking port, the loop detection module is notified to stop running the loop detection protocol on the uplink networking port; During the detection period, the ETH multiplexing port does not run the loop detection protocol.

7. The method according to claim 6, characterized in that The method further comprises: The detection result is sent to the multi-uplink detection module, and the multi-uplink detection module starts a state machine to calculate the port status and selects an uplink port according to the port status calculation result.

8. The method according to claim 7, characterized in that The method further comprises: Notify the WAN management module to delete the forwarding network card port of the previous uplink and create a forwarding network card port corresponding to the uplink after the switch; The WAN management module closes the opened user-side ETH port, triggering the DHCPC module to send a DHCP request message to the network side to obtain the interface address, and notifies OMCI and device management to turn on the light.

9. An electronic device, characterized in that: include: A processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; a memory storing a computer program; The processor, when executing the program stored in the memory, implements the FTTR multi-uplink fast switching method described in any one of claims 1 to 8.

10. A computer-readable storage medium, characterized in that: A computer program is stored, and when the computer program is executed by a processor, the FTTR multi-uplink fast switching method according to any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • Systems and methods for traffic load balancing on multiple wan backhauls and multiple distinct LAN networks

    CA2858030A1

  • Optical network protecting method and optical fiber line switching equipment

    CN102684780A

  • Method and device for supporting automatic identification in process of accessing plurality of upstream user equipment into network

    CN102957561A

  • Ring network fault switching method and ring nodes

    CN106789521A

  • Heterogeneous multimode gateway device, and transmission method and application thereof

    CN107018070A