Software system and device based on gateway product and electronic equipment
By integrating data collection and fault identification modules into gateway products, automatic fault analysis and alarms are realized, which solves the problems of complex fault analysis and poor user experience of gateway products, saves maintenance costs, and improves product quality.
Patent Information
- Application Number
- CN202410229110.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-02-29
- Publication Date
- 2024-08-23
Smart Images

Figure CN118535381A
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of gateway management, and in particular to a software system based on a gateway product, a software device based on a gateway product, a system, an electronic device and a corresponding storage medium. Background Art
[0002] With the rapid development of network technology, gateway products are also developing day by day, integrating more and more functions, and fault analysis is becoming more and more complicated. More and more after-sales personnel are needed, and when users encounter certain abnormalities during use, they cannot obtain abnormal information in time, and reproducing abnormalities may take a lot of time, which is very unfriendly to troubleshooting or log collection. Although there are some fault log collection methods or simple restart to solve the fault in the prior art, they do not improve the user experience and put great pressure on network operators to maintain.
[0003] At the same time, the existing troubleshooting system still has shortcomings such as insufficient intelligence and lack of configuration flexibility. Summary of the invention
[0004] The purpose of the embodiments of the present invention is to provide a software system, device and electronic device based on a gateway product, which integrates multiple functions such as data collection, so as to at least solve some of the problems in the background technology.
[0005] In order to achieve the above-mentioned purpose, the present invention provides a software system based on a gateway product, which includes a data collection module, which is arranged in the gateway product and is configured to: set personalized parameter burning to obtain the serial number and MAC address of the gateway product; cyclically detect the flag bit status in the personalized parameter and the current network status of the gateway product through the internal detection module; if the detection result is that the flag bit exists and the external network can be accessed normally, then execute an external executable file obtained from the external network server in the background of the gateway product to start the corresponding first process; the external executable file has a data acquisition function; write the server data obtained by the first process into a log, distinguish the data in the log according to the serial number and / or MAC address, and transfer the log to the external network server.
[0006] Preferably, the external executable file is generated by cross-compiling a C source file; the data acquisition function is set in the C source file to obtain at least one of memory, running time, CPU occupancy, process memory occupancy, number of hanging devices, plug-in running status, flash memory erase status, and network status.
[0007] Preferably, the external executable file also includes a customized data acquisition time; the data acquisition time and the data acquisition function are integrated into the external executable file after being configured by the user, and the external executable file is uploaded to the external network server.
[0008] Preferably, the C source file also includes a Shell automatic update script; the Shell automatic update script starts a second process, the second process cyclically obtains the information summary of the executable file in the external network server and compares it with the information summary of the existing external executable file of the gateway product, and decides whether to update according to the comparison result; the new external executable file is uploaded to the external network server after being compiled through the C source file modified by the user; when the comparison result is that an update is required, the Shell automatic update script ends the existing first process, grants running permissions to the new external executable file, and calls the data collection module to perform data collection.
[0009] Preferably, the software system also includes a fault identification module, which is arranged in an external network server or a user terminal and is configured to: use a python script to traverse the server data in the log to obtain the trend of various server data; compare the server data with various thresholds to obtain a comparison result; filter out abnormal gateway products based on the trend and the comparison result; and send the serial number or MAC address of the abnormal gateway product and the abnormal server data to relevant personnel through a mini program.
[0010] Preferably, if the fault identification module is provided in the user terminal, a baking file push module is provided in the external network server, and the baking file push module is used to push the baking file to the user terminal as a processing object of the python script.
[0011] The present invention also provides a software device based on a gateway product, which includes a data collection module, which is arranged in the gateway product, including: a parameter submodule, used to set personalized parameter burning and obtain the serial number and MAC address of the gateway product; a detection submodule, used to cyclically detect the flag bit status in the personalized parameter and the current network status of the gateway product through the internal detection module; an execution submodule, used to execute an external executable file obtained from the external network server in the background of the gateway product if the detection result is that the flag bit exists and the external network can be accessed normally, so as to pull up the corresponding first process; the external executable file has a data acquisition function; and an output submodule, used to write the server data obtained by the first process into a log, distinguish the data in the log according to the serial number and / or MAC address, and transmit the log to the external network server.
[0012] The present invention also provides an electronic device, comprising: at least one processor; a memory connected to the at least one processor; wherein the memory stores instructions that can be executed by the at least one processor, and the at least one processor implements the aforementioned gateway product-based software system by executing the instructions stored in the memory.
[0013] Preferably, the electronic device is one of a set-top box, a home gateway, an Internet of Things gateway, and a data gateway having a gateway function.
[0014] The present invention also provides a system, which includes: a gateway product, an external network server and a user terminal; the system realizes data collection, file update and fault alarm based on the aforementioned software system based on the gateway product.
[0015] The present invention also provides a machine-readable storage medium, on which instructions are stored. When the instructions are executed by a processor, the processor is configured to execute and implement the aforementioned software system based on the gateway product.
[0016] The present invention also provides a computer program product, including a computer program, which implements the aforementioned gateway product-based software system when executed by a processor.
[0017] The above technical solution has the following beneficial effects:
[0018] The software system in the present invention can collect and analyze data, generate fault alarms, and automatically upgrade, thereby greatly saving labor costs and time costs and improving the quality of gateway products.
[0019] Other features and advantages of the embodiments of the present invention will be described in detail in the subsequent detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] The accompanying drawings are used to provide a further understanding of the embodiments of the present invention and constitute a part of the specification. Together with the following specific implementations, they are used to explain the embodiments of the present invention, but do not constitute a limitation on the embodiments of the present invention. In the accompanying drawings:
[0021] Figure 1 Schematically shows a schematic diagram of the steps of a data collection module of a software system based on a gateway product according to an embodiment of the present invention;
[0022] Figure 2 A schematic diagram of the structure of a system according to an embodiment of the present invention is shown;
[0023] Figure 3The structure diagram of the data collection module of the software device based on the gateway product according to the embodiment of the present invention is schematically shown. DETAILED DESCRIPTION
[0024] The specific implementation of the embodiment of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the embodiment of the present invention, and is not used to limit the embodiment of the present invention.
[0025] Figure 1 The schematic diagram of the steps of the data collection module of the software system based on the gateway product according to the embodiment of the present invention is shown. Figure 1 As shown, a software system based on a gateway product includes a data collection module, and the data collection module is set in the gateway product and configured as follows:
[0026] S01. Set personalized parameter burning and obtain the serial number and MAC address of the gateway product;
[0027] S02, cyclically detecting the flag status in the personalized parameters and the current network status of the gateway product through the internal detection module;
[0028] S03. If the detection result shows that the flag bit exists and the external network can be accessed normally, an external executable file obtained from the external network server is executed in the background of the gateway product to start the corresponding first process; the external executable file has a data acquisition function;
[0029] S04: writing the server data acquired by the first process into a log, distinguishing the data in the log according to the serial number and / or MAC address, and transmitting the log to the external network server.
[0030] Through the above implementation methods, automatic data collection through the data collection module in the gateway product is achieved.
[0031] In some embodiments of the present invention, the external executable file is generated by cross-compiling a C source file; the data acquisition function is set in the C source file to obtain at least one of memory, running time, CPU occupancy, process memory occupancy, number of hanging devices, plug-in running status, flash memory erase status, and network status. The C source file has a data acquisition function for acquiring data, which can acquire important data such as memory, running time, CPU occupancy, memory occupancy of each process, number of hanging devices, plug-in running status, FLASH erase status, network status, and other important data that affect the operation of the device.
[0032] In some embodiments of the present invention, the external executable file also includes a customized data acquisition time; the data acquisition time and the data acquisition function are integrated into the external executable file after being configured by the user, and the external executable file is uploaded to the external network server. The data acquisition time in this embodiment can be a scheduled acquisition or a periodic acquisition, thereby improving the flexibility and configurability of the acquisition time.
[0033] In some embodiments of the present invention, the C source file also includes a Shell automatic update script: the Shell automatic update script pulls up a second process, the second process cyclically obtains the information summary of the executable file in the external network server and compares it with the information summary of the existing external executable file of the gateway product, and decides whether to update according to the comparison result; the new external executable file is uploaded to the external network server after being compiled by the C source file modified by the user; when the comparison result is that an update is required, the Shell automatic update script ends the existing first process, grants the new external executable file the running permission, and calls the data collection module to perform data collection. In this embodiment, an update method for an external executable file is provided, and the user can replace the external executable file at any time. When the user replaces or updates the external executable file, the user only needs to modify the C source file, and the modified C source file is compiled and placed in the external network server, and does not need to restart the gateway product, which has the advantages of being simple and fast. The information summary here is preferably the MD5 algorithm, which is a widely used hash algorithm with many advantages.
[0034] In some embodiments of the present invention, the software system also includes a fault identification module, which is arranged in an external network server or a user terminal and is configured to: use a python script to traverse the server data in the log to obtain the trend of various types of server data; compare the server data with various thresholds to obtain a comparison result; filter out abnormal gateway products according to the trend and the comparison result; send the serial number or MAC address of the abnormal gateway product and the abnormal server data to relevant personnel through a small program. The fault identification module here can be arranged in an external network server and executed by the external network server, or it can be arranged in a user terminal and executed by the user terminal. The trend of various types of server data here refers to first classifying the server data, and the classification is based on the classification of multiple types of data obtained by the aforementioned data acquisition function, and the trend includes multiple trends such as increasing, decreasing, becoming better, and becoming worse. This embodiment also combines data trends with data threshold judgments, and has the advantage of more accurate judgments. The small program here is preferably a WeChat small program, which has the advantage of high versatility.
[0035] In some embodiments of the present invention, if the fault identification module is set in the user terminal, a baking file push module is set in the external network server, and the baking file push module is used to push the baking file to the user terminal as the processing object of the python script. The aforementioned embodiment provides flexibility in setting, but when the fault identification module is set in the user terminal, it is necessary to receive the baking file at the user terminal as the processing object of the python script.
[0036] Through the above implementation methods, the software system based on the gateway product has functions such as data collection, data update and fault analysis, which greatly saves labor costs and time costs, and is of great significance to improving the product quality of gateway products.
[0037] Figure 2 The structure diagram of a system according to an embodiment of the present invention is schematically shown. Figure 2 As shown, a system includes: a gateway product (not marked in the figure), an external network server and a user end; the system realizes data collection, file update and fault alarm based on the aforementioned software system based on the gateway product. The system mainly realizes the following functions: (1) The user customizes the acquisition time and required data, and transmits the executable file to the external network server. The executable file can be an update file. The user can replace the executable file at any time. The gateway product designs an automatic update program to determine whether the executable file needs to be replaced based on the information summary such as MD5, so that the user can obtain the data he needs at any time. (2) The gateway product designs a startup program to determine whether to identify and start the file based on the automatic data collection algorithm, and transmits the generated data file to the external network server. (3) The user end uses a script to execute the fault identification algorithm, identify the data file, and compare and process each data with the alarm threshold. If there is an abnormality, it will be pushed to the relevant personnel. The push here can be pushed through the WeChat applet. The relevant personnel can be developers, and the developers can pre-process the abnormality.
[0038] Through the above implementation methods, data can be collected and analyzed, fault alarms can be generated, and automatic upgrades can be performed, thereby greatly saving labor costs and time costs and improving the quality of gateway products.
[0039] Based on the same inventive concept, the embodiment of the present invention further provides a software device based on a gateway product. Figure 3 The structure diagram of the data collection module of the software device based on the gateway product according to the embodiment of the present invention is schematically shown. Figure 3As shown, the software device includes a data collection module, which is arranged in the gateway product, including: a parameter submodule, used to set personalized parameter burning, and obtain the serial number and MAC address of the gateway product; a detection submodule, used to cyclically detect the flag bit status in the personalized parameter and the current network status of the gateway product through the internal detection module; an execution submodule, used to execute the external executable file obtained from the external network server in the background of the gateway product if the detection result is that the flag bit exists and the external network can be accessed normally, so as to pull up the corresponding first process; the external executable file has a data acquisition function; and an output submodule, used to write the server data obtained by the first process into a log, distinguish the data in the log according to the serial number and / or MAC address, and transfer the log to the external network server.
[0040] In some optional embodiments, the external executable file is generated by cross-compiling a C source file; the data acquisition function is set in the C source file to obtain at least one of memory, running time, CPU occupancy, process memory occupancy, number of connected devices, plug-in running status, flash memory erase status, and network status.
[0041] In some optional implementations, the external executable file also includes a customized data acquisition time; the data acquisition time and the data acquisition function are integrated into the external executable file after user configuration, and the external executable file is uploaded to the external network server.
[0042] In some optional implementations, the C source file also includes a Shell automatic update script; the Shell automatic update script starts a second process, the second process cyclically obtains the information summary of the executable file in the external network server and compares it with the information summary of the existing external executable file of the gateway product, and decides whether to update according to the comparison result; the new external executable file is uploaded to the external network server after being compiled through the C source file modified by the user; when the comparison result is that an update is required, the Shell automatic update script ends the existing first process, grants running permissions to the new external executable file, and calls the data collection module to perform data collection.
[0043] In some optional embodiments, the software system also includes a fault identification module, which is disposed in an external network server or a user terminal and is configured to: use a python script to traverse the server data in the log to obtain the trend of various types of server data; compare the server data with various thresholds to obtain a comparison result; filter out abnormal gateway products based on the trend and the comparison result; and send the serial number or MAC address of the abnormal gateway product and the abnormal server data to relevant personnel through a mini program.
[0044] In some optional implementations, if the fault identification module is set in the user terminal, a baking file push module is set in the external network server, and the baking file push module is used to push the baking file to the user terminal as a processing object of the python script.
[0045] The specific definition of each functional module in the above-mentioned software device based on the gateway product can refer to the definition of the software system based on the gateway product above, which will not be repeated here. Each module in the above-mentioned device can be implemented in whole or in part by software, hardware and their combination. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules. It also has the advantages of being able to collect and analyze data, fault alarms, and automatic upgrades, thereby greatly saving labor costs and time costs, and improving the quality of gateway products.
[0046] In some embodiments of the present invention, an electronic device is also provided, comprising: at least one processor; a memory connected to the at least one processor; wherein the memory stores instructions that can be executed by the at least one processor, and the at least one processor executes the aforementioned software system based on the gateway product. The control module or processor here has the functions of numerical calculation and logical operation, and it has at least a central processing unit CPU with data processing capability, a random access memory RAM, a read-only memory ROM, a variety of I / O ports and an interrupt system, etc. The processor includes a kernel, and the kernel calls the corresponding program unit from the memory. One or more kernels can be set, and the aforementioned method is implemented by adjusting the kernel parameters. The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory, such as a read-only memory (ROM) or flash memory (flash RAM), and the memory includes at least one memory chip.
[0047] In one embodiment of the present invention, a machine-readable storage medium is provided, on which instructions are stored. When the instructions are executed by a processor, the processor is configured to execute the aforementioned gateway product-based software system.
[0048] In one embodiment of the present invention, a computer program product is provided, including a computer program, which implements the aforementioned gateway product-based software system when executed by a processor.
[0049] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.
[0050] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0051] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0052] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process in the computer or other programmable device. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0053] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0054] The memory may include non-permanent memory in a computer-readable medium, random access memory (RAM) and / or non-volatile memory in the form of read-only memory (ROM) or flash RAM. The memory is an example of a computer-readable medium.
[0055] Computer readable media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device. As defined herein, computer readable media does not include temporary computer readable media (transitory media), such as modulated data signals and carrier waves.
[0056] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0057] The above are only embodiments of the present application and are not intended to limit the present application. For those skilled in the art, the present application may have various changes and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included within the scope of the claims of the present application.
Claims
1. A software system based on a gateway product, characterized in that: The software system includes a data collection module, which is provided in the gateway product and configured as follows: Set personalized parameter burning and obtain the serial number and MAC address of the gateway product; Circularly detect the flag status in the personalized parameters and the current network status of the gateway product through the internal detection module; If the detection result is that the flag bit exists and the external network can be accessed normally, an external executable file obtained from the external network server is executed in the background of the gateway product to start the corresponding first process; the external executable file has a data acquisition function; The server data acquired by the first process is written into a log, and the data in the log is distinguished according to the serial number and / or MAC address, and the log is transmitted to the external network server.
2. The software system according to claim 1, characterized in that: The external executable file is generated by cross-compiling the C source file; The data acquisition function is set in the C source file and is used to obtain at least one of memory, running time, CPU occupancy, process memory occupancy, number of hanging devices, plug-in running status, flash memory erasure status, and network status.
3. The software system according to claim 2, characterized in that: The external executable file also includes a customized data acquisition time; The data acquisition time and the data acquisition function are integrated into the external executable file after being configured by the user, and the external executable file is uploaded to the external network server.
4. The software system according to claim 2, characterized in that: The C source file also includes a Shell automatic update script; The Shell automatic update script starts a second process, which cyclically obtains the information summary of the executable file in the external network server and compares it with the information summary of the existing external executable file of the gateway product, and decides whether to update according to the comparison result; the new external executable file is uploaded to the external network server after being compiled by the C source file modified by the user; When the comparison result indicates that an update is required, the Shell automatic update script terminates the existing first process, grants the execution permission to the new external executable file, and calls the data collection module to perform data collection.
5. The software system according to claim 1, characterized in that: The software system further includes a fault identification module, which is disposed in an external network server or a user terminal and is configured as follows: Use Python scripts to traverse the server data in the logs and find out the trend of various server data; Compare the server data with various thresholds to obtain comparison results; Screening out abnormal gateway products according to the trend and the comparison results; The abnormal serial number or MAC address of the gateway product and the abnormal server data are sent to relevant personnel through the mini program.
6. The software system according to claim 5, characterized in that: If the fault identification module is set in the user end, a baking file push module is set in the external network server, and the baking file push module is used to push the baking file to the user end as a processing object of the python script.
7. A software device based on a gateway product, characterized in that: The software device includes a data collection module, which is arranged in the gateway product and includes: The parameter submodule is used to set personalized parameter burning and obtain the serial number and MAC address of the gateway product; A detection submodule, used for cyclically detecting the status of the flag bit in the personalized parameters and the current network status of the gateway product through an internal detection module; An execution submodule, for executing an external executable file obtained from an external network server in the background of the gateway product to start a corresponding first process if the detection result shows that the flag bit exists and the external network can be accessed normally; the external executable file has a data acquisition function; and The output submodule is used to write the server data acquired by the first process into a log, distinguish the data in the log according to the serial number and / or MAC address, and transfer the log to the external network server.
8. An electronic device, characterized in that: include: at least one processor; a memory connected to the at least one processor; The memory stores instructions that can be executed by the at least one processor, and the at least one processor implements the gateway product-based software system as described in any one of claims 1 to 4 by executing the instructions stored in the memory.
9. The electronic device according to claim 8, characterized in that: The electronic device is one of a set-top box, a home gateway, an Internet of Things gateway, and a data gateway with a gateway function.
10. A system, characterized in that: The system comprises: a gateway product, an external network server and a user terminal; the system realizes data collection, file update and fault alarm based on the software system based on the gateway product described in any one of claims 1 to 6.
