CN115022170A - Intelligent gateway and area upgrading control method thereof - Google Patents

Intelligent gateway and area upgrading control method thereof Download PDF

Info

Publication number
CN115022170A
CN115022170A CN202210612943.4A CN202210612943A CN115022170A CN 115022170 A CN115022170 A CN 115022170A CN 202210612943 A CN202210612943 A CN 202210612943A CN 115022170 A CN115022170 A CN 115022170A
Authority
CN
China
Prior art keywords
mac
intelligent gateway
mac address
configuration file
file
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210612943.4A
Other languages
Chinese (zh)
Inventor
雷鹏
邵长利
郭中磊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hisense Broadband Multimedia Technology Co Ltd
Original Assignee
Hisense Broadband Multimedia Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hisense Broadband Multimedia Technology Co Ltd filed Critical Hisense Broadband Multimedia Technology Co Ltd
Priority to CN202210612943.4A priority Critical patent/CN115022170A/en
Priority to CN202211132006.5A priority patent/CN115348173A/en
Publication of CN115022170A publication Critical patent/CN115022170A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/08Configuration management of networks or network elements
    • H04L41/0803Configuration setting
    • H04L41/0813Configuration setting characterised by the conditions triggering a change of settings
    • H04L41/082Configuration setting characterised by the conditions triggering a change of settings the condition being updates or upgrades of network functionality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/66Arrangements for connecting between networks having differing types of switching systems, e.g. gateways
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/06Protocols specially adapted for file transfer, e.g. file transfer protocol [FTP]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/2866Architectures; Arrangements
    • H04L67/30Profiles
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The intelligent gateway comprises an interface and a CPU (central processing unit), wherein the interface is used for receiving downloaded configuration files, the configuration files comprise an MAC (media access control) address library of the intelligent gateway in a region and an upgrade file download address corresponding to an MAC address, and the MAC addresses in the MAC address library are discontinuous; the CPU is used for searching whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in the MAC address library, if the matched MAC address exists, the upgrading file is downloaded according to the downloading address corresponding to the MAC address, and the intelligent gateway is upgraded after the upgrading file is successfully verified. According to the method and the system, the intelligent gateway identifies the installation area through the MAC address in the configuration file, the server identification is not needed, the configuration file only contains the download address of the upgrade file, the calculation power and the flow of the server are saved, the server is miniaturized, and the hardware cost and the maintenance cost of the server are saved.

Description

Intelligent gateway and area upgrading control method thereof
Technical Field
The application relates to the technical field of intelligent gateways, in particular to an intelligent gateway and a region upgrading control method of the intelligent gateway.
Background
With the rise and development of the internet of things, a large number of sensors and routers capable of accessing the internet are integrated into the life of people. Nowadays, the internet of things devices are billions, and people's ever-changing demands are met by continuously upgrading the firmware and updating the software of the router.
At present, The upgrading of a router comprises Content Delivery Network (CDN) upgrading and centralized control upgrading, in an OTA (Over The Air, depending on Over The Air) scheme of a conventional router based on CDN technology, The MAC addresses of The router in a packing box are continuous, and The routers distributed to various cities are transported based on The packing box, so that The upgrading of a designated area can be completed by using a limited number of MAC address sections; the centralized control usually includes that the terminal periodically initiates an upgrade request to establish a session with the server, the upgrade request includes information of the terminal, and the server extracts the information of the terminal and compares the information with the information of the server database to determine whether to upgrade or not and upgrade the version used.
However, the CDN upgrade method is not accurate enough in region locking, and in an actual use scenario, the router is often installed disorderly due to some errors in management, and the MAC address cannot be used to control the address of the real space; the centralized control upgrading mode comprises a large amount of transportation and system I/O (input/output) inside the server, an upgrading packet of the upgrading mode cannot be stored by using the CDN, the network speed of the computing center can generate a bottleneck in the upgrading process of millions of platforms, other services of the computing center are forced to be stopped, the server has to adopt a flow control algorithm to ensure that the services of the computing center are normal, the computational overhead of a server side is increased, and the real-time performance of terminal upgrading is reduced.
Disclosure of Invention
The embodiment of the application provides an intelligent gateway and a region upgrading control method of the intelligent gateway, so that when the intelligent gateway is upgraded, the installation region of the intelligent gateway is accurately identified, and the calculation capacity and the flow of a server are saved.
In a first aspect, the present application provides an intelligent gateway, including:
the interface is configured to receive a downloaded configuration file, wherein the configuration file comprises an MAC address base of the intelligent gateway in the region and an upgrade file downloading address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous;
the CPU is configured to search whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in the MAC address library; if the matched MAC address exists in the MAC address base, downloading an upgrade file according to a download address corresponding to the MAC address, and upgrading the intelligent gateway after the upgrade file is successfully verified.
In a second aspect, the present application further provides a method for controlling area upgrade of an intelligent gateway, where the method includes:
receiving a downloaded configuration file, wherein the configuration file comprises an MAC address library of an intelligent gateway in a region and an upgrade file download address corresponding to an MAC address, and the MAC address in the MAC address library is discontinuous;
searching whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in the MAC address library;
if the matched MAC address exists in the MAC address library, downloading an upgrade file according to a download address corresponding to the MAC address;
and after the upgrade file is successfully checked, upgrading the intelligent gateway.
The intelligent gateway comprises an interface and a CPU electrically connected with the interface, wherein the interface is used for receiving a downloaded configuration file, namely the intelligent gateway sends an upgrade request to a CDN (content delivery network) through the interface so as to download the configuration file from the CDN, and the configuration file comprises an MAC (media access control) address library of the intelligent gateway in a region and an upgrade file download address corresponding to the MAC address, so that the intelligent gateway receives the MAC address library containing all the MAC addresses of the intelligent gateway in an installation region so as to identify the installation region of the intelligent gateway; the MAC addresses in the MAC address library are discontinuous, and when the intelligent gateways of the installation area are upgraded, the MAC addresses of all the intelligent gateways need to be matched and identified, so that the intelligent gateways of the installation area can be upgraded simultaneously; after receiving the downloaded configuration file, the intelligent gateway searches whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in an MAC address library, namely, whether the MAC address of the intelligent gateway to be upgraded belongs to the installation region is checked; if the matched MAC address exists in the MAC address library, the intelligent gateway to be upgraded belongs to the installation region, the upgrade file is downloaded according to the download address corresponding to the matched MAC address, and after the upgrade file is successfully verified, the intelligent gateway is upgraded according to the upgrade file. That is, the configuration file only contains the download address of the upgrade file, and the intelligent gateway downloads the upgrade file from the CDN network according to the download address without the need for the server to provide an upgrade package, which can save server effort and traffic. According to the method, the configuration file downloaded from the CDN by the intelligent gateway comprises an MAC address base of the intelligent gateway in the region and an upgrade file downloading address corresponding to the MAC address, the installation region of the intelligent gateway is identified according to whether the MAC address base has the MAC address matched with the MAC of the intelligent gateway to be upgraded, so that the intelligent gateway of the installation region can be upgraded conveniently, and the positioning algorithm does not depend on auxiliary algorithms such as protocols and sensors in a network topology angle; after the intelligent gateway is positioned, the upgrading file is downloaded according to the downloading address corresponding to the matched MAC address, so that the calculation power and the flow of a server can be saved; the method has the advantages of accurately positioning the area of the user, optimizing the structure, miniaturizing the server, simplifying the calculation of the server side, simplifying the overstaffed server overhead, saving the hardware cost and the maintenance cost of the server and saving the network flow cost of the server outlet.
Drawings
FIG. 1 is a diagram of a connection relationship of an intelligent gateway and a server, according to some embodiments;
fig. 2 is a connection relationship diagram of an intelligent gateway and a content distribution network provided in the embodiment of the present application;
fig. 3 is a first flowchart of a method for controlling a regional upgrade of an intelligent gateway according to an embodiment of the present application;
fig. 4 is a second flowchart of a method for controlling area upgrade of an intelligent gateway according to an embodiment of the present application.
Detailed Description
To facilitate the description of the claimed embodiments, some concepts related to the present application will be described below.
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
Fig. 1 is a diagram of a connection relationship of an intelligent gateway and a server according to some embodiments. As shown in fig. 1, when an intelligent gateway is installed in a region, the intelligent gateway is directly connected to a server, an MAC address of the intelligent gateway is stored in a storage region of the server, and the server sends an upgrade file to the intelligent gateway, so that the intelligent gateway can be upgraded according to the upgrade file. When other intelligent gateways are installed in the same region, a CDN network is connected between the server and the intelligent gateways, namely the server and the CDN network are in communication connection, the CDN network is in communication connection with each intelligent gateway, and MAC addresses of all the intelligent gateways installed in the region are stored in the CDN network. Therefore, when the intelligent gateway sends an upgrading request to the server, the server transmits the configuration file to the CDN, the intelligent gateway sends the upgrading request to the CDN, and the upgrading file is downloaded in the CDN. In some embodiments, the intelligent gateway includes a router, and the upgrade control method of the intelligent gateway may be described by taking router upgrade as an example.
When The existing intelligent gateway is upgraded, The upgrading mode mainly comprises CDN upgrading and centralized control upgrading, in The OTA (Over The Air, depending on Over The Air) scheme of The conventional intelligent gateway based on CDN technology, The MAC addresses of The intelligent gateway in a packing box are continuous, and The intelligent gateways distributed to various cities are transported based on The packing box, so that The upgrading of a designated area can be completed by using a limited number of MAC address sections. Namely, the MAC address field of a region is segmented continuously, for example, the MAC address of a region is segmented, 40 intelligent gateways are taken as one segment, the MAC addresses of the 40 intelligent gateways are 1-9, 11-19, 21-29, 30-39 and the like, when the intelligent gateways in the region are upgraded, the intelligent gateways are upgraded in a segmented mode, namely, 40 intelligent gateways are upgraded, and after the upgrade is completed, the next 40 intelligent gateways are upgraded. However, the CDN upgrade method is not accurate enough in regional locking, and in an actual use scenario, the intelligent gateway is often installed disorderly due to some errors in management, and the MAC address cannot be used to control the address in the real space.
When the centralized control upgrading is adopted, the centralized control usually means that a terminal periodically initiates an upgrading request to establish a session with a server, the upgrading request comprises terminal information, the server extracts the terminal information and compares the terminal information with the information of a server database to judge whether the intelligent gateway needs upgrading or not and upgrade the version used, namely, whether the intelligent gateway needs upgrading or not and the version used for upgrading are all carried out at the server. However, the centralized control upgrading mode includes a large amount of transportation and system I/O in the server, and the upgrading packet of the upgrading mode cannot be stored by using the CDN, so that in the millions of upgrading processes, the network speed of the computing center may become a bottleneck, causing other services of the computing center to be forced to be suspended, and in order to ensure that the services of the computing center are normal, the server has to adopt a flow control algorithm, which increases the computational overhead of the server side, and reduces the real-time performance of terminal upgrading.
In order to solve the problems, the distributed algorithm is applied to an access network terminal (intelligent gateway), the area identification calculation is distributed to the cloud side without depending on a network topology structure or a centralized server, and the calculation power and the flow of the server are saved.
Fig. 2 is a connection relationship diagram of an intelligent gateway and a content distribution network provided in the embodiment of the present application. As shown in fig. 2, the intelligent gateway includes an interface and a CPU, and the intelligent gateway is in communication connection with the CDN network through the interface, and if the intelligent gateway performs upgrade, the intelligent gateway sends an upgrade request to the CDN network through the interface, and after the CDN network receives the upgrade request, the CDN network downloads the configuration file into the intelligent gateway through the interface.
The MAC version stored in the current database of the intelligent gateway and the version of the configuration file downloaded through the interface may be the same or different, and if the MAC version is the same, the MAC version in the current database is the latest version and does not need to be updated; if not, the MAC version in the current database is not the latest version, and a new version needs to be downloaded.
To facilitate identifying the version of the configuration file, the configuration file is in the format:
{
"img":
{
"product_ID":"VS002",
"hw_version":"V1.0.0",
"sw_src_ver":"V1.0.1.120",
"sw_dst_ver":"V1.1.5.138b",
"mac_limits":"B84DEE000000-B84DEEFFFFFF",
"target_URI":"http://ota.hbmtservice.com/VS007/img115138b.tar",
"target_MD5":"92332638aaa2bd84cd3a1d51f62cd716",
"cycle_time":90000
}
}
the product _ ID, the hw _ version, the sw _ src _ ver and the sw _ dst _ ver represent version information, and whether the MAC version stored in the current database of the intelligent gateway is the same as the version of the configuration file downloaded through the interface can be detected according to the version information.
In order to make the MAC version in the current database of the intelligent gateway the latest version, the configuration file downloaded by the intelligent gateway through the interface includes a URL identifying the configuration file MAC _ CFG and a version number identifying the configuration file MAC _ CFG, and the version number corresponds to the URL. That is, the configuration file is changed, a MAC _ config field is added to the configuration file, for example, the URL of the configuration file MAC _ CFG is recorded in the MAC _ config _ URL field, and a new configuration file MAC _ CFG can be downloaded from the CDN network according to the URL of the configuration file MAC _ CFG; the MAC _ config _ ver field is added to record the version number of the configuration file MAC _ CFG to confirm whether the version number is downloaded in the intelligent gateway or not through the version number.
In some embodiments, the configuration file is changed, adding the mac _ config field:
{
"img":
{
"product_ID":"VS002",
"hw_version":"V1.0.0",
"sw_src_ver":"V1.0.1.120",
"sw_dst_ver":"V1.1.5.138b",
"mac_limits":
{
"mac_config_enable":"1",
"mac_config_ver":"1235",
"mac_config_url":"http://ota.hbmtservice.com/VS007/mac_config.cfg",
}
"target_URI":"http://ota.hbmtservice.com/VS007/img115138b.tar",
"target_MD5":"92332638aaa2bd84cd3a1d51f62cd716",
"cycle_time":90000
}
}
wherein, product _ ID, hw _ version, sw _ src _ ver and sw _ dst _ ver in the configuration file represent version information of the configuration file, mac _ config _ ver represents the version number of the configuration file, and mac _ config _ URL represents the download address URL of the configuration file.
After receiving the downloaded configuration file through the interface, the intelligent gateway analyzes the configuration file to obtain the version number recorded by the configuration file, compares the version number with the current MAC version number of the intelligent gateway (the MAC version number stored in the intelligent gateway database), and judges whether the version number obtained by analysis is consistent with the current MAC version number of the intelligent gateway or not so as to confirm whether the intelligent gateway needs to be upgraded or not.
If the version number obtained by analysis is consistent with the current MAC version number of the intelligent gateway, the current MAC version number of the intelligent gateway is the latest version number, and the intelligent gateway does not need to be upgraded.
If the version number obtained by analysis is not consistent with the current MAC version number of the intelligent gateway, the server updates the version number of the intelligent gateway in the installation area, the intelligent gateway needs to be upgraded, and the MAC version number in the database of the intelligent gateway is updated according to the version number obtained by analysis.
And when the version number obtained by analysis is inconsistent with the current MAC version number of the intelligent gateway, the intelligent gateway downloads a new configuration file MAC _ CFG according to the URL of the MAC _ config _ URL identification configuration file MAC _ CFG in the configuration file so as to upgrade the intelligent gateway through the new configuration file MAC _ CFG.
After the MAC version number of the intelligent gateway is successfully matched, the address information needs to be matched, namely whether the MAC of the intelligent gateway is contained in an MAC address library in the configuration file is judged. When the MAC of the intelligent gateway is contained in the MAC address library of the configuration file, the intelligent gateway is indicated to be successfully matched with the address information.
In some embodiments, the CDN network may periodically send the configuration file to each installation area, and after the intelligent gateway receives the downloaded configuration file, the MAC address included in the configuration file received by the intelligent gateway may be an intelligent gateway MAC address library of another installation area, that is, the MAC address of the intelligent gateway and the MAC address library included in the received configuration file belong to different installation areas, so that the installation area needs to be confirmed according to the MAC address of the intelligent gateway and the MAC address library included in the configuration file.
In order to identify the installation area of the intelligent gateway, the configuration file downloaded by the intelligent gateway through the interface further comprises a config file, the config file comprises a MAC address base of the intelligent gateway in the area and an upgrade file downloading address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous. That is, a configuration file is sequentially downloaded from the CDN network, and a MAC _ config file is added to the configuration file, and MAC address libraries of all intelligent gateways in the installation area are added to the MAC _ config file, MAC addresses in the MAC address libraries are sorted by small and large, and the MAC addresses are separated by a fixed separator, such as 08674E00001234, 08674E0005678, 08674E0000ABCD, 08674E000 BCDE.
When the installation area of the intelligent gateway is identified, the intelligent gateway analyzes the downloaded configuration file to obtain a config file in the configuration file, and searches whether an MAC address matched with the MAC of the intelligent gateway exists in an MAC address library in the config file, namely, searches whether the MAC address of the intelligent gateway exists in the MAC address library in the config file, if the MAC address of the intelligent gateway exists in the MAC address library, the intelligent gateway and the intelligent gateway with each MAC address in the config file are positioned in the same installation area; if the MAC address of the intelligent gateway does not exist in the MAC address library, the intelligent gateway and the intelligent gateway of each MAC address in the config file are located in different installation areas, the upgrade is quitted at the moment, the configuration file needs to be downloaded from the CDN again, and the installation areas are identified again.
Since each MAC address in the configuration file is a character string, the field of each MAC character string is fixed, and the MAC address can be represented in a numerical manner. Each MAC character string is in a 16-system form, and each MAC character string can be converted into a numerical value through the 16-system form, namely, each MAC address in a MAC address library contained in a configuration file is converted into a MAC numerical value through the character string.
After each MAC address in the MAC address pool is converted to a MAC value, the converted MAC values are sorted by size and size, and the values corresponding to each MAC address are separated by a fixed separator, e.g., 23653818799924, 2365384518817400, etc.
And after converting each MAC address from a character string into a shaping numerical value, searching by a dichotomy by using a comparative shaping method, if a config file contains 5 MAC addresses, converting the 5 MAC addresses from the character string into the numerical values, sequencing the converted numerical values from small values to large values, and searching the sequenced numerical values by adopting the dichotomy, wherein the sequence is 1, 2, 3, 4 and 5.
If the value of the MAC of the intelligent gateway is converted into 2, firstly, the dichotomy is adopted to search for 3 from the sorted 1, 2, 3, 4 and 5, and then the dichotomy is continuously adopted to search for 2 from the 1, 2 and 3, so that the MAC address matched with the MAC of the intelligent gateway exists in the MAC address library.
When the MAC of the intelligent gateway is converted into the value of 6, the dichotomy is adopted to search for 3 from the sorted 1, 2, 3, 4 and 5, the dichotomy is continuously adopted to search for 2 from the 1, 2 and 3, and then the dichotomy is continuously adopted to search for 1 from the 1 and 2, so that the value 6 corresponding to the MAC of the intelligent gateway is not searched after the sorted value is searched by adopting the dichotomy, and the MAC address matched with the MAC of the intelligent gateway does not exist in the MAC address library.
If the MAC address matched with the MAC of the intelligent gateway is not found from the MAC address library in the config file, the matching of the MAC address is failed, the MA C of the intelligent gateway and the MAC address in the configuration file are in different installation areas, and the upgrading of the intelligent gateway is quitted.
If the MAC address matched with the MAC of the intelligent gateway is found from the MAC address library in the config file, the MAC address is successfully matched, the MAC of the intelligent gateway and the MAC address in the configuration file are in the same installation area, and the intelligent gateway is upgraded through the configuration file.
And when the MAC address is successfully matched, the CPU acquires an upgrading file downloading address IMG _ URL corresponding to the matched MAC address from the analyzed configuration file, acquires an upgrading file IMG _ TAR according to the downloading address IMG _ URL, and carries out version upgrading on the intelligent gateway through the upgrading file IMG _ TAR.
In some embodiments, when the intelligent gateway downloads the upgrade file IMG _ TAR according to the download address IMG _ URL, the configuration file MAC _ CFG may be deleted from the configuration file first because the upgrade file is large and the occupied field is large, and then the upgrade file IMG _ TAR is downloaded according to the download address IMG _ URL.
When the server uploads the intelligent gateway upgrading file to the CDN, the server calculates upgrading data of the upgrading file through an algorithm to obtain an MD5 configuration file, and then uploads the upgrading file and the MD5 configuration file to the CDN together.
In order to verify that the upgrade file IMG _ TAR downloaded by the intelligent gateway is the same as the upgrade data uploaded by the server, after the intelligent gateway downloads the upgrade file IMG _ TAR from the CDN network, the downloaded upgrade file IMG _ TAR and the MD5 configuration file are calculated through the same algorithm, namely, the MD5 configuration file of the upgrade file IMG _ TAR is verified.
If the verification of the MD5 configuration file of the upgrade file IMG _ TAR is successful, it indicates that the upgrade file IMG _ TAR downloaded by the intelligent gateway is the same as the upgrade data in the upgrade file uploaded by the server, and the intelligent gateway can upgrade the intelligent gateway according to the downloaded upgrade file IMG _ TAR.
If the MD5 configuration file of the upgrade file IMG _ TAR is not successfully verified, the fact that the upgrade data in the upgrade file IMG _ TAR downloaded by the intelligent gateway is different from the upgrade data in the upgrade file uploaded by the server is indicated, so that the intelligent gateway exits the upgrade, and the intelligent gateway downloads the configuration file from the CDN network again.
The intelligent gateway comprises an interface and a CPU (central processing unit) electrically connected with the interface, wherein the interface is used for receiving a downloaded configuration file, namely the intelligent gateway sends an upgrading request to a CDN (content delivery network) through the interface so as to download the configuration file from the CDN, and the configuration file comprises an MAC (media access control) address library of the intelligent gateway in a region and an upgrading file downloading address corresponding to an MAC address, so that the intelligent gateway receives the MAC address library containing all the MAC addresses of the intelligent gateway in an installation region so as to identify the installation region of the intelligent gateway; the MAC addresses in the MAC address library are discontinuous, and when the intelligent gateways of the installation area are upgraded, the MAC addresses of all the intelligent gateways need to be matched and identified, so that the intelligent gateways of the installation area can be upgraded simultaneously; after receiving the downloaded configuration file, the intelligent gateway searches whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in an MAC address library, namely, whether the MAC address of the intelligent gateway to be upgraded belongs to the installation region is checked; if the matched MAC address exists in the MAC address library, the intelligent gateway to be upgraded belongs to the installation region, the upgrade file is downloaded according to the download address corresponding to the matched MAC address, and after the upgrade file is successfully verified, the intelligent gateway is upgraded according to the upgrade file. That is, the configuration file only contains the download address of the upgrade file, and the intelligent gateway downloads the upgrade file from the CDN network according to the download address without the need for the server to provide an upgrade package, which can save server effort and traffic.
The positioning algorithm does not depend on auxiliary algorithms such as protocols and sensors in a network topology angle, and accurately positions the space where the user is located. The structure is optimized, the server is miniaturized, the server side is accurately and simply calculated, the cost of components is saved, the overstaffed server overhead is simplified, the hardware cost and the maintenance cost of the server are saved, and the network flow cost of the server outlet is saved.
Based on the intelligent gateway described in the above embodiment, the embodiment of the present application further provides a region upgrade control method for an intelligent gateway, the method applies a distributed algorithm to the intelligent gateway, the positioning algorithm does not depend on auxiliary algorithms such as protocols and sensors in a network topology angle, the space where the user is located is accurately positioned, the server is miniaturized, the server side is refined and simplified in calculation, and terminal optimization is achieved.
Fig. 3 is a first flowchart of a method for controlling area upgrade of an intelligent gateway according to an embodiment of the present application. As shown in fig. 3, a method for controlling area upgrade of an intelligent gateway provided in an embodiment of the present application includes:
s100: and receiving a downloaded configuration file, wherein the configuration file comprises an MAC address base of the intelligent gateway in the region and an upgrade file download address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous.
The CDN network may periodically send configuration files to each installation area, and after the intelligent gateway receives the downloaded configuration files, the MAC address base included in the configuration files received by the intelligent gateway may be an intelligent gateway MAC address of another installation area, so that the installation area needs to be confirmed according to the MAC address of the intelligent gateway and the MAC address base included in the configuration files.
In order to identify the installation area of the intelligent gateway, the configuration file downloaded by the intelligent gateway through the interface further comprises a config file, the config file comprises a MAC address base of the intelligent gateway in the area and an upgrade file downloading address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous. The method comprises the steps that configuration files are downloaded from a CDN network in order, MAC _ config files are added in the configuration files, MAC address libraries of all intelligent gateways in an installation area are added in the MAC _ config files, MAC addresses in the MAC address libraries are sorted by size and size, and the MAC addresses are separated by fixed separators.
Fig. 4 is a second flowchart of a method for controlling area upgrade of an intelligent gateway according to an embodiment of the present application. As shown in fig. 4, when the address matching is performed between the MAC address library in the config file and the MAC of the intelligent gateway, the version number of the identifier in the configuration file needs to be obtained through parsing, and whether the parsed version number is consistent with the current MAC version number of the intelligent gateway is determined to determine whether the intelligent gateway needs to be upgraded.
The specific method for determining whether the intelligent gateway needs to be upgraded according to the version number obtained by analysis comprises the following steps:
s110: and analyzing the configuration file.
S120: and acquiring the version number of the configuration file in the configuration file.
S130: and judging whether the version number is consistent with the current MAC version number of the intelligent gateway or not.
S140: and if the version number is not consistent with the current MAC version number of the intelligent gateway, downloading a new configuration file according to the URL corresponding to the version number, and updating the MAC version number of the intelligent gateway.
After the intelligent gateway receives the downloaded configuration file through the interface, because the configuration file comprises a URL (uniform resource locator) for identifying the configuration file MAC _ CFG and a version number for identifying the configuration file MAC _ CFG, and the version number corresponds to the URL, the configuration file is analyzed, the version number recorded by the configuration file is obtained, the version number is compared with the current MAC version number of the intelligent gateway (the MAC version number stored in an intelligent gateway database), whether the analyzed version number is consistent with the current MAC version number of the intelligent gateway or not is judged, and whether the intelligent gateway needs to be upgraded or not is confirmed.
If the version number obtained by the analysis is consistent with the current MAC version number of the intelligent gateway, the current MAC version number of the intelligent gateway is the latest version number, and S200 is executed.
If the version number obtained by the analysis is not consistent with the current MAC version number of the intelligent gateway, the server updates the version number of the intelligent gateway in the installation area, the intelligent gateway needs to be upgraded, the intelligent gateway downloads a new configuration file MAC _ CFG according to the URL of the MAC _ config _ URL identification configuration file MAC _ CFG in the configuration file, and S200 is executed.
S200: and searching whether the MAC address matched with the intelligent gateway MAC exists in the MAC address library.
After each MAC address in the MAC address library is converted into a MAC value, the converted MAC values are sorted according to the size, and the values corresponding to each MAC address are separated by a fixed separator. And then, performing dichotomy search by using a comparative shaping method to perform address matching after the version information is successfully matched, wherein the address matching is successful if the intelligent gateway MAC is contained in an MAC address base of the configuration file.
S300: and if the MAC address matched with the intelligent gateway MAC exists in the MAC address library, downloading the upgrade file according to the download address corresponding to the MAC address.
And when the MAC address is successfully matched, the CPU acquires an upgrading file downloading address IMG _ URL corresponding to the matched MAC address from the analyzed configuration file, acquires an upgrading file IMG _ TAR according to the downloading address IMG _ URL, and carries out version upgrading on the intelligent gateway through the upgrading file IMG _ TAR.
S400: and after the upgrade file is successfully verified, upgrading the intelligent gateway.
When the server uploads the intelligent gateway upgrading file to the CDN, the server calculates upgrading data of the upgrading file through an algorithm to obtain an MD5 configuration file, and then uploads the upgrading file and the MD5 configuration file to the CDN together.
In order to verify that the upgrade file IMG _ TAR downloaded by the intelligent gateway is the same as the upgrade data uploaded by the server, after the intelligent gateway downloads the upgrade file IMG _ TAR from the CDN network, the downloaded upgrade file IMG _ TAR and the MD5 configuration file are calculated through the same algorithm, namely, the MD5 configuration file of the upgrade file IMG _ TAR is verified.
If the verification of the MD5 configuration file of the upgrade file IMG _ TAR is successful, it indicates that the upgrade file IMG _ TAR downloaded by the intelligent gateway is the same as the upgrade data in the upgrade file uploaded by the server, and the intelligent gateway can upgrade the intelligent gateway according to the downloaded upgrade file IMG _ TAR.
According to the area upgrading control method of the intelligent gateway, a distributed algorithm is applied to an access network terminal (intelligent gateway), a network topology structure is not relied on, a centralized server is not relied on, area identification calculation is distributed to a cloud end, and calculation power and flow of the server are saved. The method comprises the steps of technology centralized configuration method, area query distributed algorithm, server network optimization, network flow control optimization, equipment algorithm optimization and equipment memory space optimization.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (10)

1. An intelligent gateway, comprising:
the interface is configured to receive a downloaded configuration file, wherein the configuration file comprises an MAC address base of the intelligent gateway in the region and an upgrade file downloading address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous;
the CPU is configured to search whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in the MAC address library; if the matched MAC address exists in the MAC address library, downloading an upgrading file according to a downloading address corresponding to the MAC address, and upgrading the intelligent gateway after the upgrading file is successfully verified.
2. The intelligent gateway of claim 1, wherein the configuration file further comprises a URL identifying the configuration file and a version number identifying the configuration file, the version number corresponding to the URL.
3. The intelligent gateway of claim 2, wherein the CPU is further configured to parse the configuration file, obtain a version number of the configuration file, and determine whether the version number is consistent with a current MAC version number of the intelligent gateway; and if the version number is not consistent with the current MAC version number, downloading a new configuration file according to the URL corresponding to the version number, and updating the MAC version number of the intelligent gateway.
4. The intelligent gateway of claim 1, wherein the MAC addresses in the MAC address bank are ordered by small and large, adjacent MAC addresses being separated by a separator.
5. The intelligent gateway of claim 4, wherein when looking up from the MAC address library whether a MAC address matching with the intelligent gateway MAC to be upgraded exists, the CPU is further configured to convert each MAC address in the MAC address library from a character string to a MAC value, and sort the converted MAC values;
and converting the intelligent gateway MAC into an MAC value, and searching whether the MAC value exists in the sequenced MAC values through a dichotomy.
6. The intelligent gateway of claim 5, wherein when the MAC value exists in the sorted MAC values, the CPU is further configured to obtain an upgrade file download address corresponding to a matching MAC address in the configuration file.
7. The intelligent gateway of claim 6, wherein after obtaining the download address of the upgrade file, the CPU is further configured to delete the configuration file, download the upgrade file according to the download address, and verify the MD5 configuration file in the upgrade file.
8. The intelligent gateway of claim 7, wherein when the MD5 configuration file is verified, the CPU is further configured to parse the MD5 configuration file through an algorithm to obtain upgrade data corresponding to the MD5 configuration file, and verify the upgrade file according to the upgrade data.
9. A regional upgrade control method for an intelligent gateway is characterized by comprising the following steps:
receiving a downloaded configuration file, wherein the configuration file comprises an MAC address base of an intelligent gateway in a region and an upgrade file download address corresponding to the MAC address, and the MAC address in the MAC address base is discontinuous;
searching whether an MAC address matched with the MAC of the intelligent gateway to be upgraded exists in the MAC address library;
if the matched MAC address exists in the MAC address library, downloading an upgrade file according to a download address corresponding to the MAC address;
and after the upgrade file is successfully checked, upgrading the intelligent gateway.
10. The method for controlling regional upgrade of an intelligent gateway according to claim 9, further comprising, after receiving the downloaded configuration file:
analyzing the configuration file;
acquiring the version number of the configuration file in the configuration file;
judging whether the version number is consistent with the current MAC version number of the intelligent gateway;
if the version number is consistent with the current MAC version number of the intelligent gateway, searching whether an MAC address matched with the MAC of the intelligent gateway exists in the MAC address library;
and if the version number is not consistent with the current MAC version number of the intelligent gateway, downloading a new configuration file according to the URL corresponding to the version number, and updating the MAC version number of the intelligent gateway.
CN202210612943.4A 2022-05-31 2022-05-31 Intelligent gateway and area upgrading control method thereof Pending CN115022170A (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN202210612943.4A CN115022170A (en) 2022-05-31 2022-05-31 Intelligent gateway and area upgrading control method thereof
CN202211132006.5A CN115348173A (en) 2022-05-31 2022-05-31 Area upgrading control method for household intelligent gateway

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210612943.4A CN115022170A (en) 2022-05-31 2022-05-31 Intelligent gateway and area upgrading control method thereof

Related Child Applications (1)

Application Number Title Priority Date Filing Date
CN202211132006.5A Division CN115348173A (en) 2022-05-31 2022-05-31 Area upgrading control method for household intelligent gateway

Publications (1)

Publication Number Publication Date
CN115022170A true CN115022170A (en) 2022-09-06

Family

ID=83070668

Family Applications (2)

Application Number Title Priority Date Filing Date
CN202210612943.4A Pending CN115022170A (en) 2022-05-31 2022-05-31 Intelligent gateway and area upgrading control method thereof
CN202211132006.5A Pending CN115348173A (en) 2022-05-31 2022-05-31 Area upgrading control method for household intelligent gateway

Family Applications After (1)

Application Number Title Priority Date Filing Date
CN202211132006.5A Pending CN115348173A (en) 2022-05-31 2022-05-31 Area upgrading control method for household intelligent gateway

Country Status (1)

Country Link
CN (2) CN115022170A (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116360809B (en) * 2023-05-31 2023-08-22 深圳市微克科技有限公司 Remote firmware upgrading method, system and medium for embedded intelligent terminal

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040218549A1 (en) * 2003-04-14 2004-11-04 Benq Corporation Method and system for network device upgrade
US20080134165A1 (en) * 2006-12-01 2008-06-05 Lori Anderson Methods and apparatus for software provisioning of a network device
CN103269375A (en) * 2013-05-30 2013-08-28 厦门亿联网络技术股份有限公司 Method for updating client-side configuration information automatically
CN105933150A (en) * 2016-04-20 2016-09-07 努比亚技术有限公司 OTA upgrade method, device and system
WO2017190547A1 (en) * 2016-05-06 2017-11-09 中兴通讯股份有限公司 Method for upgrading apparatus, device, and configuration point
CN109347931A (en) * 2018-09-28 2019-02-15 四川长虹电器股份有限公司 A kind of OTA upgrading method for down loading based on layering interaction design
CN111147314A (en) * 2019-12-30 2020-05-12 深圳市丰润达科技有限公司 Switch upgrading method, device and storage medium
CN111433773A (en) * 2017-11-30 2020-07-17 Abb瑞士股份有限公司 Updating gateways in substations
CN113805933A (en) * 2020-06-12 2021-12-17 深圳市中兴微电子技术有限公司 Set top box system upgrading method and device, set top box, system and storage medium
CN114301990A (en) * 2021-12-29 2022-04-08 中国电信股份有限公司 Node scheduling method, device and storage medium based on content distribution network

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20110032723A (en) * 2009-09-24 2011-03-30 엘지전자 주식회사 Software downloading method
JP6613690B2 (en) * 2015-07-31 2019-12-04 富士通株式会社 Network device setting method, information processing device, and BIOS program
CN106375122A (en) * 2016-08-31 2017-02-01 上海澳润信息科技有限公司 Intelligent gateway strategy upgrading method based on LAMP (Linux+Apache+Mysql/MariaDB+Perl/PHP/Python)
CN106533813B (en) * 2016-12-30 2020-01-14 深圳创维-Rgb电子有限公司 Method for remotely controlling system upgrading of intelligent equipment
CN109561118B (en) * 2017-09-26 2020-12-25 比亚迪股份有限公司 Software upgrading method, device, system, storage medium, electronic equipment and vehicle
CN108471361B (en) * 2018-03-28 2021-08-24 新华三技术有限公司 Version upgrading method and device
CN114461239B (en) * 2021-06-30 2023-11-24 荣耀终端有限公司 Software upgrading system and software upgrading method

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040218549A1 (en) * 2003-04-14 2004-11-04 Benq Corporation Method and system for network device upgrade
US20080134165A1 (en) * 2006-12-01 2008-06-05 Lori Anderson Methods and apparatus for software provisioning of a network device
CN103269375A (en) * 2013-05-30 2013-08-28 厦门亿联网络技术股份有限公司 Method for updating client-side configuration information automatically
CN105933150A (en) * 2016-04-20 2016-09-07 努比亚技术有限公司 OTA upgrade method, device and system
WO2017190547A1 (en) * 2016-05-06 2017-11-09 中兴通讯股份有限公司 Method for upgrading apparatus, device, and configuration point
CN111433773A (en) * 2017-11-30 2020-07-17 Abb瑞士股份有限公司 Updating gateways in substations
CN109347931A (en) * 2018-09-28 2019-02-15 四川长虹电器股份有限公司 A kind of OTA upgrading method for down loading based on layering interaction design
CN111147314A (en) * 2019-12-30 2020-05-12 深圳市丰润达科技有限公司 Switch upgrading method, device and storage medium
CN113805933A (en) * 2020-06-12 2021-12-17 深圳市中兴微电子技术有限公司 Set top box system upgrading method and device, set top box, system and storage medium
CN114301990A (en) * 2021-12-29 2022-04-08 中国电信股份有限公司 Node scheduling method, device and storage medium based on content distribution network

Also Published As

Publication number Publication date
CN115348173A (en) 2022-11-15

Similar Documents

Publication Publication Date Title
CN108702397B (en) Method and system for acquiring and collecting local DNS (Domain name Server) server of client
CN109194617B (en) Automatic parsing and packaging method and device for XML (extensive markup language) message
CN102025595A (en) Flow optimization method and system
US20120314608A1 (en) Information and communication processing system, method, and network node
CN111404833B (en) Data stream type recognition model updating method and related equipment
KR20140051447A (en) Cloud computing enhanced gateway for communication networks
CN109729183B (en) Request processing method, device, equipment and storage medium
CN115022170A (en) Intelligent gateway and area upgrading control method thereof
EP4095768A1 (en) Application recognition model updating method and apparatus, and storage medium
WO2019134240A1 (en) Method for identifying multiple packets, method for identifying data packet, and traffic guiding method
CN102918511A (en) Relay device, relay system, relay method, program, and storage medium capable of reading from computer storing said program
CN112783541A (en) Equipment upgrading method and device and server
CN114390060A (en) Method for distributing edge computing network and storage medium
CN114090033A (en) OTA (over the air) upgrading method and device, electronic equipment and readable medium
CN112052023A (en) Intelligent terminal upgrading strategy management method
CN111405018A (en) File transmission method and device, electronic equipment and storage medium
CN111277628A (en) Server configuration method and device and service server
WO2020010906A1 (en) Method and device for operating system (os) batch installation, and network device
CN110674427A (en) Method, device, equipment and storage medium for responding to webpage access request
CN113300879A (en) Method, system and computer readable medium for zero configuration opening of equipment
CN109922083B (en) Network protocol flow control system
CN114650281B (en) File downloading method, device, equipment and storage medium based on complex network
CN114911515A (en) Configuration management method, device, equipment and medium
JP5925287B1 (en) Information processing apparatus, method, and program
CN112306518A (en) Protocol updating method and device and electronic equipment

Legal Events

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