CN105915362A - Method for controlling system upgrading according to version information and device thereof - Google Patents
Method for controlling system upgrading according to version information and device thereof Download PDFInfo
- Publication number
- CN105915362A CN105915362A CN201510759566.7A CN201510759566A CN105915362A CN 105915362 A CN105915362 A CN 105915362A CN 201510759566 A CN201510759566 A CN 201510759566A CN 105915362 A CN105915362 A CN 105915362A
- Authority
- CN
- China
- Prior art keywords
- field
- client
- version
- latest
- upgrade
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 32
- 230000008569 process Effects 0.000 description 4
- 230000008901 benefit Effects 0.000 description 3
- 238000010586 diagram Methods 0.000 description 3
- 230000007547 defect Effects 0.000 description 1
- 238000009434 installation Methods 0.000 description 1
- 238000012986 modification Methods 0.000 description 1
- 230000004048 modification Effects 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/0813—Configuration setting characterised by the conditions triggering a change of settings
- H04L41/082—Configuration setting characterised by the conditions triggering a change of settings the condition being updates or upgrades of network functionality
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/085—Retrieval of network configuration; Tracking network configuration history
- H04L41/0859—Retrieval of network configuration; Tracking network configuration history by keeping history of different configuration generations or by rolling back to previous configuration versions
- H04L41/0863—Retrieval of network configuration; Tracking network configuration history by keeping history of different configuration generations or by rolling back to previous configuration versions by rolling back to previous configuration versions
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L2101/00—Indexing scheme associated with group H04L61/00
- H04L2101/60—Types of network addresses
- H04L2101/618—Details of network addresses
- H04L2101/622—Layer-2 addresses, e.g. medium access control [MAC] addresses
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Information Transfer Between Computers (AREA)
- Stored Programmes (AREA)
Abstract
本发明公开了一种根据版本信息控制系统升级的方法和装置,其中,该方法包括:获取客户端上传的系统升级请求;根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,最新系统版本字段包括最新系统版本号,且最新系统版本字段的格式与客户端版本字段的格式相一致;判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号高于客户端系统版本号时,将与最新系统版本字段相对应的系统升级包发送至客户端,指示客户端进行系统升级。该方法扩展了版本字段,版本字段支持增加新的平台或机型等,可扩展性强,通过判断版本号的大小即可确定是否需要升级,判断逻辑简单。
The invention discloses a method and device for controlling system upgrade based on version information, wherein the method includes: obtaining a system upgrade request uploaded by a client; Consistent latest system version field, the latest system version field includes the latest system version number, and the format of the latest system version field is consistent with the format of the client version field; to determine whether the latest system version number is higher than the client system version number, in the latest When the system version number is higher than the client system version number, a system upgrade package corresponding to the latest system version field is sent to the client to instruct the client to perform system upgrade. This method expands the version field, which supports the addition of new platforms or models, etc., and has strong scalability. It can be determined whether an upgrade is required by judging the size of the version number, and the judgment logic is simple.
Description
技术领域technical field
本发明涉及系统升级技术领域,具体地,涉及一种根据版本信息控制系统升级的方法及装置。The invention relates to the technical field of system upgrades, in particular to a method and device for controlling system upgrades based on version information.
背景技术Background technique
OTA:英文全称是Over-the-Air Technology,即空间下载技术。OTA升级是Android系统的标准升级方式,支持通过有线网或无线网进行手动或自动下载OTA升级包,并实现自动安装升级。OTA: The full English name is Over-the-Air Technology, that is, space download technology. OTA upgrade is the standard upgrade method of Android system, which supports manual or automatic download of OTA upgrade package through wired network or wireless network, and realizes automatic installation and upgrade.
版本号:是一种唯一标识软件系统版本的信息,常用于版本比较。Version number: It is a kind of information that uniquely identifies the version of the software system, and is often used for version comparison.
Android系统的版本号在OTA升级中具有非常重要的作用,其直接作用就在于版本的大小比较,从而判断是否要升级。目前业内OTA升级系统,其系统版本号的选型上都相对比较简单,适用范围有限,可扩展性很低,不能满足Android系统日益发展的多业务多渠道需求。The version number of the Android system plays a very important role in the OTA upgrade, and its direct function is to compare the size of the version, so as to judge whether to upgrade. At present, the OTA upgrade system in the industry is relatively simple in the selection of the system version number, has a limited scope of application, and has low scalability, which cannot meet the growing multi-service and multi-channel needs of the Android system.
发明内容Contents of the invention
本发明是为了克服现有技术中OAT升级系统的版本号扩展性低的缺陷,根据本发明的一个方面,提出一种根据版本信息控制系统升级的方法。The purpose of the present invention is to overcome the defect of low scalability of the version number of the OAT upgrade system in the prior art. According to one aspect of the present invention, a method for controlling system upgrade based on version information is proposed.
本发明实施例提供的一种根据版本信息控制系统升级的方法,包括:A method for upgrading a system based on version information control provided by an embodiment of the present invention includes:
获取客户端上传的系统升级请求,系统升级请求包括客户端版本字段,客户端版本字段包括平台机型字段、地域字段和客户端系统版本号;Obtain the system upgrade request uploaded by the client. The system upgrade request includes a client version field, and the client version field includes a platform model field, a region field, and a client system version number;
根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,最新系统版本字段包括最新系统版本号,且最新系统版本字段的格式与客户端版本字段的格式相一致;Determine the latest system version field consistent with the platform model field and region field according to the platform model field and region field. The latest system version field includes the latest system version number, and the format of the latest system version field is the same as that of the client version field. consistent;
判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号高于客户端系统版本号时,将与最新系统版本字段相对应的系统升级包发送至客户端,指示客户端进行系统升级。Determine whether the latest system version number is higher than the client system version number, and when the latest system version number is higher than the client system version number, send the system upgrade package corresponding to the latest system version field to the client, instructing the client to perform system upgrade.
在上述技术方案中,客户端版本字段还包括编译日期和编译次数;In the above technical solution, the client version field also includes compilation date and compilation times;
若最新系统版本号与客户端系统版本号相同,则在最新系统版本字段中的编译日期高于客户端版本字段中的编译日期时,将与最新系统版本字段相对应的系统升级包发送至客户端;If the latest system version number is the same as the client system version number, when the compilation date in the latest system version field is higher than the compilation date in the client version field, send the system upgrade package corresponding to the latest system version field to the client end;
若最新系统版本字段中的编译日期与客户端版本字段中的编译日期相同,则在最新系统版本字段中的编译次数大于客户端版本字段中的编译次数时,将与最新系统版本字段相对应的系统升级包发送至客户端。If the compilation date in the latest system version field is the same as the compilation date in the client version field, when the number of compilations in the latest system version field is greater than the number of compilations in the client version field, the corresponding The system upgrade package is sent to the client.
在上述技术方案中,客户端版本字段还包括版本类型;In the above technical solution, the client version field also includes a version type;
根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,具体包括:Determine the latest system version field consistent with the platform model field and region field according to the platform model field and region field, including:
根据平台机型字段、地域字段和版本类型确定与平台机型字段、地域字段和版本类型相一致的最新系统版本字段。Determine the latest system version field consistent with the platform model field, region field and version type according to the platform model field, region field and version type.
在上述技术方案中,系统升级请求还包括客户端MAC地址;In the above technical solution, the system upgrade request also includes the MAC address of the client;
在获取客户端上传的系统升级请求步骤之后,该方法还包括:After the step of obtaining the system upgrade request uploaded by the client, the method further includes:
判断客户端MAC地址是否与系统存储的MAC地址相匹配,在客户端MAC地址与系统存储的MAC地址相匹配时,继续确定最新系统版本字段步骤。Determine whether the MAC address of the client matches the MAC address stored in the system, and when the MAC address of the client matches the MAC address stored in the system, proceed to the step of determining the latest system version field.
在上述技术方案中,系统升级包中包括升级标识;In the above technical solution, the system upgrade package includes an upgrade mark;
在升级标识为支持升级时,指示客户端进行系统升级。When the upgrade is identified as supporting the upgrade, instruct the client to upgrade the system.
基于同样的发明构思,本发明实施例还提供一种根据版本信息控制系统升级的装置,包括:Based on the same inventive concept, an embodiment of the present invention also provides a device for controlling system upgrades based on version information, including:
获取模块,用于获取客户端上传的系统升级请求,系统升级请求包括客户端版本字段,客户端版本字段包括平台机型字段、地域字段和客户端系统版本号;The obtaining module is used to obtain the system upgrade request uploaded by the client. The system upgrade request includes a client version field, and the client version field includes a platform model field, a region field and a client system version number;
确定模块,用于根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,最新系统版本字段包括最新系统版本号,且最新系统版本字段的格式与客户端版本字段的格式相一致;The determining module is used to determine the latest system version field that is consistent with the platform model field and the region field according to the platform model field and the region field. The latest system version field includes the latest system version number, and the format of the latest system version field is the same as that of the client The format of the version field is consistent;
处理模块,用于判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号高于客户端系统版本号时,将与最新系统版本字段相对应的系统升级包发送至客户端,指示客户端进行系统升级。The processing module is used to judge whether the latest system version number is higher than the client system version number, and when the latest system version number is higher than the client system version number, send the system upgrade package corresponding to the latest system version field to the client, Instruct the client to perform a system upgrade.
在上述技术方案中,客户端版本字段还包括编译日期和编译次数;该装置还包括:In the above technical solution, the client version field also includes compilation date and compilation times; the device also includes:
第一判断模块,用于若最新系统版本号与客户端系统版本号相同,则在最新系统版本字段中的编译日期高于客户端版本字段中的编译日期时,将与最新系统版本字段相对应的系统升级包发送至客户端;The first judging module is used for if the latest system version number is the same as the client system version number, when the compilation date in the latest system version field is higher than the compilation date in the client version field, it will correspond to the latest system version field The system upgrade package is sent to the client;
第二判断模块,用于若最新系统版本字段中的编译日期与客户端版本字段中的编译日期相同,则在最新系统版本字段中的编译次数大于客户端版本字段中的编译次数时,将与最新系统版本字段相对应的系统升级包发送至客户端。The second judging module is used for if the compilation date in the latest system version field is the same as the compilation date in the client version field, then when the compilation times in the latest system version field is greater than the compilation times in the client version field, it will be compared with The system upgrade package corresponding to the latest system version field is sent to the client.
在上述技术方案中,客户端版本字段还包括:版本类型;In the above technical solution, the client version field also includes: version type;
确定模块具体用于:根据平台机型字段、地域字段和版本类型确定与平台机型字段、地域字段和版本类型相一致的最新系统版本字段。The determination module is specifically used to: determine the latest system version field consistent with the platform model field, region field and version type according to the platform model field, region field and version type.
在上述技术方案中,系统升级请求还包括客户端MAC地址;该装置还包括匹配模块;In the above technical solution, the system upgrade request also includes the MAC address of the client; the device also includes a matching module;
在获取模块获取客户端上传的系统升级请求之后,匹配模块用于:After the obtaining module obtains the system upgrade request uploaded by the client, the matching module is used to:
判断客户端MAC地址是否与系统存储的MAC地址相匹配,在客户端MAC地址与系统存储的MAC地址相匹配时,继续确定最新系统版本字段步骤。Determine whether the MAC address of the client matches the MAC address stored in the system, and when the MAC address of the client matches the MAC address stored in the system, proceed to the step of determining the latest system version field.
在上述技术方案中,系统升级包中包括升级标识;在升级标识为支持升级时,处理模块指示客户端进行系统升级。In the above technical solution, the system upgrade package includes an upgrade identifier; when the upgrade identifier indicates that the upgrade is supported, the processing module instructs the client to upgrade the system.
本发明实施例提供的一种根据版本信息控制系统升级的方法及装置,重新扩展了版本字段,根据版本字段中的平台机型字段和地域字段等确定服务器端的最新系统的版本字段,进而通过比较即可判断客户端是否需要升级。该版本字段支持增加新的平台或机型等,可扩展性强,通过判断版本号的大小即可确定是否需要升级,判断逻辑简单。通过判断MAC地址可以剔除硬件不符合升级要求的客户端;通过升级标识服务器端可以有效控制客户端系统升级的情况。The embodiment of the present invention provides a method and device for controlling system upgrades based on version information. The version field is re-extended, and the version field of the latest system on the server side is determined according to the platform model field and region field in the version field, and then by comparing You can determine whether the client needs to be upgraded. The version field supports the addition of new platforms or models, etc., and is highly scalable. It can be determined whether an upgrade is required by judging the size of the version number, and the judgment logic is simple. Clients whose hardware does not meet the upgrade requirements can be eliminated by judging the MAC address; the upgrade of the client system can be effectively controlled by identifying the server.
本发明的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本发明而了解。本发明的目的和其他优点可通过在所写的说明书、权利要求书、以及附图中所特别指出的结构来实现和获得。Additional features and advantages of the invention will be set forth in the description which follows, and in part will be apparent from the description, or may be learned by practice of the invention. The objectives and other advantages of the invention may be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
下面通过附图和实施例,对本发明的技术方案做进一步的详细描述。The technical solutions of the present invention will be described in further detail below with reference to the accompanying drawings and embodiments.
附图说明Description of drawings
附图用来提供对本发明的进一步理解,并且构成说明书的一部分,与本发明的实施例一起用于解释本发明,并不构成对本发明的限制。在附图中:The accompanying drawings are used to provide a further understanding of the present invention, and constitute a part of the description, and are used together with the embodiments of the present invention to explain the present invention, and do not constitute a limitation to the present invention. In the attached picture:
图1为本发明实施例中根据版本信息控制系统升级的方法流程图;Fig. 1 is a flow chart of a method for controlling system upgrades based on version information in an embodiment of the present invention;
图2为实施例一中根据版本信息控制系统升级的方法流程图;Fig. 2 is a flow chart of a method for controlling system upgrades based on version information in Embodiment 1;
图3为本发明实施例中根据版本信息控制系统升级装置的第一结构图;FIG. 3 is a first structural diagram of a device for upgrading a system based on version information control in an embodiment of the present invention;
图4为本发明实施例中根据版本信息控制系统升级装置的第二结构图;FIG. 4 is a second structural diagram of a device for upgrading a system based on version information control in an embodiment of the present invention;
图5为本发明实施例中根据版本信息控制系统升级装置的第三结构图。FIG. 5 is a third structural diagram of an apparatus for upgrading a system based on version information control in an embodiment of the present invention.
具体实施方式detailed description
下面结合附图,对本发明的具体实施方式进行详细描述,但应当理解本发明的保护范围并不受具体实施方式的限制。The specific embodiments of the present invention will be described in detail below in conjunction with the accompanying drawings, but it should be understood that the protection scope of the present invention is not limited by the specific embodiments.
根据本发明实施例,提供一种根据版本信息控制系统升级的方法,参见图1所示,该方法包括步骤101-103:According to an embodiment of the present invention, a method for upgrading a system based on version information control is provided, as shown in FIG. 1 , the method includes steps 101-103:
步骤101:获取客户端上传的系统升级请求,系统升级请求包括客户端版本字段,客户端版本字段包括平台机型字段、地域字段和客户端系统版本号。Step 101: Obtain a system upgrade request uploaded by the client. The system upgrade request includes a client version field, and the client version field includes a platform model field, a region field, and a client system version number.
本发明实施例中,客户端(例如手机、电视机或机顶盒等)需要系统升级是,则向服务器发送包含客户端版本字段的系统升级请求。具体的,本发明实施例中,扩展了传统意义的版本号,将版本号扩展为版本字段,该版本字段具体可以包括平台机型字段、地域字段和客户端系统版本号。In the embodiment of the present invention, when the client (such as a mobile phone, a TV set or a set-top box, etc.) needs system upgrade, it sends a system upgrade request including the client version field to the server. Specifically, in the embodiment of the present invention, the version number in the traditional sense is extended, and the version number is expanded into a version field, and the version field may specifically include a platform model field, a region field, and a client system version number.
其中,平台机型字段用于表示平台厂商和设备机型。本发明实施例中,以“Vxxxx”格式表示平台机型字段,具体参见表1所示。其中,V表示平台机型字段的起始位,之后的第一位表示平台厂商,第二位表示平台,第三、四位共同表示设备机型。未来如有新的平台厂商、新的平台或新的机型,都可以在此之上进行扩展,不需要变更版本字段的格式。Among them, the platform model field is used to indicate the platform manufacturer and device model. In the embodiment of the present invention, the field of the platform model is represented in the format of "Vxxxx", as shown in Table 1 for details. Among them, V represents the start digit of the platform model field, the first digit after that represents the platform manufacturer, the second digit represents the platform, and the third and fourth digits together represent the device model. In the future, if there are new platform manufacturers, new platforms, or new models, they can all expand on this without changing the format of the version field.
表1Table 1
地域字段用于表示国家地域,同时也可以用来表示版本类型。本发明实施例中,以“Rxxxx”格式表示地域字段,具体参见表2所示。其中,R表示地域字段的起始位,之后的第一、二位表示国家或地域,第三、四位表示设备渠道。未来如有新的国家地域、新的渠道,都可以在此之上进行扩展,不需要变更版本字段的格式。The region field is used to indicate the country and region, and can also be used to indicate the version type. In the embodiment of the present invention, the region field is represented in the "Rxxxx" format, see Table 2 for details. Among them, R represents the start digit of the region field, the first and second digits after that represent the country or region, and the third and fourth digits represent the device channel. If there are new countries and regions and new channels in the future, they can be extended on top of this without changing the format of the version field.
表2Table 2
系统版本号(本发明实施例中,客户端的版本号称为客户端系统版本号)用于表示当前版本的标识号。本发明实施例中,以“Cxxxxxx”格式表示系统版本号,具体参见表3所示。本发明实施例中,将系统版本号分为大版本号和小版本号,其中,C表示系统版本号的起始位,之后的第一、二、三位表示大版本号,第四、五、六位表示小版本号。未来如有新的大小版本号,都可以在此之上进行扩展,不需要变更版本字段的格式。The system version number (in the embodiment of the present invention, the version number of the client is referred to as the client system version number) is used to represent the identification number of the current version. In the embodiment of the present invention, the system version number is represented in the format of "Cxxxxxx", see Table 3 for details. In the embodiment of the present invention, the system version number is divided into a major version number and a minor version number, wherein, C represents the starting digit of the system version number, the first, second and third digits after that represent the major version number, and the fourth and fifth digits represent the major version number. , Six digits represent the minor version number. If there is a new version number in the future, it can be extended on top of this, without changing the format of the version field.
表3table 3
步骤102:根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,最新系统版本字段包括最新系统版本号,且最新系统版本字段的格式与客户端版本字段的格式相一致。Step 102: Determine the latest system version field consistent with the platform model field and region field according to the platform model field and region field, the latest system version field includes the latest system version number, and the format of the latest system version field is the same as that of the client version field format is consistent.
本发明实施例中,服务器端的系统版本字段(即步骤102中的最新系统版本字段)与客户端的系统版本字段(即步骤102中的客户端版本字段)格式相一致,即最新系统版本字段中也包括平台机型字段、地域字段和版本号。本发明实施例中,为了区分服务器与客户端之间的版本号,将服务器段的版本号称为最新系统版本号,即最新系统版本字段包括:平台机型字段、地域字段和最新系统版本号。只有最新系统版本字段的格式与客户端版本字段的格式相一致,二者才能进行比对。In the embodiment of the present invention, the format of the system version field of the server side (i.e. the latest system version field in step 102) is consistent with the format of the client's system version field (i.e. the client version field in step 102), that is, the latest system version field is also Including platform model field, region field and version number. In the embodiment of the present invention, in order to distinguish the version number between the server and the client, the version number of the server section is called the latest system version number, that is, the latest system version field includes: platform model field, region field and the latest system version number. Only when the format of the latest system version field is consistent with that of the client version field can the two be compared.
步骤103:判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号高于客户端系统版本号时,将与最新系统版本字段相对应的系统升级包发送至客户端,指示客户端进行系统升级。Step 103: Determine whether the latest system version number is higher than the client system version number, and when the latest system version number is higher than the client system version number, send the system upgrade package corresponding to the latest system version field to the client, instructing the client system upgrade.
本发明实施例中,重新扩展了版本字段,根据版本字段中的平台机型字段和地域字段确定服务器端的最新系统的版本字段,进而通过比较即可判断客户端是否需要升级。该版本字段支持增加新的平台或机型等,可扩展性强,通过判断版本号的大小即可确定是否需要升级,判断逻辑简单。In the embodiment of the present invention, the version field is re-expanded, and the version field of the latest system on the server side is determined according to the platform model field and the region field in the version field, and then it can be judged whether the client needs to be upgraded through comparison. The version field supports the addition of new platforms or models, etc., and is highly scalable. It can be determined whether an upgrade is required by judging the size of the version number, and the judgment logic is simple.
优选的,客户端版本字段还包括编译日期和/或编译次数。需要说明的是,由于最新系统版本字段的格式与客户端版本字段的格式相一致,则当客户端版本字段还包括编译日期和/或编译次数时,则相应的最新系统版本字段中也包括编译日期和/或编译次数。Preferably, the client version field also includes compilation date and/or compilation times. It should be noted that since the format of the latest system version field is consistent with that of the client version field, when the client version field also includes the compilation date and/or compilation times, the corresponding latest system version field also includes the compilation date and/or compilation count.
具体的,编译日期用于表示系统版本编译的时间。在本发明实施例中,以“Bxxxx”格式表示编译日期,具体参见表4所示。其中,B表示编译日期的起始位,之后的第一、二位表示编译日期的月份,第三、四位表示编译日期的日期。Specifically, the compilation date is used to indicate the time when the system version was compiled. In the embodiment of the present invention, the compilation date is represented in the format of "Bxxxx", see Table 4 for details. Among them, B represents the start digit of the compilation date, the first and second digits after that represent the month of the compilation date, and the third and fourth digits represent the date of the compilation date.
表4Table 4
编译次数用于表示在某一日期下编译系统版本的次数,具体可以为“第一次编译的版本”、“第二次编译的版本”等。同时,客户端版本字段还包括版本类型,版本类型可以分为稳定版和开发版等,未来如有新的版本类型出现,可以在此之上进行扩展,不需要变更版本字段的格式。具体参见表5所示:The number of compilations is used to indicate the number of compilations of the system version on a certain date, which can be specifically "the first compiled version", "the second compiled version" and so on. At the same time, the client version field also includes the version type, which can be divided into stable version and development version, etc. If a new version type appears in the future, it can be extended on top of this without changing the format of the version field. See Table 5 for details:
表5table 5
本发明实施例中,当客户端版本字段还包括编译日期和/或编译次数时,若最新系统版本号与客户端系统版本号相同,则还可以根据编译日期和/或编译次数判断你是否进行系统升级。具体包括步骤A1-A2:In the embodiment of the present invention, when the client version field also includes the compilation date and/or compilation times, if the latest system version number is the same as the client system version number, then it can also be judged based on the compilation date and/or compilation times whether you have performed System Upgrade. Specifically include steps A1-A2:
步骤A1、若最新系统版本号与客户端系统版本号相同,则在最新系统版本字段中的编译日期高于客户端版本字段中的编译日期时,将与最新系统版本字段相对应的系统升级包发送至客户端;Step A1. If the latest system version number is the same as the client system version number, when the compilation date in the latest system version field is higher than the compilation date in the client version field, upgrade the system package corresponding to the latest system version field sent to the client;
步骤A2、若最新系统版本字段中的编译日期与客户端版本字段中的编译日期相同,则在最新系统版本字段中的编译次数大于客户端版本字段中的编译次数时,将与最新系统版本字段相对应的系统升级包发送至客户端。Step A2. If the compilation date in the latest system version field is the same as the compilation date in the client version field, when the number of compilations in the latest system version field is greater than the number of compilations in the client version field, it will be compared with the latest system version field The corresponding system upgrade package is sent to the client.
优选的,当客户端版本字段还包括版本类型时;步骤102中根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,具体包括:Preferably, when the client version field also includes a version type; in step 102, determine the latest system version field consistent with the platform model field and the region field according to the platform model field and the region field, specifically including:
根据平台机型字段、地域字段和版本类型确定与平台机型字段、地域字段和版本类型相一致的最新系统版本字段。本发明实施例中,根据平台机型字段、地域字段和版本类型可以缩小服务器端系统版本的检索范围,提高处理效率。Determine the latest system version field consistent with the platform model field, region field and version type according to the platform model field, region field and version type. In the embodiment of the present invention, according to the platform model field, region field and version type, the retrieval range of the server-side system version can be narrowed, and the processing efficiency can be improved.
优选的,系统升级请求还包括客户端MAC地址。在步骤101获取客户端上传的系统升级请求之后,该方法还包括:Preferably, the system upgrade request further includes the MAC address of the client. After obtaining the system upgrade request uploaded by the client in step 101, the method further includes:
判断客户端MAC地址是否与系统存储的MAC地址相匹配,在客户端MAC地址与系统存储的MAC地址相匹配时,继续确定最新系统版本字段步骤。Determine whether the MAC address of the client matches the MAC address stored in the system, and when the MAC address of the client matches the MAC address stored in the system, proceed to the step of determining the latest system version field.
本发明实施例中,客户端的MAC地址用于确认该客户端是否具有升级系统的资格,从而可以排除其他客户端。例如,厂商A生产的手机a可以向厂商A的服务器请求系统升级,而厂商B生产的手机b不可以向厂商A的服务器请求系统升级;通过判断MAC地址是否匹配即可完成上述过程。In the embodiment of the present invention, the MAC address of the client is used to confirm whether the client is qualified to upgrade the system, so that other clients can be excluded. For example, mobile phone a produced by manufacturer A can request system upgrade from the server of manufacturer A, while mobile phone b produced by manufacturer B cannot request system upgrade from the server of manufacturer A; the above process can be completed by judging whether the MAC addresses match.
优选的,服务器向客户端发送的系统升级包中包括升级标识;该升级标识用于标识是否可以进行系统升级。例如,0代表不升级,1代表强制升级,2代表可以升级,需要用户自主选择。只有在升级标识为支持升级时(以上述为例,升级标识为1或2时),指示客户端进行系统升级。Preferably, the system upgrade package sent by the server to the client includes an upgrade identifier; the upgrade identifier is used to identify whether the system can be upgraded. For example, 0 means no upgrade, 1 means mandatory upgrade, and 2 means upgrade is possible, which needs to be selected by the user. Only when the upgrade flag supports upgrade (taking the above as an example, when the upgrade flag is 1 or 2), the client is instructed to perform system upgrade.
本发明实施例提供的一种根据版本信息控制系统升级的方法,重新扩展了版本字段,根据版本字段中的平台机型字段和地域字段等确定服务器端的最新系统的版本字段,进而通过比较即可判断客户端是否需要升级。该版本字段支持增加新的平台或机型等,可扩展性强,通过判断版本号的大小即可确定是否需要升级,判断逻辑简单。通过判断MAC地址可以剔除硬件不符合升级要求的客户端;通过升级标识服务器端可以有效控制客户端系统升级的情况。The embodiment of the present invention provides a method for controlling system upgrades based on version information, which re-expands the version field, determines the version field of the latest system on the server side according to the platform model field and region field in the version field, and then compares Determine whether the client needs to be upgraded. The version field supports the addition of new platforms or models, etc., and is highly scalable. It can be determined whether an upgrade is required by judging the size of the version number, and the judgment logic is simple. Clients whose hardware does not meet the upgrade requirements can be eliminated by judging the MAC address; the upgrade of the client system can be effectively controlled by identifying the server.
下面通过一个实施例详细介绍该方法的流程。The flow of the method will be described in detail below through an embodiment.
实施例一Embodiment one
在实施例一中,版本字段包括平台机型字段、地域字段、系统版本号、编译日期和编译次数,版本字段采取24位字母+数字混合的方式,其格式为VxxxxRxxxxCxxxxxxBxxxxNS,该版本字段的优势在于具有丰富的业务含义及很强的扩展性。参见图2所示,该方法包括步骤201-209:In the first embodiment, the version field includes platform model field, region field, system version number, compilation date and compilation times. The version field adopts 24 letters and numbers mixed in the form of VxxxxRxxxxCxxxxxxBxxxxNS. The advantage of this version field is It has rich business meaning and strong scalability. Referring to Fig. 2, the method includes steps 201-209:
步骤201:获取客户端上传的系统升级请求,系统升级请求包括客户端版本字段和客户端MAC地址。Step 201: Obtain a system upgrade request uploaded by the client, where the system upgrade request includes a client version field and a client MAC address.
其中,该客户端版本字段包括平台机型字段、地域字段、客户端系统版本号、编译日期和编译次数。Wherein, the client version field includes platform model field, region field, client system version number, compilation date and compilation times.
步骤202:判断客户端MAC地址与系统存储的MAC地址是否相匹配,在相匹配时继续步骤203,否则流程结束。Step 202: Determine whether the MAC address of the client matches the MAC address stored in the system, and if so, proceed to step 203; otherwise, the process ends.
步骤203:根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段。Step 203: Determine the latest system version field consistent with the platform model field and region field according to the platform model field and region field.
该最新系统版本字段即为服务器端的在该平台机型字段和地域字段下的系统版本字段。最新系统版本字段包括平台机型字段、地域字段、最新系统版本号、编译日期和编译次数。The latest system version field is the system version field under the platform model field and region field on the server side. The latest system version field includes platform model field, region field, latest system version number, compilation date and compilation times.
步骤204:判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号不高于客户端系统版本号,继续步骤205,否则继续步骤207。Step 204: Determine whether the latest system version number is higher than the client system version number, if the latest system version number is not higher than the client system version number, go to step 205, otherwise go to step 207.
步骤205:判断最新系统版本字段中的编译日期是否高于客户端版本字段中的编译日期,在最新系统版本字段中的编译日期不高于客户端版本字段中的编译日期时,继续步骤206,否则继续步骤207。Step 205: determine whether the compilation date in the latest system version field is higher than the compilation date in the client version field, and when the compilation date in the latest system version field is not higher than the compilation date in the client version field, proceed to step 206, Otherwise, go to step 207.
步骤206:判断最新系统版本字段中的编译次数是否大于客户端版本字段中的编译次数,在最新系统版本字段中的编译次数大于客户端版本字段中的编译次数时,继续步骤207,否则流程结束。Step 206: Determine whether the number of compilations in the latest system version field is greater than the number of compilations in the client version field, and when the number of compilations in the latest system version field is greater than the number of compilations in the client version field, continue to step 207, otherwise the flow ends .
步骤207:将与最新系统版本字段相对应的系统升级包发送至客户端。Step 207: Send the system upgrade package corresponding to the latest system version field to the client.
步骤208:客户端根据该系统升级包对系统进行升级。Step 208: The client upgrades the system according to the system upgrade package.
步骤209:流程结束。Step 209: the process ends.
以上详细介绍了一种根据版本信息控制系统升级的方法流程,该方法也可以通过相应的装置实现,下面详细介绍该装置的结构和功能。The above describes in detail the flow of a method for controlling system upgrades based on version information. This method can also be implemented by a corresponding device. The structure and functions of the device will be described in detail below.
本发明实施例提供的一种根据版本信息控制系统升级的装置,参见图3所示,包括:An embodiment of the present invention provides a device for controlling system upgrades based on version information, as shown in FIG. 3 , including:
获取模块31,用于获取客户端上传的系统升级请求,系统升级请求包括客户端版本字段,客户端版本字段包括平台机型字段、地域字段和客户端系统版本号;The obtaining module 31 is used to obtain the system upgrade request uploaded by the client. The system upgrade request includes a client version field, and the client version field includes a platform model field, a region field and a client system version number;
确定模块32,用于根据平台机型字段和地域字段确定与平台机型字段和地域字段相一致的最新系统版本字段,最新系统版本字段包括最新系统版本号,且最新系统版本字段的格式与客户端版本字段的格式相一致;Determination module 32 is used to determine the latest system version field consistent with the platform model field and the region field according to the platform model field and the region field, the latest system version field includes the latest system version number, and the format of the latest system version field is the same as that of the customer The format of the terminal version field is consistent;
处理模块33,用于判断最新系统版本号是否高于客户端系统版本号,在最新系统版本号高于客户端系统版本号时,将与最新系统版本字段相对应的系统升级包发送至客户端,指示客户端进行系统升级。The processing module 33 is used to judge whether the latest system version number is higher than the client system version number, and when the latest system version number is higher than the client system version number, send the system upgrade package corresponding to the latest system version field to the client to instruct the client to upgrade the system.
优选的,客户端版本字段还包括编译日期和编译次数;参见图4所示,该装置还包括:Preferably, the client version field also includes compilation date and compilation times; referring to Fig. 4, the device also includes:
第一判断模块34,用于若最新系统版本号与客户端系统版本号相同,则在最新系统版本字段中的编译日期高于客户端版本字段中的编译日期时,将与最新系统版本字段相对应的系统升级包发送至客户端;The first judging module 34 is used for if the latest system version number is the same as the client system version number, when the compilation date in the latest system version field is higher than the compilation date in the client version field, it will match the latest system version field. The corresponding system upgrade package is sent to the client;
第二判断模块35,用于若最新系统版本字段中的编译日期与客户端版本字段中的编译日期相同,则在最新系统版本字段中的编译次数大于客户端版本字段中的编译次数时,将与最新系统版本字段相对应的系统升级包发送至客户端。The second judging module 35 is used for if the compilation date in the latest system version field is the same as the compilation date in the client version field, then when the compilation times in the latest system version field is greater than the compilation times in the client version field, the The system upgrade package corresponding to the latest system version field is sent to the client.
优选的,客户端版本字段还包括版本类型;Preferably, the client version field also includes a version type;
确定模块32具体用于:根据平台机型字段、地域字段和版本类型确定与平台机型字段、地域字段和版本类型相一致的最新系统版本字段。The determining module 32 is specifically configured to: determine the latest system version field consistent with the platform model field, region field and version type according to the platform model field, region field and version type.
优选的,系统升级请求还包括客户端MAC地址;参见图5所示,该装置还包括匹配模块36;Preferably, the system upgrade request also includes the MAC address of the client; as shown in Figure 5, the device also includes a matching module 36;
在获取模块31获取客户端上传的系统升级请求之后,匹配模块36用于:After the acquisition module 31 acquires the system upgrade request uploaded by the client, the matching module 36 is used for:
判断客户端MAC地址是否与系统存储的MAC地址相匹配,在客户端MAC地址与系统存储的MAC地址相匹配时,继续确定最新系统版本字段步骤。Determine whether the MAC address of the client matches the MAC address stored in the system, and when the MAC address of the client matches the MAC address stored in the system, proceed to the step of determining the latest system version field.
优选的,系统升级包中包括升级标识;在升级标识为支持升级时,处理模块指示客户端进行系统升级。Preferably, the system upgrade package includes an upgrade identifier; when the upgrade identifier supports upgrade, the processing module instructs the client to perform system upgrade.
本发明实施例提供的一种根据版本信息控制系统升级的方法及装置,重新扩展了版本字段,根据版本字段中的平台机型字段和地域字段等确定服务器端的最新系统的版本字段,进而通过比较即可判断客户端是否需要升级。该版本字段支持增加新的平台或机型等,可扩展性强,通过判断版本号的大小即可确定是否需要升级,判断逻辑简单。通过判断MAC地址可以剔除硬件不符合升级要求的客户端;通过升级标识服务器端可以有效控制客户端系统升级的情况。The embodiment of the present invention provides a method and device for controlling system upgrades based on version information. The version field is re-extended, and the version field of the latest system on the server side is determined according to the platform model field and region field in the version field, and then by comparing You can determine whether the client needs to be upgraded. The version field supports the addition of new platforms or models, etc., and is highly scalable. It can be determined whether an upgrade is required by judging the size of the version number, and the judgment logic is simple. Clients whose hardware does not meet the upgrade requirements can be eliminated by judging the MAC address; the upgrade of the client system can be effectively controlled by identifying the server.
本发明能有多种不同形式的具体实施方式,上面以图1-图5为例结合附图对本发明的技术方案作举例说明,这并不意味着本发明所应用的具体实例只能局限在特定的流程或实施例结构中,本领域的普通技术人员应当了解,上文所提供的具体实施方案只是多种优选用法中的一些示例,任何体现本发明权利要求的实施方式均应在本发明技术方案所要求保护的范围之内。The present invention can have a variety of specific implementations in different forms. The technical solutions of the present invention are illustrated by taking Fig. 1-Fig. 5 as an example in conjunction with the accompanying drawings. In the specific process or embodiment structure, those of ordinary skill in the art should understand that the specific implementations provided above are only some examples of various preferred usages, and any implementation that embodies the claims of the present invention shall be included in the present invention. Within the scope of protection required by the technical solution.
最后应说明的是:以上所述仅为本发明的优选实施例而已,并不用于限制本发明,尽管参照前述实施例对本发明进行了详细的说明,对于本领域的技术人员来说,其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换。凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。Finally, it should be noted that: the above is only a preferred embodiment of the present invention, and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, for those skilled in the art, it still The technical solutions recorded in the foregoing embodiments may be modified, or some technical features thereof may be equivalently replaced. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present invention shall be included within the protection scope of the present invention.
Claims (10)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201510759566.7A CN105915362A (en) | 2015-11-09 | 2015-11-09 | Method for controlling system upgrading according to version information and device thereof |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN201510759566.7A CN105915362A (en) | 2015-11-09 | 2015-11-09 | Method for controlling system upgrading according to version information and device thereof |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN105915362A true CN105915362A (en) | 2016-08-31 |
Family
ID=56744202
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN201510759566.7A Pending CN105915362A (en) | 2015-11-09 | 2015-11-09 | Method for controlling system upgrading according to version information and device thereof |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN105915362A (en) |
Cited By (2)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109218054A (en) * | 2017-07-03 | 2019-01-15 | 腾讯科技(深圳)有限公司 | Terminal dynamic configuration, respective server implementation method, device and storage medium |
| CN113886367A (en) * | 2021-10-29 | 2022-01-04 | 南方电网科学研究院有限责任公司 | Method, system and device for judging compliance of power information system network security inspection |
Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1917406A (en) * | 2005-08-17 | 2007-02-21 | 三星电子株式会社 | Method of upgrading software through download in t-dmb terminal |
| CN101232562A (en) * | 2007-01-25 | 2008-07-30 | 深圳市同洲电子股份有限公司 | Method and system for updating set top box and software thereof |
| CN101499932A (en) * | 2009-03-09 | 2009-08-05 | 建汉科技股份有限公司 | Firmware upgrading method for multiple network devices |
| US20090265425A1 (en) * | 2004-07-12 | 2009-10-22 | Netsuite, Inc. | Phased rollout of version upgrades in web-based business information systems |
| CN104049985A (en) * | 2013-03-12 | 2014-09-17 | 中兴通讯股份有限公司 | Cross-file-system version on-line upgrading method and device |
| CN104424001A (en) * | 2013-09-06 | 2015-03-18 | 镇江精英软件科技有限公司 | Method for realizing automatic upgrading of CS (client/server) architecture program through version control |
| CN105024839A (en) * | 2014-04-18 | 2015-11-04 | 中兴通讯股份有限公司 | Method and device for upgrading software version |
-
2015
- 2015-11-09 CN CN201510759566.7A patent/CN105915362A/en active Pending
Patent Citations (7)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US20090265425A1 (en) * | 2004-07-12 | 2009-10-22 | Netsuite, Inc. | Phased rollout of version upgrades in web-based business information systems |
| CN1917406A (en) * | 2005-08-17 | 2007-02-21 | 三星电子株式会社 | Method of upgrading software through download in t-dmb terminal |
| CN101232562A (en) * | 2007-01-25 | 2008-07-30 | 深圳市同洲电子股份有限公司 | Method and system for updating set top box and software thereof |
| CN101499932A (en) * | 2009-03-09 | 2009-08-05 | 建汉科技股份有限公司 | Firmware upgrading method for multiple network devices |
| CN104049985A (en) * | 2013-03-12 | 2014-09-17 | 中兴通讯股份有限公司 | Cross-file-system version on-line upgrading method and device |
| CN104424001A (en) * | 2013-09-06 | 2015-03-18 | 镇江精英软件科技有限公司 | Method for realizing automatic upgrading of CS (client/server) architecture program through version control |
| CN105024839A (en) * | 2014-04-18 | 2015-11-04 | 中兴通讯股份有限公司 | Method and device for upgrading software version |
Cited By (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN109218054A (en) * | 2017-07-03 | 2019-01-15 | 腾讯科技(深圳)有限公司 | Terminal dynamic configuration, respective server implementation method, device and storage medium |
| CN109218054B (en) * | 2017-07-03 | 2022-08-09 | 腾讯科技(深圳)有限公司 | Terminal dynamic configuration, corresponding server implementation method, device and storage medium |
| CN113886367A (en) * | 2021-10-29 | 2022-01-04 | 南方电网科学研究院有限责任公司 | Method, system and device for judging compliance of power information system network security inspection |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| CN1270568C (en) | Method for supporting multilanguage for mobile communication terminal and its communication system | |
| CN103402194B (en) | A kind of method recommending software when software upgrading and realize the system of the method | |
| CN105915361A (en) | Group upgrading method and device | |
| CN101287189B (en) | Displaying method of terminal, server and terminal | |
| US10091141B2 (en) | Method and device for providing communication between multi-devices | |
| CN102750176A (en) | Software upgrading method and device for network TV | |
| CN105743984A (en) | Method, device and system for automatically updating mobile application | |
| WO2017181623A1 (en) | Network registration method for virtual sim card and terminal | |
| CN107295503A (en) | Determine method, storage medium and the mobile terminal of mobile terminal access way | |
| US20150230282A1 (en) | Method of updating into service category table in device and device for the same | |
| CN103987028A (en) | Method and system for automatically updating contacts | |
| CN108334364A (en) | It is a kind of that dynamic load is realized based on Lottie and updates the method and its system of animation | |
| CN105007537A (en) | Smart television booting animation control method and system | |
| CN105915362A (en) | Method for controlling system upgrading according to version information and device thereof | |
| CN107948239A (en) | Version upgrading method and its system based on android system | |
| CN101272204B (en) | A method for updating electronic business guide and its terminal | |
| CN107318042A (en) | A kind of channel choosing method and intelligent television based on speech recognition | |
| CN108108166B (en) | Multi-platform inter-map processing method and system | |
| CN104383695B (en) | Control method and system for electronic toy | |
| CN113590151A (en) | Method and system for OTA (over the air) upgrade of Bluetooth equipment | |
| CN101854442B (en) | Network device and firmware updating method thereof | |
| WO2018133500A1 (en) | Push system and method utilized in remote application and based on wechat subscription number | |
| CN107483449B (en) | Universal television terminal management system and management method | |
| CN105338031A (en) | Intelligent terminal operating system based affair reminding method, and intelligent terminal | |
| CN105915363A (en) | Transition upgrading method and device |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| C06 | Publication | ||
| PB01 | Publication | ||
| C10 | Entry into substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20160831 |
|
| WD01 | Invention patent application deemed withdrawn after publication |