CN109286863B - Method for establishing link, ONU and computer readable storage medium - Google Patents

Method for establishing link, ONU and computer readable storage medium Download PDF

Info

Publication number
CN109286863B
CN109286863B CN201710601843.0A CN201710601843A CN109286863B CN 109286863 B CN109286863 B CN 109286863B CN 201710601843 A CN201710601843 A CN 201710601843A CN 109286863 B CN109286863 B CN 109286863B
Authority
CN
China
Prior art keywords
data
olt
link
sent
onu
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710601843.0A
Other languages
Chinese (zh)
Other versions
CN109286863A (en
Inventor
周仁龙
臧高勇
谢小龙
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Sanechips Technology Co Ltd
Original Assignee
Sanechips Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sanechips Technology Co Ltd filed Critical Sanechips Technology Co Ltd
Priority to CN201710601843.0A priority Critical patent/CN109286863B/en
Publication of CN109286863A publication Critical patent/CN109286863A/en
Application granted granted Critical
Publication of CN109286863B publication Critical patent/CN109286863B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q11/00Selecting arrangements for multiplex systems
    • H04Q11/0001Selecting arrangements for multiplex systems using optical switching
    • H04Q11/0062Network aspects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B10/00Transmission systems employing electromagnetic waves other than radio-waves, e.g. infrared, visible or ultraviolet light, or employing corpuscular radiation, e.g. quantum communication
    • H04B10/07Arrangements for monitoring or testing transmission systems; Arrangements for fault measurement of transmission systems
    • H04B10/075Arrangements for monitoring or testing transmission systems; Arrangements for fault measurement of transmission systems using an in-service signal
    • H04B10/077Arrangements for monitoring or testing transmission systems; Arrangements for fault measurement of transmission systems using an in-service signal using a supervisory or additional signal
    • H04B10/0773Network aspects, e.g. central monitoring of transmission parameters
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q11/00Selecting arrangements for multiplex systems
    • H04Q11/0001Selecting arrangements for multiplex systems using optical switching
    • H04Q11/0062Network aspects
    • H04Q2011/0079Operation or maintenance aspects
    • H04Q2011/0081Fault tolerance; Redundancy; Recovery; Reconfigurability
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04QSELECTING
    • H04Q11/00Selecting arrangements for multiplex systems
    • H04Q11/0001Selecting arrangements for multiplex systems using optical switching
    • H04Q11/0062Network aspects
    • H04Q2011/0079Operation or maintenance aspects
    • H04Q2011/0083Testing; Monitoring

Abstract

The embodiment of the invention discloses a method for establishing a link, which is mainly applied to an ONU and comprises the following steps: acquiring state information of a link between the OLT and the OLT in real time; when the state of the link represented by the state information of the link is a discovery state, disabling a service data sending function and deleting data to be sent of an MAC layer; the discovery state refers to a state when the ONU and the OLT are not connected; and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT. The embodiment of the invention also discloses an ONU and a computer readable storage medium.

Description

Method for establishing link, ONU and computer readable storage medium
Technical Field
The present invention relates to the field of Ethernet Passive Optical Networks (EPONs), and in particular, to a method for establishing a link, an Optical Network Unit (ONU), and a computer-readable storage medium.
Background
The EPON is a Passive Optical Network (PON) based on ethernet, and mainly includes an Optical Line Terminal (OLT), an ONU, and an Optical Distribution Network (ODN). The ONU cooperates with the OLT to provide various broadband services to connected user equipment, such as Internet Surfing (Internet Surfing), Voice over Internet Phone (VoIP), High-Definition television (HDTV), and Video Conference (Video Conference).
Each Time an ONU starts, it implements link connection with the OLT by performing a complete discovery and registration process once, and implements transmission of uplink data in a Time Division Multiplexing (TDM) manner. The OLT judges whether a link with the ONU is available through a keep-alive mechanism, that is, periodically judges whether any valid operation, administration, and Maintenance Protocol data unit (OAM PDU) is received, and if not, the OLT considers that the current link has failed, and then triggers the ONU to re-execute the above discovery and registration process.
However, when the ONU is already in the link connection state in the EPON system and the uplink is continuously transmitting traffic data, if the link is temporarily disconnected for some reason, for example, the optical fiber is hot-plugged, and the link is determined to be abnormal under the action of the OLT keep-alive mechanism, the OLT triggers the ONU to perform a complete discovery and registration process again. However, in the foregoing scenario, even if the OLT circularly triggers the ONU to perform the start-up configuration process under the keep-alive mechanism, the ONU still cannot establish a connection with the OLT.
Disclosure of Invention
To solve the above technical problem, embodiments of the present invention desirably provide a method for establishing a link, an ONU, and a computer-readable storage medium, which aim to enable re-establishment of a link when a link of an ONU that is continuously transmitting service data in an uplink direction is suddenly interrupted, thereby improving robustness of the ONU link.
The technical scheme of the invention is realized as follows:
in a first aspect, an embodiment of the present invention provides a method for establishing a link, where the method is applied to an optical network unit ONU, and the method includes: acquiring state information of a link between the OLT and an optical line terminal in real time; when the link state represented by the link state information is a discovery state, disabling a service data transmission function and deleting data to be transmitted of a Media Access Control (MAC) layer; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection; and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
In a second aspect, an embodiment of the present invention provides an apparatus for establishing a link, where the apparatus includes: the device comprises a multipoint control protocol (MPCP) message analysis module, a control module, a negotiation message sending module, a service data sending module and a Media Access Control (MAC) layer data cache module to be sent; the MPCP message analysis module is configured to acquire state information of a link between an optical network unit ONU to which the MPCP message analysis module belongs and an optical line terminal OLT in real time; the control module is configured to disable the sending function of the service data sending module and delete the data to be sent in the MAC layer data-to-be-sent cache module when the state of the link represented by the state information of the link is a discovery state; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection; the negotiation message sending module is configured to send a negotiation message for establishing connection between the ONU and the OLT to the OLT.
In a third aspect, an embodiment of the present invention provides an optical network unit ONU, where the ONU includes: memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program: acquiring state information of a link between the OLT and an optical line terminal in real time; when the link state represented by the link state information is a discovery state, disabling a service data transmission function and deleting data to be transmitted of a Media Access Control (MAC) layer; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection; and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, where one or more programs are stored, and the one or more programs are executable by one or more processors to implement the method steps for establishing a link according to one or more of the above-mentioned technical solutions.
The embodiment of the invention provides a link establishing method, an ONU and a computer readable storage medium, wherein the method mainly monitors the state of a link between the ONU and an OLT in real time, disables the sending function of service data when the state of the link between the ONU and the OLT is in a state of not establishing connection, deletes data to be sent of an MAC layer, and sends a negotiation message for establishing connection with the OLT to the OLT after finishing deleting the data to be sent of the MAC layer. According to the method, the negotiation message can be successfully sent out mainly by eliminating the data blockage of the MAC layer, so that the link reconstruction between the ONU and the OLT is realized, and the robustness of the ONU link is improved.
Drawings
Fig. 1 is a schematic diagram of a method for establishing a link according to an embodiment of the present invention;
fig. 2 is a schematic diagram of another method for establishing a link according to an embodiment of the present invention;
fig. 3(a) is a schematic diagram of a frame structure of a GATE frame according to an embodiment of the present invention;
fig. 3(b) is an information schematic diagram of a numberfgrants/Flags field in a GATE frame according to an embodiment of the present invention;
fig. 4 is a schematic diagram of another method for establishing a link according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an apparatus for establishing a link according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of an ONU according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of another ONU according to an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
Example one
As shown in fig. 1, which illustrates a method for establishing a link according to an embodiment of the present invention, it can be seen from the figure that an abrupt disconnection of the link between the ONU2 and the OLT causes the service data packet 2 that is being continuously transmitted upstream to stay in a Media Access Control (MAC) layer of the ONU 2. At this time, under the action of the OLT keep-alive mechanism, ONU2 re-executes a complete discovery and registration process, and in executing this process, ONU2 acquires the management data transmission window authorized by the OLT, and transmits a negotiation packet (i.e., packet 0 shown in fig. 1) for establishing a connection with the OLT using this authorization window. However, since the basic unit of data transmission in the EPON system is a complete ethernet packet, and the management data transmission window authorized by the OLT is relatively small, which can only satisfy the transmission of the negotiation packet, the service data packet 2 retained in the MAC layer cannot be always transmitted because there is no long enough authorization window, so that the MAC layer is blocked by data congestion, as shown in fig. 1, the shorter negotiation packet in the MAC layer of the ONU2 is blocked behind the retained service data (i.e., long packet data) packet 2, so that the ONU2 cannot always establish a connection with the OLT by transmitting idle data to the OLT. Based on this, several other embodiments will be provided to provide another method for establishing a link, so as to solve the above problem that the ONU link cannot establish a connection with the OLT after being interrupted, thereby improving the robustness of the link between the ONU and the OLT.
Example two
As shown in fig. 2, the figure shows a method for establishing a link according to an embodiment of the present invention, where the method is mainly applied to an ONU, and as can be seen from the figure, the method may include:
s110, acquiring state information of a link between the OLT and the terminal in real time;
s120, when the link state represented by the link state information is a discovery state, disabling a service data sending function and deleting data to be sent of an MAC layer; the discovery state refers to a state when the ONU and the OLT are not connected;
it can be understood that, when the ONU is initially started or restarted, a complete registration and discovery process must be performed, in which the state of the link between the ONU and the OLT is referred to as a discovery state, and the ONU and the OLT in the discovery state implement link connection through an interactive negotiation message. In order to avoid that long packet data (i.e. service data to be transmitted) retained in the MAC layer blocks transmission of a negotiation packet, when the link between the ONU and the OLT is in a discovery state, on one hand, the transmission function of the service data of the ONU needs to be disabled, so that no new service data is retained in the MAC layer, and on the other hand, the data to be transmitted on the MAC layer needs to be deleted, so that short packet data to be transmitted (i.e. the negotiation packet) generated when the ONU performs registration and discovery processes again can be transmitted in time.
And S130, after the deletion of the data to be sent is completed, sending a negotiation message for establishing connection with the OLT to the OLT.
It can be understood that after the deletion of the data to be sent is completed, that is, after the data to be sent of the MAC layer is emptied, at this time, the MAC layer does not have service data to be sent any more, so that the ONU can successfully send the negotiation message by using the management data sending window authorized by the OLT.
For example, in step S120, the deleting the data to be sent in the MAC layer may include: detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold value or not; and when the data volume of the data to be sent in the MAC layer exceeds the preset threshold value, deleting the data to be sent in the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the MAC layer exceeds the preset threshold value.
Here, the preset threshold value belongs to an empirical value. Because the rates of the uplink and downlink transmission lines of the EPON system both reach giga-level and the basic unit of data transmission is a complete ethernet message, when the link between the ONU and the OLT is in a discovery state or a connection establishment state, the data volume of data to be transmitted in the MAC layer of the ONU is almost 0. Therefore, whether the MAC layer has a data congestion phenomenon can be determined by detecting whether the amount of data to be transmitted in the MAC layer exceeds a preset threshold (e.g., the preset threshold is 0). In addition, in order to ensure that the data congestion of the MAC layer is completely eliminated, after the data to be sent of the MAC layer is deleted, a step of detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold needs to be executed again.
Specifically, after the step of detecting whether the data amount of the data to be sent in the MAC layer exceeds a preset threshold, the method may further include: when the data volume of the data to be sent in the MAC layer does not exceed the preset threshold value, detecting whether connection is established with the OLT or not; and when the ONU establishes connection with the OLT, enabling the service data sending function.
It can be understood that, in order not to affect the sending of the service data after the ONU establishes the connection, here, when the ONU establishes the connection with the OLT, the sending function of the service data needs to be recovered.
For example, for step S110, the acquiring, in real time, the state information of the link with the OLT may include: receiving a Multi-Point Control Protocol (MPCP) message issued by an OLT in real time; and reading the state information of the link contained in the MPCP message.
In practical applications, in order to facilitate interaction between the ONU and the OLT and to implement communication between the ONU and the OLT, the EPON system mainly defines 5 MPCP control frames, that is: authorization (GATE) frame, REPORT (REPORT) frame, registration request (REGISTER _ RQ) frame, registration (REGISTER) frame, registration acknowledgement (REGISTER _ ACK) frame. Since the GATE frame includes information for characterizing the state of the link between the ONU and the OLT, the state information of the link can be acquired by analyzing the frame structure of the GATE frame. Specifically, the frame structure of the GATE frame is as shown in fig. 3(a), where information of the Number of bits/Flags field in the GATE frame is as shown in fig. 3(b), and as can be seen from fig. 3(b), a value of a 3 rd bit in the Number of bits/Flags field is used to represent a state of a link between the ONU and the OLT, and when the value of the 3 rd bit is 1, the state of the link is a discovery state; when the value of the 3 rd bit is 0, the state of the link is a connection establishment state.
Exemplarily, after step S110, the method shown in fig. 1 may further include: and when the state of the link represented by the state information of the link is not the discovery state, returning to execute the step S110.
It is understood that, in order to continuously monitor the state of the link, when the state of the link, which is characterized by the state information of the link, is not the discovery state, it is required to return to perform step S110, that is, to obtain the state information of the link with the OLT in real time.
The embodiment of the invention provides a method for establishing a link, which is mainly applied to an ONU and has the core thought that: when the link between the ONU and the OLT is in a discovery state, the transmission function of the service data is disabled, and the data to be transmitted of the MAC layer is deleted, so that the MAC layer can successfully transmit a negotiation message for establishing connection with the OLT after the data blocking phenomenon is eliminated, the link between the ONU and the OLT is connected, and the robustness of the ONU link is improved.
EXAMPLE III
For facilitating understanding of the above technical solution, as shown in fig. 4, the figure shows a detailed implementation process of implementing the above technical solution by an ONU, and as can be seen from the figure, the implementation process may specifically include the following steps:
s410, receiving an MPCP message issued by an OLT in real time;
s420, reading the link state information contained in the MPCP message; the link refers to a link between the ONU and the OLT;
s430, judging whether the state of the link represented by the state information of the link is a discovery state; if yes, go to step S440; otherwise, returning to execute the step S410;
here, the discovery state refers to a state when the ONU and the OLT do not establish a connection.
S440, disabling the sending function of the service data, and executing the step S450;
s450, detecting whether the data volume of data to be sent in the MAC layer exceeds a preset threshold value; if yes, go to step S460; otherwise, go to step S470;
s460, deleting the data to be sent of the MAC layer, and returning to execute the step S450;
s470, sending a negotiation message for establishing connection with the OLT to the OLT, and executing the step S480;
s480, detecting whether connection with the OLT is established or not; if yes, go to step S490; otherwise, returning to execute the step S480;
here, it can be understood that, when the ONU does not establish a connection with the OLT, returning to the step of detecting whether a connection is established with the OLT is substantially to wait for the ONU to establish a connection with the OLT.
And S490, enabling the service data sending function.
As can be seen from fig. 4, when the link between the ONU and the OLT is in the discovery state, the ONU determines whether data congestion occurs in the MAC layer by detecting whether the data amount of data to be transmitted in the MAC layer of the ONU exceeds a preset threshold, and eliminates the data congestion in the MAC layer by deleting the data to be transmitted in the MAC layer and disabling the transmission function of the service data, and transmits a negotiation packet for establishing connection with the OLT after the congestion phenomenon is eliminated, thereby implementing the connection between the ONU and the OLT.
Example four
Based on the same technical concept as described above, as shown in fig. 5, the figure illustrates an apparatus 50 for establishing a link according to an embodiment of the present invention, and as can be seen from the figure, the apparatus 50 mainly includes: an MPCP message parsing module 510, a control module 520, a negotiation message sending module 530, a service data sending module 540, and an MAC layer to-be-sent data caching module 550; wherein the content of the first and second substances,
the MPCP message parsing module 510 may be configured to obtain, in real time, state information of a link between the ONU to which the MPCP message parsing module belongs and the OLT;
the control module 520 may be configured to disable the sending function of the service data sending module 540 and delete the data to be sent of the MAC layer data to be sent buffer module 550 when the state of the link represented by the state information of the link is a discovery state; the discovery state refers to a state when the ONU and the OLT are not connected;
the negotiation message sending module 530 may be configured to send a negotiation message for the ONU to establish a connection with the OLT.
In the foregoing solution, the control module 520 may be specifically configured to: detecting whether the data amount of the data to be sent in the data cache module 550 to be sent of the MAC layer exceeds a preset threshold; when the data amount of the data to be sent in the data-to-be-sent buffer module 550 of the MAC layer exceeds the preset threshold, deleting the data to be sent in the data-to-be-sent buffer module 550 of the MAC layer, and returning to the step of detecting whether the data amount of the data to be sent in the data-to-be-sent buffer module 550 of the MAC layer exceeds the preset threshold.
In the foregoing solution, the control module 520 may be further specifically configured to: when the data amount of the data to be sent in the data cache module 550 to be sent in the MAC layer does not exceed the preset threshold, detecting whether a connection with the OLT is established; when the ONU establishes a connection with the OLT, the transmission function of the service data transmission module 540 is enabled.
In the above scheme, the MPCP message parsing module 510 may be specifically configured to: receiving an MPCP message issued by an OLT in real time; and reading the state information of the link contained in the MPCP message.
EXAMPLE five
For facilitating understanding of the foregoing technical solutions, as shown in fig. 6, this figure shows a process of establishing a link by an ONU according to an embodiment of the present invention when the ONU includes the foregoing apparatus 50, where the process may include the following steps:
s710, the MPCP message parsing module 510 receives an MPCP message issued by the OLT in real time, and reads the state information of the link included in the MPCP message;
s720, the MPCP message parsing module 510 feeds back the read link state information included in the MPCP message to the control module 520;
s730, the control module 520 determines whether the state of the link is a discovery state according to the state of the link represented by the state information of the link; if yes, go to step S740; otherwise, returning to execute step S710;
s740, the control module 520 disables the sending function of the service data sending module 540, and performs step S750;
s750, the control module 520 detects whether the data amount of the data to be sent in the data to be sent buffer module 550 of the MAC layer exceeds a preset threshold; if yes, go to step S760; otherwise, go to step S770;
s760, the control module 520 deletes the to-be-sent data in the MAC layer to-be-sent data cache module 550, and returns to perform step S750;
s770, the negotiation message sending module 530 sends a negotiation message for establishing connection with the OLT to the OLT, and executes step S780;
s780, the control module 520 detects whether connection with the OLT is established; if yes, go to step S790; otherwise, returning to execute step S780;
s790, the control module 520 enables the sending function of the service data sending module 540.
Here, it should be noted that, in practical applications, the negotiation packet sending module 530 and the service data sending module 540 are generally attributed to a user management module (TM) of the MAC layer, and the MPCP packet parsing module 510, the control module 520, and the to-be-sent data caching module 550 of the MAC layer are generally attributed to the MAC layer.
EXAMPLE six
Based on the same technical concept as described above, as shown in fig. 7, the diagram illustrates an ONU 80 according to an embodiment of the present invention, where the ONU 80 includes: memory 810, processor 820 and computer program 830 stored on memory 810 and executable on processor 820, wherein processor 820 implements the following steps when executing program 830:
acquiring state information of a link between the OLT and the OLT in real time;
when the state of the link represented by the state information of the link is a discovery state, disabling a service data sending function and deleting data to be sent of an MAC layer; the discovery state refers to a state when the ONU and the OLT are not connected;
and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
In practical applications, the Memory 810 may be a volatile Memory (volatile Memory), such as a Random-Access Memory (RAM); or a non-volatile Memory (non-volatile Memory), such as a Read-Only Memory (ROM), a flash Memory (flash Memory), a Hard Disk (HDD), or a Solid-State Drive (SSD); or a combination of the above types of memories and provides a computer program to the processor 820.
The Processor 820 may be at least one of an Application Specific Integrated Circuit (ASIC), a Digital Signal Processor (DSP), a Digital Signal Processing Device (DSPD), a Programmable Logic Device (PLD), a Field Programmable Gate Array (FPGA), a Central Processing Unit (CPU), a controller, a microcontroller, and a microprocessor. It will be appreciated that the electronic devices used to implement the processor functions described above may be other devices, and embodiments of the present invention are not limited in particular.
For example, the step of deleting the data to be sent in the MAC layer can be further executed by the processor 820 to implement the following steps: detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold value or not; and when the data volume of the data to be sent in the MAC layer exceeds the preset threshold value, deleting the data to be sent in the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the MAC layer exceeds the preset threshold value.
For example, after the step of detecting whether the data amount of the data to be sent in the MAC layer exceeds the preset threshold, the processor 820 may further implement the following steps when executing the program 830: when the data volume of the data to be sent in the MAC layer does not exceed the preset threshold value, detecting whether connection is established with the OLT or not; and when the ONU establishes connection with the OLT, enabling the service data sending function.
Illustratively, the step of acquiring the status information of the link with the OLT in real time may be further executed by the processor 820 to implement the following steps: receiving an MPCP message issued by an OLT in real time; and reading the state information of the link contained in the MPCP message.
Illustratively, after the step of acquiring the status information of the link with the OLT in real time, the processor 820 may further implement the following steps when executing the program 830: and returning to the step of acquiring the state information of the link between the OLT and the OLT in real time when the state of the link represented by the state information of the link is not the discovery state.
EXAMPLE seven
The technical solution of any of the above embodiments essentially or partially contributes to the prior art, or all or part of the technical solution may be embodied in the form of a software product stored in a computer-readable storage medium, which includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) or a processor (processor) to execute all or part of the steps of the method described in this embodiment. And the aforementioned computer-readable storage media comprise: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Specifically, the computer program instructions corresponding to a method for establishing a link in the present embodiment may be stored on a computer-readable storage medium such as an optical disc, a hard disk, a usb disk, or the like, where the computer-readable storage medium stores one or more programs, and the one or more programs are executable by one or more processors to implement the following steps:
acquiring state information of a link between the OLT and the OLT in real time;
when the state of the link represented by the state information of the link is a discovery state, disabling a service data sending function and deleting data to be sent of an MAC layer; the discovery state refers to a state when the ONU and the OLT are not connected;
and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
Illustratively, the step of deleting the data to be sent in the MAC layer may be further executed by the one or more processors to implement the following steps: detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold value or not; and when the data volume of the data to be sent in the MAC layer exceeds the preset threshold value, deleting the data to be sent in the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the MAC layer exceeds the preset threshold value.
For example, after the step of detecting whether the data amount of the data to be sent in the MAC layer exceeds the preset threshold, the one or more processors may further execute the step of: when the data volume of the data to be sent in the MAC layer does not exceed the preset threshold value, detecting whether connection is established with the OLT or not; and when the ONU establishes connection with the OLT, enabling the service data sending function.
Illustratively, the step of acquiring the status information of the link with the OLT in real time may be further executed by the one or more processors to implement the following steps: receiving an MPCP message issued by an OLT in real time; and reading the state information of the link contained in the MPCP message.
Illustratively, after the step of acquiring the status information of the link with the OLT in real time, the one or more processors may further perform the following steps: and returning to the step of acquiring the state information of the link between the OLT and the OLT in real time when the state of the link represented by the state information of the link is not the discovery state.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of a hardware embodiment, a software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, optical storage, and the like) having computer-usable program code embodied therein.
The present invention is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
The above description is only a preferred embodiment of the present invention, and is not intended to limit the scope of the present invention.

Claims (10)

1. A method for establishing a link, the method being applied to an Optical Network Unit (ONU), the method comprising:
acquiring state information of a link between the OLT and an optical line terminal in real time;
when the link state represented by the link state information is a discovery state, disabling a service data transmission function and deleting data to be transmitted of a Media Access Control (MAC) layer; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection;
and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
2. The method of claim 1, wherein the deleting data to be sent at a Media Access Control (MAC) layer comprises:
detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold value;
and when the data volume of the data to be sent in the MAC layer exceeds the preset threshold value, deleting the data to be sent in the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the MAC layer exceeds the preset threshold value.
3. The method according to claim 2, wherein after the detecting whether the data amount of the data to be transmitted in the MAC layer exceeds a preset threshold, the method further comprises:
when the data volume of the data to be sent in the MAC layer does not exceed the preset threshold value, detecting whether connection with the OLT is established or not;
and when the ONU establishes connection with the OLT, enabling the sending function of the service data.
4. The method according to claim 1, wherein the obtaining of the status information of the link with the Optical Line Terminal (OLT) in real time comprises:
receiving a multipoint control protocol (MPCP) message issued by the OLT in real time;
and reading the state information of the link contained in the MPCP message.
5. The method according to claim 1, wherein after said real-time obtaining of status information of a link with an Optical Line Termination (OLT), the method further comprises:
and when the state of the link represented by the state information of the link is not the discovery state, returning to the step of acquiring the state information of the link between the OLT and the optical line terminal OLT in real time.
6. An apparatus for establishing a link, the apparatus comprising: the device comprises a multipoint control protocol (MPCP) message analysis module, a control module, a negotiation message sending module, a service data sending module and a Media Access Control (MAC) layer data cache module to be sent; wherein the content of the first and second substances,
the MPCP message analysis module is configured to acquire the state information of the link between the optical network unit ONU to which the MPCP message analysis module belongs and the optical line terminal OLT in real time;
the control module is configured to disable the sending function of the service data sending module and delete the data to be sent in the MAC layer data-to-be-sent cache module when the state of the link represented by the state information of the link is a discovery state; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection;
the negotiation message sending module is configured to send a negotiation message for establishing connection between the ONU and the OLT to the OLT.
7. The apparatus of claim 6, wherein the control module is specifically configured to: detecting whether the data volume of the data to be sent in the MAC layer data cache module to be sent exceeds a preset threshold value or not; and when the data volume of the data to be sent in the data cache module to be sent of the MAC layer exceeds the preset threshold, deleting the data to be sent in the data cache module to be sent of the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the data cache module to be sent of the MAC layer exceeds the preset threshold.
8. An optical network unit, ONU, comprising: memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program:
acquiring state information of a link between the OLT and an optical line terminal in real time;
when the link state represented by the link state information is a discovery state, disabling a service data transmission function and deleting data to be transmitted of a Media Access Control (MAC) layer; wherein the discovery state refers to a state when the ONU and the OLT do not establish a connection;
and after the deletion of the data to be sent is finished, sending a negotiation message for establishing connection with the OLT to the OLT.
9. The ONU of claim 8, wherein the processor, when executing the computer program, further performs the steps of: detecting whether the data volume of the data to be sent in the MAC layer exceeds a preset threshold value; and when the data volume of the data to be sent in the MAC layer exceeds the preset threshold value, deleting the data to be sent in the MAC layer, and returning to the step of detecting whether the data volume of the data to be sent in the MAC layer exceeds the preset threshold value.
10. A computer readable storage medium, storing one or more programs, which are executable by one or more processors, for performing the method steps of establishing a link of any of claims 1 to 5.
CN201710601843.0A 2017-07-21 2017-07-21 Method for establishing link, ONU and computer readable storage medium Active CN109286863B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710601843.0A CN109286863B (en) 2017-07-21 2017-07-21 Method for establishing link, ONU and computer readable storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710601843.0A CN109286863B (en) 2017-07-21 2017-07-21 Method for establishing link, ONU and computer readable storage medium

Publications (2)

Publication Number Publication Date
CN109286863A CN109286863A (en) 2019-01-29
CN109286863B true CN109286863B (en) 2021-08-17

Family

ID=65184983

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710601843.0A Active CN109286863B (en) 2017-07-21 2017-07-21 Method for establishing link, ONU and computer readable storage medium

Country Status (1)

Country Link
CN (1) CN109286863B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115273453B (en) * 2021-04-30 2023-12-26 阿波罗智联(北京)科技有限公司 Method and device for managing road side equipment in vehicle-road cooperation, cloud control platform and system

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1543136A (en) * 2003-11-04 2004-11-03 港湾网络有限公司 Ether ring redundancy protection method
CN1852203A (en) * 2006-02-10 2006-10-25 华为技术有限公司 Virtual-link set-up method and apparatus
CN101385276A (en) * 2006-03-29 2009-03-11 国际商业机器公司 Apparatus, system and method for error assessment over a communication link
CN102137027A (en) * 2011-05-03 2011-07-27 厦门市美亚柏科信息股份有限公司 Reliable data transmission method and device thereof
CN103685489A (en) * 2013-12-02 2014-03-26 许继电气股份有限公司 File transmitting method in wireless network

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6748244B2 (en) * 2001-11-21 2004-06-08 Intellisist, Llc Sharing account information and a phone number between personal mobile phone and an in-vehicle embedded phone

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1543136A (en) * 2003-11-04 2004-11-03 港湾网络有限公司 Ether ring redundancy protection method
CN1852203A (en) * 2006-02-10 2006-10-25 华为技术有限公司 Virtual-link set-up method and apparatus
CN101385276A (en) * 2006-03-29 2009-03-11 国际商业机器公司 Apparatus, system and method for error assessment over a communication link
CN102137027A (en) * 2011-05-03 2011-07-27 厦门市美亚柏科信息股份有限公司 Reliable data transmission method and device thereof
CN103685489A (en) * 2013-12-02 2014-03-26 许继电气股份有限公司 File transmitting method in wireless network

Also Published As

Publication number Publication date
CN109286863A (en) 2019-01-29

Similar Documents

Publication Publication Date Title
US10827553B2 (en) Method and apparatus for session reestablishment, access and mobility management function entity, session management function entity and terminal
US20110080842A1 (en) Binding/unbinding processing method, system, and apparatus
CN108696588B (en) Information sending method and equipment
WO2016197861A1 (en) Remote management method, managed device, managing device and intelligent television system
US9008505B2 (en) Optical power adjustment method for ethernet passive optical network system, and optical line terminal
CN101217561B (en) A method to enhance the storage reliability of the network and a network device
US20020018455A1 (en) Wireless access system
CN105306867A (en) Method, device and system for improving end-to-end video transmission quality
WO2016188196A1 (en) Method and device for detecting abnormal pon terminal
CN109286863B (en) Method for establishing link, ONU and computer readable storage medium
WO2008037178A1 (en) The optical network unit and its accessing method, the optical line terminal and the passive optical network system
CN107710634A (en) Communication means and equipment based on optical network system
CN101360044B (en) Session processing method and unit preventing session oscillation
WO2011035639A1 (en) Method and apparatus for upgrade protection
CN106067857B (en) Method and device for preventing user from being forced off-line
US20180081746A1 (en) Application message processing system, method, and application device
CN113259874A (en) Message processing method, electronic device and storage medium
US20190036793A1 (en) Network service implementation method, service controller, and communications system
US20140161125A1 (en) Method, duplication point device, and system for data flow reuse transmission
CN113014615B (en) Data synchronization method, device and system
KR102544290B1 (en) Optical communication device, control method, and control program
WO2015158058A1 (en) Method and system for implementing call saving and recovery
WO2011144043A2 (en) Omci message transmission method, device and passive optical network system
CN106231618A (en) A kind of method and device sending encoding and decoding renegotiation request
JP2009124629A (en) Band management system and method, and access device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant