Optical Network Unit Device Testing Method, Apparatus, Terminal, and Storage Medium in FTTR

The automated testing system for ONUs in FTTR networks addresses inefficiencies and errors in traditional methods by remotely rebooting and monitoring ONUs, ensuring accurate and efficient stability testing.

CN119945549BActive Publication Date: 2025-07-15SICHUAN TIANYI COMHEART TELECOM
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202510232062.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-02-28
Publication Date
2025-07-15
Estimated Expiration
2045-02-28

AI Technical Summary

Technical Problem

The stability testing of existing optical network unit equipment requires manual intervention and multiple operations, which leads to time-consuming and labor-intensive and easy introduction of human errors, affecting the reliability of the test results.

Method used

Design the optical network unit device test system in FTTR, and automatically perform restart operations and test processes through automated scripts to obtain the status information of the optical network unit device and confirm the status of the dynamic host configuration protocol server.

Benefits of technology

It improves the efficiency and accuracy of optical network unit equipment testing, reduces the impact of human errors, and ensures the reliability of test results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119945549B_ABST
    Figure CN119945549B_ABST
Patent Text Reader

Abstract

The present application discloses a method, device, terminal, and storage medium for testing an optical network unit device in an FTTR. The method includes: responding to a restart instruction sent by an optical line terminal device, restarting the optical network unit device, and obtaining the device status information of the companion optical network unit device; obtaining the device status information of the main optical network unit device; obtaining the server status information of the Dynamic Host Configuration Protocol server corresponding to the optical network unit device; and generating a target test result. The purpose of the present application is to implement the testing of the optical network unit device through the designed optical network unit device testing system in the FTTR, improving the testing efficiency and accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of optical fiber communication technology, and particularly to a method, device, terminal and storage medium for testing optical network unit equipment in FTTR. Background Art

[0002] In the process of the current network operator's management and maintenance of optical network unit equipment, that is, ONU, optical network unit equipment cutover, remote upgrade, remote restart, and power-off restart are often involved. If there are defects in the optical network unit equipment, abnormalities are likely to occur. Therefore, batch equipment stability testing is required to discover problems in advance. The traditional stability testing of optical network unit equipment requires technicians to remotely log in to the optical line terminal equipment, that is, OLT (Optical Line Terminal), and restart the PON, that is, a specific optical network unit equipment under the interface of the passive optical network, and wait for a period of time (such as 5 minutes) to observe whether the optical network unit equipment goes online normally, and at the same time detect whether there is a long light emission or burst light phenomenon, which may cause problems such as other optical network unit equipment dropping offline. It is also necessary to check whether the DHCP SERVER of the optical network unit equipment, that is, the dynamic host configuration protocol server corresponding to the optical network unit equipment, can be normally obtained through the terminal connected to the optical network unit equipment. This process needs to be repeated many times (such as more than 2000 times) to ensure the accuracy and comprehensiveness of the test. Manually performing such tests by technicians is time-consuming and laborious, and is prone to introducing human errors, affecting the reliability of the test results. Summary of the Invention

[0003] The main purpose of this application is to provide a method, device, terminal and storage medium for testing optical network unit equipment in FTTR, aiming to realize the testing of optical network unit equipment through the designed optical network unit equipment testing system in FTTR, and improve the test efficiency and accuracy.

[0004] To achieve the above purpose, this application provides a method for testing optical network unit equipment in FTTR, which is applied to the optical network unit equipment testing system in FTTR. The optical network unit equipment testing system in FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit equipment and to perform a restart operation according to the interface corresponding to the optical network unit equipment and the identification code corresponding to the optical network unit equipment. The second module is used to confirm whether the dynamic host configuration protocol server corresponding to the optical network unit equipment is in a normal running state. The optical network unit equipment includes a companion optical network unit equipment and a main optical network unit equipment;

[0005] The method includes:

[0006] In response to a restart instruction sent by an optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device;

[0007] Obtain the device status information of the main optical network unit device;

[0008] Obtain the server status information of the Dynamic Host Configuration Protocol server corresponding to the optical network unit device;

[0009] Generate a target test result based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the Dynamic Host Configuration Protocol server.

[0010] Specifically, before the step of in response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device, the method further includes:

[0011] Based on a preset configuration file, determine the optical network unit device, the logical optical identifier of the optical network unit device, the number of restart times corresponding to the optical network unit device, the restart waiting time corresponding to the optical network unit device, the main optical network unit device, and the companion optical network unit device from the optical network unit devices to be tested in the passive optical network;

[0012] Establish a connection with the optical line terminal device through the first network card of the control terminal corresponding to the passive optical network and a preset communication protocol;

[0013] In response to the restart instruction, query and obtain the device status information of the optical network unit devices to be tested in the passive optical network;

[0014] Save the device status information of the optical network unit devices to be tested to a first preset text file.

[0015] Specifically, the step of obtaining the device status information of the companion optical network unit device includes:

[0016] After restarting the optical network unit device, wait for the restart waiting time and then restart the optical network unit device;

[0017] Detect whether the companion optical network unit device is in a disconnected state. If the companion optical network unit device is not in a disconnected state, it is determined that the companion optical network unit device does not have a problem of long-term light emission or burst light; if the companion optical network unit device is in a disconnected state, it is determined that the companion optical network unit device has a problem with light reception and emission;

[0018] Save the device status information of the auxiliary photometric network unit device with light emission and reception problems to a second preset text file, where the second preset text file is used to characterize the device status information of the auxiliary photometric network unit device.

[0019] Specifically, it is characterized in that obtaining the device status information of the main photometric network unit device includes:

[0020] Obtain the online status information of the main photometric network unit device, where the online status information is used to characterize the online time of the main photometric network unit device and the connection status of the main photometric network unit device;

[0021] Read the optical fiber light emission and reception power data in the first preset text file;

[0022] Based on the comparison result between the current optical fiber light emission and reception power data corresponding to the main photometric network unit device and the optical fiber light emission and reception power data in the first preset text file, obtain the device status information of the main photometric network unit device.

[0023] Specifically, it is characterized in that obtaining the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device includes:

[0024] Establish a connection with the switch corresponding to the passive optical network through the second network card of the control terminal corresponding to the passive optical network;

[0025] Based on the configuration file, perform Address Resolution Protocol (ARP) detection on the optical network unit device to obtain an address detection result;

[0026] Based on the address detection result, obtain the server status information of the DHCP server.

[0027] Specifically, it is characterized in that based on the configuration file, performing ARP detection on the optical network unit device to obtain an address detection result includes:

[0028] Perform ARP detection on the preset network addresses within the management network segment corresponding to the optical network unit device to obtain an address detection result, where the address detection result does not include the management address corresponding to the optical network unit device or the network address of the control terminal corresponding to the passive optical network.

[0029] Specifically, based on the address detection result, obtaining the server status information of the DHCP server includes:

[0030] If the number of active network addresses in the address detection result is the same as the number of terminals connected to the optical network unit device, it is determined that the Dynamic Host Configuration Protocol (DHCP) server is in a normal working state; if the number of active network addresses in the address detection result is different from the number of terminals connected to the optical network unit device, it is determined that the DHCP server is not in a normal working state.

[0031] To achieve the above object, the present application further provides a test device for an optical network unit device in an FTTR, which is applied to a test system for an optical network unit device in an FTTR. The test system for an optical network unit device in an FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit device and to perform a restart operation according to the interface corresponding to the optical network unit device and the identification code corresponding to the optical network unit device. The second module is used to confirm whether the DHCP server corresponding to the optical network unit device is in a normal operating state. The optical network unit device includes a companion optical network unit device and a main optical network unit device. The device includes:

[0032] A first unit, configured to restart the optical network unit device in response to a restart instruction sent by an optical line terminal device, and obtain the device status information of the companion optical network unit device;

[0033] A second unit, configured to obtain the device status information of the main optical network unit device;

[0034] A third unit, configured to obtain the server status information of the DHCP server corresponding to the optical network unit device;

[0035] A fourth unit, configured to generate a target test result based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the DHCP server.

[0036] To achieve the above object, the present application further provides a terminal, including a memory storing multiple instructions; the processor loads the instructions from the memory to execute the steps in any one of the methods provided by the present application.

[0037] To achieve the above object, the present application further provides a storage medium storing multiple instructions, and the instructions are suitable for being loaded by a processor to execute the steps in any one of the methods provided by the present application.

[0038] A method, device, terminal, and storage medium for testing an optical network unit device in FTTR provided by this application can first respond to a restart instruction sent by the optical line terminal device, restart the optical network unit device, and obtain the device status information of the companion optical network unit device; then, obtain the device status information of the main optical network unit device; then, obtain the server status information of the Dynamic Host Configuration Protocol server corresponding to the optical network unit device; finally, generate a target test result based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the Dynamic Host Configuration Protocol server, thereby realizing the testing of the optical network unit device and improving the testing efficiency and accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0039] Figure 1 It is a flowchart of the method provided by an embodiment of this application;

[0040] Figure 2 It is a bottom-layer processing diagram of the optical network unit device testing system in FTTR provided by an embodiment of this application;

[0041] Figure 3 It is an architecture networking diagram of the optical network unit device testing system in FTTR provided by an embodiment of this application;

[0042] Figure 4 It is a test process diagram of the optical network unit device testing system in FTTR provided by an embodiment of this application;

[0043] Figure 5 It is a structural diagram of the device provided by an embodiment of this application;

[0044] Figure 6 It is a structural diagram of the terminal provided by an embodiment of this application. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0045] Next, the technical solutions in the embodiments of this application will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of this application. Obviously, the described embodiments are only a part of the embodiments of this application, rather than all the embodiments. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative efforts fall within the scope of protection of this application.

[0046] Since the stability test of traditional optical network unit devices requires accessing the terminal through the optical network unit device to check whether the DHCP SERVER of the optical network unit device can be normally obtained, that is, the Dynamic Host Configuration Protocol server corresponding to the optical network unit device, this process needs to be repeated many times (such as more than 2000 times) to ensure the accuracy and comprehensiveness of the test. It is time-consuming and laborious for technicians to manually perform such tests, and it is easy to introduce human errors, affecting the reliability of the test results.

[0047] Therefore, the embodiments of the present application provide a method, device, terminal and storage medium for testing an optical network unit device in FTTR to solve practical technical problems.

[0048] In some embodiments, the device may be specifically integrated in an electronic device, and the electronic device may be a device such as a terminal or a server.

[0049] In some embodiments, the server may also be implemented in the form of a terminal.

[0050] Among them, the server may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms.

[0051] Among them, the terminal may be a smart phone, a tablet computer, a laptop computer, a desktop computer, a smart speaker, a smart watch, etc., but is not limited thereto. The terminal and the server may be directly or indirectly connected through wired or wireless communication methods, and the present application does not make any restrictions here.

[0052] The embodiments of the present application provide a method for testing an optical network unit device in FTTR. The method can implement the test of the optical network unit device through the designed test system of the optical network unit device in FTTR, improving the test efficiency and accuracy.

[0053] A testing method for optical network unit devices in FTTR, which is applied to a testing system for optical network unit devices in FTTR. The testing system for optical network unit devices in FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit device and to perform a restart operation according to the interface corresponding to the optical network unit device and the identification code corresponding to the optical network unit device. The second module is used to confirm whether the Dynamic Host Configuration Protocol server corresponding to the optical network unit device is in a normal running state. The optical network unit device includes an auxiliary optical network unit device and a main optical network unit device.

[0054] In some embodiments, an optical network unit device, namely an Optical Network Unit device or an ONU device, is a user-side device of a fiber access network. An ONU device is a device used to receive and process optical signals and convert them into electrical signals that can be understood by user devices. It belongs to the terminal device in a fiber communication system and is a bridge between an optical line terminal (OLT) and a user terminal device, playing a key role in broadband access networks such as fiber to the home (FTTH) and fiber to the building (FTTB).

[0055] A Dynamic Host Configuration Protocol Server (DHCP SERVER for short) is a network service program. The core function of a DHCP server is to dynamically allocate IP addresses to client devices in a network. When a client device (such as a computer, smartphone, tablet, printer, etc.) connects to the network, it sends a request to the DHCP server, and the DHCP server selects an available IP address from its address pool and assigns it to the client. In addition to allocating IP addresses, the DHCP server also provides other network configuration information to the client, including subnet mask, default gateway, DNS (Domain Name System) server address, domain name suffix, etc., to ensure that the client device can communicate with the network and access network resources normally.

[0056] Specifically, as Figure 2, the optical network unit device test system in the FTTR includes an automated script dedicated to ONU stability testing, which can automatically log in to the OLT device. After restarting the ONU, the script automatically waits for a specified time (such as 5 minutes), and then checks whether the ONU has successfully come online. The script uses a built-in optical signal detection algorithm to continuously monitor for long-burst light or burst light phenomena and whether these phenomena have an adverse impact on other ONUs. The script confirms the active IP by sending arp probe packets on the ONU LAN and determines whether the DHCP SERVER of the ONU is working properly based on the number of active IPs. During the test, all key data (such as the number of ONU restarts, online status, online time, optical signal status, offline reasons, etc.) are automatically recorded. After the test, a detailed test report is generated. If an anomaly is detected, the script immediately issues an alarm and provides possible fault location information. According to the test requirements, the script can customize the number of executions and automatically perform multiple (such as 2000 times) loop tests. The test results are statistically analyzed to evaluate the stability and reliability of the ONU.

[0057] In some embodiments, such as Figure 3 shown, the optical network unit device test system in the FTTR uses Python as the programming language and utilizes its powerful network programming and automated testing capabilities for automated system design and development. The optical network unit device test system in the FTTR mainly consists of two functional modules:

[0058] The check_onu_status module, i.e., the first module, which is mainly used to read and record the status information of the ONU on the OLT and perform a restart operation according to the interface where the ONU is located and the ONU ID:

[0059] (1) Define a login_olt function to read information such as the account information of the olt, the list of loids registered by each ONU, the number of tests, the onu ID of the ONU to be restarted, the onu ID of the accompanying test ONU, etc. through the json module, and create a telnet object through the telnetlib library to log in to the olt. To ensure successful login to the OLT as much as possible, set the timeout to 1 minute and try to log in to the olt multiple times within the timeout period.

[0060] (2) Define a save_onu_result function to append and record the onu status.

[0061] (3) Define an arrange_onu_info function to return the queried onu information in dictionary form through regular expressions of the re module. The return form is as follows:

[0062] {"loid":"xxx","onu_online":True,”onu_online_time”:"2024-12-14_12:12:12","receive_db":"-20", "send_db":"-18",”last_down_cause”:”reset”,”rogue_onu”:”no”}

[0063] (4) Define a reset_onu function to establish a connection with the OLT through the Telnet protocol by calling login_olt, input the username and password for logging in to the OLT. After successful login, traverse the read loid list, query the interface where the ONU is located and the onu id respectively, execute the command to query the status information of all ONUs under the PON port, read the ONU online status, online time, optical transceiver status, and offline reason through the arrange_onu_info function, call the save_onu_result function to save the information, then enter this interface to execute the restart command, and wait for the ONU to restart. The waiting time is obtained by reading through the read_config function.

[0064] check_subdevice_status, that is, the second module. This module mainly constructs and sends ARP packets within the local area network, checks the number of received ARP packets in response, to confirm whether the ONU DHCP SERVER is normal:

[0065] (1) Define a discover_devices function to broadcast ARP requests to the local area network to discover active IP addresses and MAC addresses. The pdst of the ARP layer is the IP address range of the network (for example, '192.168.1.0 / 24'), and the destination MAC address of the Ethernet frame Ether layer is the broadcast address ff:ff:ff:ff:ff:ff. Combine the ARP request packet and the Ethernet frame ether_frame / arp_request and send it to the broadcast through srp in the scapy.sendrecv module, and wait for a response. The response contains all the responded ARP packets. Each response includes the IP address (received.psrc) and the MAC address (received.hwsrc). Save this information in the devices dictionary, with the IP address as the key and the MAC address as the value. Obtain the number of terminals connected under the ONU according to the length of the dictionary.

[0066] (2) Define a test execution entry, run_main, which calls the reset_onu function in the check_onu_status module, records the status information of all ONUs under the PON port and executes the ONU restart instruction, then calls the discover_devices function to detect the number of terminal accesses of the ONU. If there are multiple ONUs, the run_main function is traversed and executed according to the loid list in the json configuration file. According to the configuration information in the json configuration file, the test result is obtained after the execution ends.

[0067] In some embodiments, such as Figure 2 shown, the test environment of the optical network unit device test system in FTTR can be configured and set up as follows:

[0068] Network segment configuration: To ensure the uniqueness of the test environment and avoid IP address conflicts, each ONU needs to be configured with a different IP network segment.

[0069] Network card configuration of the control terminal:

[0070] The first network card: is specifically used to connect to the OLT device to ensure unobstructed communication with the OLT.

[0071] The second network card: is used to connect to the switch to facilitate the management and communication of ONUs in the network.

[0072] IP address setting: For the IP network segment of each ONU, the second IP address of this network segment needs to be configured for the control PC network card 2 as its own static IP. For example, if the IP network segment of the ONU is 192.168.1.0 / 24, the control PC should add the IP address 192.168.1.2.

[0073] Deployment of the automated test system: Use the pyinstaller tool to package the code file into an.exe executable file, and then deploy it to the specified control PC.

[0074] Configuration of the accompanying test ONU: Under the same test PON port of the OLT, several accompanying test ONU devices need to be configured for comparative testing.

[0075] Configuration of the test networking devices:

[0076] (1) Control terminal:

[0077] Contains automated test scripts and necessary test tools.

[0078] Equipped with two network cards, the first network card is used to connect to the OLT device to operate the OLT, and the second network card is used for the switch to communicate with the ONU.

[0079] (2) OLT device:

[0080] The optical line terminal of the passive optical network is responsible for managing and controlling the ONU devices under the PON port.

[0081] Provide Telnet or other remote login protocol interfaces for the control PC to access.

[0082] (3) ONU:

[0083] ONU (Optical Network Unit): The optical network unit is a device in the optical access network system and is usually located at the user side.

[0084] (4) Switch:

[0085] The layer 2 switch is responsible for the connection and communication between the ONU and the control PC.

[0086] (5) User terminal:

[0087] It can be a PC, a set-top box, a camera, etc. When testing, the terminal is set to obtain the IP address in the dhcp mode.

[0088] Such as Figure 1 and Figure 4 As shown, the specific process of the method can be as follows:

[0089] S110. In response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the accompanying optical network unit device.

[0090] In some embodiments, before the step of in response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the accompanying optical network unit device, the method further includes the step contents of R1 to R4 as shown below:

[0091] R1. Based on a preset configuration file, determine the optical network unit device, the logical optical identifier of the optical network unit device, the restart times corresponding to the optical network unit device, the restart waiting time corresponding to the optical network unit device, the main optical network unit device, and the accompanying optical network unit device from the optical network unit devices to be tested in the passive optical network.

[0092] Specifically, according to the test requirements, the ONU serial number, LOID, restart times, restart waiting time, and accompanying device serial number for restart can be set through the config.json configuration file, that is, the preset configuration file.

[0093] R2. Establish a connection with the optical line terminal device through the first network card of the control terminal corresponding to the passive optical network and a preset communication protocol.

[0094] Specifically, use the first network card of the control terminal to establish a connection with the OLT through the Telnet protocol, that is, the preset communication protocol.

[0095] R3. In response to the restart instruction, query and obtain the device status information of the optical network unit devices to be tested in the passive optical network.

[0096] Specifically, execute the OLT command, that is, the restart instruction, and query the status information of all ONUs under the current PON port.

[0097] R4. Save the device status information of the optical network unit devices to be tested to the first preset text file.

[0098] Specifically, record the online status, online time, and light receiving and emitting conditions of all ONU devices under the PON port, and save this information to the init_result.csv file, that is, the first preset text file.

[0099] In some embodiments, obtaining the device status information of the accompanying optical network unit devices includes the step contents of S111 to S113 as shown below:

[0100] S111. After restarting the optical network unit device, wait for the restart waiting time and then restart the optical network unit device.

[0101] S112. Detect whether the accompanying optical network unit device is in a disconnected state. If the accompanying optical network unit device is not in a disconnected state, it is determined that the accompanying optical network unit device does not have a problem of long-term light emission or burst light; if the accompanying optical network unit device is in a disconnected state, it is determined that the accompanying optical network unit device has a problem with light receiving and emitting.

[0102] Specifically, after waiting for 5 minutes, the OLT command can be executed again to check whether the accompanying ONU is disconnected. If the accompanying ONU is not disconnected, it is determined that it does not have a problem of long-term light emission and burst light; otherwise, it is considered to have a problem with light receiving and emitting.

[0103] S113. Save the device status information of the accompanying optical network unit devices with problems in light receiving and emitting to the second preset text file, where the second preset text file is used to represent the device status information of the accompanying optical network unit devices.

[0104] In some embodiments, for the ONUs with problems, their serial numbers can be recorded and output to the result.csv file, that is, the second preset text file.

[0105] S120. Obtain the device status information of the main optical network unit device.

[0106] In some embodiments, obtaining the device status information of the main optical measurement network unit device includes the step contents of S121 to S123 shown below:

[0107] S121. Obtain the online status information of the main optical measurement network unit device, where the online status information is used to characterize the online time of the main optical measurement network unit device and the connection status of the main optical measurement network unit device.

[0108] S122. Read the optical fiber receiving and transmitting optical power data in the first preset text file.

[0109] S123. Based on the comparison result between the current optical fiber receiving and transmitting optical power data corresponding to the main optical measurement network unit device and the optical fiber receiving and transmitting optical power data in the first preset text file, obtain the device status information of the main optical measurement network unit device.

[0110] Specifically, check whether the online time and status of the ONU are normal. Read the optical fiber receiving and transmitting optical power data before restart (refer to init_result.csv). Compare the receiving and transmitting optical power of the current optical fiber with the data before restart. If the difference is within ±0.5 dB, it is determined that the receiving and transmitting optical power is normal; otherwise, it is regarded as having a problem. According to the detection results, record the results in the result.csv file in a predetermined format for subsequent analysis.

[0111] S130. Obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device.

[0112] In some embodiments, obtaining the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device includes the step contents of S131 to S133 shown below:

[0113] S131. Establish a connection with the switch corresponding to the passive optical network through the second network card of the control terminal corresponding to the passive optical network.

[0114] S132. Based on the configuration file, perform an Address Resolution Protocol (ARP) detection on the optical network unit device to obtain an address detection result.

[0115] In some embodiments, the specific implementation process of performing an Address Resolution Protocol (ARP) detection on the optical network unit device based on the configuration file to obtain an address detection result includes the following:

[0116] Perform Address Resolution Protocol (ARP) detection on the preset network addresses within the management network segment corresponding to the optical network unit device to obtain an address detection result, where the address detection result does not include the management address corresponding to the optical network unit device or the network address of the control terminal corresponding to the passive optical network.

[0117] S134. Based on the address detection result, obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server.

[0118] In some embodiments, the process of obtaining the server status information of the DHCP server based on the address detection result includes the following specific implementation process:

[0119] If the number of active network addresses in the address detection result is the same as the number of terminals connected to the optical network unit device, it is determined that the DHCP server is in a normal working state; if the number of active network addresses in the address detection result is different from the number of terminals connected to the optical network unit device, it is determined that the DHCP server is not in a normal working state.

[0120] Specifically, establish a connection between the second network card of the control terminal and the switch. For each ONU, perform arp detection one by one according to its management network segment configuration in config.json. During the detection process, exclude the ONU management address and the IP address of the control PC, and only perform arp detection on the 3rd to 255th IP addresses within the management network segment. If the number of active IP addresses detected by arp is the same as the number of terminals connected to the ONU, it is determined that the ONU DHCP SERVER is working properly; otherwise, it is determined that the ONU DHCP SERVER is not working properly.

[0121] In some embodiments, the above server status information can be output to the result.csv file.

[0122] S140. Based on the device status information of the slave optical network unit device, the device status information of the master optical network unit device, and the server status information of the DHCP server, generate a target test result.

[0123] In some embodiments, according to the number of restart times set by the user, determine whether to continue the test process. Finally, based on the device status information of the slave optical network unit device, the device status information of the master optical network unit device, and the server status information of the DHCP server, generate a test report in a specific format. The report content should cover all test process data, test analysis, and results. The test report is used to represent the target test result.

[0124] In the embodiment of the present application, first, in response to the restart instruction sent by the optical line terminal device, the optical network unit device is restarted, and the device status information of the companion optical network unit device is obtained; then, the device status information of the main optical network unit device is obtained; then, the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device is obtained; finally, based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the DHCP server, a target test result is generated.

[0125] In summary, the present application provides a method for testing an optical network unit device in an FTTR, which realizes the testing of the optical network unit device through the designed testing system for the optical network unit device in the FTTR, improving the testing efficiency and accuracy.

[0126] To better implement the above method, the embodiment of the present application also provides a testing device for the optical network unit device in an FTTR. This device can be specifically integrated in an electronic device, which can be a terminal, a server, or other devices. Among them, the terminal can be a mobile phone, a tablet computer, a smart Bluetooth device, a laptop computer, a personal computer, or other devices; the server can be a single server or a server cluster composed of multiple servers.

[0127] For example, in this embodiment, taking the testing device for the optical network unit device in an FTTR being specifically integrated in a terminal as an example, the method of the embodiment of the present application will be described in detail.

[0128] For example, as Figure 5 shown, the testing device 500 for the optical network unit device in an FTTR may include a first unit 501, a second unit 502, a third unit 503, and a fourth unit 504, and is applied to the testing system for the optical network unit device in an FTTR. The testing system for the optical network unit device in an FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit device and to perform a restart operation according to the interface corresponding to the optical network unit device and the identification code corresponding to the optical network unit device. The second module is used to confirm whether the DHCP server corresponding to the optical network unit device is in a normal operating state. The optical network unit device includes a companion optical network unit device and a main optical network unit device. The device includes:

[0129] The first unit 501 is used to, in response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device;

[0130] The second unit 502 is used to obtain the device status information of the main optical network unit device;

[0131] The third unit 503 is used to obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device;

[0132] The fourth unit 504 is used to generate a target test result based on the device status information of the slave optical network unit device, the device status information of the master optical network unit device, and the server status information of the DHCP server.

[0133] In specific implementation, each of the above units can be implemented as an independent entity, or can be combined arbitrarily to be implemented as the same or several entities. For the specific implementation of each of the above units, reference can be made to the foregoing method embodiments and will not be elaborated herein.

[0134] As can be seen from the above, the embodiments of the present application can implement the test of the optical network unit device through the designed optical network unit device test system in the FTTR, improving the test efficiency and accuracy.

[0135] The embodiments of the present application further provide an electronic device, which can be a device such as a terminal or a server. Among them, the terminal can be a mobile phone, a tablet computer, a smart Bluetooth device, a laptop computer, a personal computer, and so on; the server can be a single server or a server cluster composed of multiple servers, and so on.

[0136] In some embodiments, the product processing device can also be integrated in multiple electronic devices. For example, the product processing device can be integrated in multiple servers, and the optical network unit device test method in the FTTR of the present application can be implemented by multiple servers.

[0137] In this embodiment, the electronic device in this embodiment is taken as an example of a terminal for detailed description. For example, as Figure 6 shown, it shows a schematic structural diagram of a terminal 600 involved in the embodiments of the present application. Specifically:

[0138] The terminal 600 may include a processor 601 with one or more processing cores, a memory 602 with one or more storage media, a power supply 603, an input module 604, a communication module 605 and other components. Those skilled in the art can understand that Figure 6 the structure of the terminal 600 shown in

[0139] The processor 601 is the control center of the terminal 600, connecting various parts of the entire terminal 600 through various interfaces and circuits. By running or executing software programs and / or modules stored in the memory 602, and by invoking the data stored in the memory 602, it executes various functions of the terminal 600 and processes data, thereby monitoring the terminal 600 as a whole. In some embodiments, the processor 601 may include one or more processing cores; in some embodiments, the processor 601 may integrate an application processor and a modem processor. Among them, the application processor mainly processes the operating system, user interface, application programs, etc., and the modem processor mainly processes wireless communication. It can be understood that the above-mentioned modem processor may not be integrated into the processor 601 either.

[0140] The memory 602 can be used to store software programs and modules. The processor 601 executes various functional applications and data processing by running the software programs and modules stored in the memory 602. The memory 602 mainly includes a program storage area and a data storage area. Among them, the program storage area can store the operating system, application programs required for at least one function (such as the sound playback function, image playback function, etc.); the data storage area can store the data created according to the use of the terminal 600. In addition, the memory 602 may include high-speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage devices. Correspondingly, the memory 602 may also include a memory controller to provide the processor 601 with access to the memory 602.

[0141] The terminal 600 further includes a power supply 603 for powering each component. In some embodiments, the power supply 603 may be logically connected to the processor 601 through a power management system, so as to realize functions such as management of charging, discharging, and power consumption management through the power management system. The power supply 603 may also include any components such as one or more DC or AC power supplies, a recharge system, a power failure detection circuit, a power converter or inverter, and a power status indicator.

[0142] The terminal 600 may further include an input module 604, which can be used to receive input digital or character information, and generate keyboard, mouse, joystick, optical or trackball signal inputs related to user settings and function controls.

[0143] The terminal 600 may further include a communication module 605. In some embodiments, the communication module 605 may include a wireless module. The terminal 600 can perform short-distance wireless transmission through the wireless module of the communication module 605, thereby providing users with wireless broadband Internet access. For example, the communication module 605 can be used to help users send and receive emails, browse the web, and access streaming media, etc.

[0144] Although not shown, the terminal 600 may further include a display unit, etc., which will not be elaborated here. Specifically in this embodiment, the processor 601 in the terminal 600 will load the executable files corresponding to the processes of one or more application programs into the memory 602 according to the following instructions, and the processor 601 will run the application programs stored in the memory 602 to implement various functions as follows:

[0145] In response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device;

[0146] Obtain the device status information of the main optical network unit device;

[0147] Obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device;

[0148] Generate a target test result based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the DHCP server.

[0149] For the specific implementation of each of the above operations, reference may be made to the previous embodiments, which will not be elaborated here.

[0150] As can be seen from the above, the embodiments of the present application can improve the test efficiency and accuracy by implementing the test of the optical network unit device.

[0151] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructions or by controlling relevant hardware through instructions. These instructions can be stored in a storage medium and loaded and executed by a processor.

[0152] Therefore, the embodiments of the present application provide a storage medium in which multiple instructions are stored. These instructions can be loaded by a processor to execute the steps in any of the optical network unit device test methods provided by the embodiments of the present application. For example, these instructions can execute the following steps:

[0153] In response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device;

[0154] Obtain the device status information of the main optical network unit device;

[0155] Obtain the server status information of the DHCP server corresponding to the optical network unit device;

[0156] Generate a target test result based on the device status information of the companion photometric network unit device, the device status information of the main photometric network unit device, and the server status information of the Dynamic Host Configuration Protocol (DHCP) server.

[0157] Among them, the storage medium may include: Read Only Memory (ROM), Random Access Memory (RAM), magnetic disk, optical disc, etc.

[0158] According to one aspect of the present application, there is provided a computer program product or a computer program. The computer program product or the computer program includes computer instructions, and the computer instructions are stored in a storage medium. The processor of the computer device reads the computer instructions from the storage medium, and the processor executes the computer instructions, so that the computer device executes the methods provided in the various optional implementation manners provided in the above embodiments.

[0159] Since the instructions stored in the storage medium can execute the steps in any of the optical network unit device test methods provided in the embodiments of the present application, the beneficial effects that can be achieved by any of the optical network unit device test methods provided in the embodiments of the present application can be realized. For details, please refer to the previous embodiments and will not be repeated here.

[0160] The above has introduced in detail an optical network unit device test method, device, terminal, and storage medium in a Fiber to the Room (FTTR) provided in the embodiments of the present application. Specific examples are used in this article to elaborate on the principle and implementation manner of the present application. The description of the above embodiments is only used to help understand the method and its core idea of the present application; at the same time, for those skilled in the art, according to the idea of the present application, there will be changes in the specific implementation manner and application scope. In summary, the content of this specification should not be construed as a limitation to the present application.

Claims

1. A test method for an optical network unit device in FTTR, characterized in that, An optical network unit device test system applied to Fiber to the Room (FTTR). The optical network unit device test system in the FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit device and to perform a restart operation according to the interface corresponding to the optical network unit device and the identification code corresponding to the optical network unit device. The second module is used to confirm whether the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device is in a normal running state. The optical network unit device includes a companion optical network unit device and a main optical network unit device; The method includes: In response to a restart instruction sent by an optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device; Obtain the device status information of the main optical network unit device; Obtain the server status information of the DHCP server corresponding to the optical network unit device; Generate a target test result based on the device status information of the companion optical network unit device, the device status information of the main optical network unit device, and the server status information of the DHCP server.

2. The method according to claim 1, wherein Before the step of, in response to the restart instruction sent by the optical line terminal device, restart the optical network unit device and obtain the device status information of the companion optical network unit device, the method further includes: Based on a preset configuration file, determine the optical network unit device, the logical optical identifier of the optical network unit device, the restart times corresponding to the optical network unit device, the restart waiting time corresponding to the optical network unit device, the main optical network unit device, and the companion optical network unit device from the optical network unit devices to be tested in the passive optical network; Establish a connection with the optical line terminal device through the first network card of the control terminal corresponding to the passive optical network and a preset communication protocol; In response to the restart instruction, query and obtain the device status information of the optical network unit devices to be tested in the passive optical network; Save the device status information of the optical network unit devices to be tested to a first preset text file.

3. The method according to claim 2, characterized in that, The step of obtaining the device status information of the companion optical network unit device includes: After restarting the optical network unit device, wait for the restart waiting time and then restart the optical network unit device; Detect whether the companion optical network unit device is in a disconnected state. If the companion optical network unit device is not in a disconnected state, it is determined that the companion optical network unit device does not have a problem of long-term light emission or burst light. If the companion optical network unit device is in a disconnected state, it is determined that the companion optical network unit device has a problem with light reception and emission; Save the device status information of the companion optical network unit device with a problem of light reception and emission to a second preset text file, where the second preset text file is used to represent the device status information of the companion optical network unit device.

4. The method according to claim 2, wherein The step of obtaining the device status information of the main optical network unit device includes: Obtain the online status information of the main optical power measurement network unit device, where the online status information is used to characterize the online time of the main optical power measurement network unit device and the connection status of the main optical power measurement network unit device; Read the optical fiber receiving and transmitting optical power data in the first preset text file; Based on the comparison result between the current optical fiber receiving and transmitting optical power data corresponding to the main optical power measurement network unit device and the optical fiber receiving and transmitting optical power data in the first preset text file, obtain the device status information of the main optical power measurement network unit device.

5. The method according to claim 2, wherein The obtaining the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device includes: Establish a connection with the switch corresponding to the passive optical network through the second network card of the control terminal corresponding to the passive optical network; Based on the configuration file, perform Address Resolution Protocol (ARP) detection on the optical network unit device to obtain an address detection result; Based on the address detection result, obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server.

6. The method according to claim 5, characterized in that, The performing Address Resolution Protocol (ARP) detection on the optical network unit device based on the configuration file to obtain an address detection result includes: Perform Address Resolution Protocol (ARP) detection on the preset network addresses within the management network segment corresponding to the optical network unit device to obtain an address detection result, where the address detection result does not include the management address corresponding to the optical network unit device or the network address of the control terminal corresponding to the passive optical network.

7. The method according to claim 5, wherein The obtaining the server status information of the Dynamic Host Configuration Protocol (DHCP) server based on the address detection result includes: If the number of active network addresses in the address detection result is the same as the number of terminals connected to the optical network unit device, determine that the Dynamic Host Configuration Protocol (DHCP) server is in a normal working state; if the number of active network addresses in the address detection result is different from the number of terminals connected to the optical network unit device, determine that the Dynamic Host Configuration Protocol (DHCP) server is not in a normal working state.

8. An optical network unit device testing apparatus in an FTTR, characterized in that An optical network unit device test system applied to Fiber to the Room (FTTR), the optical network unit device test system in the FTTR includes a first module and a second module. The first module is used to obtain the status information of each optical network unit device and to perform a restart operation according to the interface corresponding to the optical network unit device and the identification code corresponding to the optical network unit device. The second module is used to confirm whether the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device is in a normal running state. The optical network unit device includes an auxiliary optical power measurement network unit device and a main optical power measurement network unit device. The device includes: A first unit, configured to restart the optical network unit device in response to a restart instruction sent by the optical line terminal device, and obtain the device status information of the auxiliary optical power measurement network unit device; A second unit, configured to obtain the device status information of the main optical power measurement network unit device; A third unit, configured to obtain the server status information of the Dynamic Host Configuration Protocol (DHCP) server corresponding to the optical network unit device; A fourth unit is configured to generate a target test result based on the device status information of the slave photometric network unit device, the device status information of the master photometric network unit device, and the server status information of the Dynamic Host Configuration Protocol (DHCP) server.

9. A terminal, characterized in that, It includes a processor and a memory, and the memory stores multiple instructions; the processor loads the instructions from the memory to execute the steps in the method according to any one of claims 1 to 7.

10. A storage medium, characterized in that, The storage medium stores multiple instructions, and the instructions are suitable for being loaded by a processor to execute the steps in the method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Fault detection debugging method of passive optical network system and communication message device

    CN101047443A

  • xPON comprehensive test instrument for detecting fiber optic access network and test method

    CN104333416A