WO2017096889A1 - 系统升降级的方法和装置 - Google Patents

系统升降级的方法和装置 Download PDF

Info

Publication number
WO2017096889A1
WO2017096889A1 PCT/CN2016/089472 CN2016089472W WO2017096889A1 WO 2017096889 A1 WO2017096889 A1 WO 2017096889A1 CN 2016089472 W CN2016089472 W CN 2016089472W WO 2017096889 A1 WO2017096889 A1 WO 2017096889A1
Authority
WO
WIPO (PCT)
Prior art keywords
data packet
type
packet
system data
data
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.)
Ceased
Application number
PCT/CN2016/089472
Other languages
English (en)
French (fr)
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.)
Le Holdings Beijing Co Ltd
Lemobile Information Technology (Beijing) Co Ltd
Original Assignee
Le Holdings Beijing Co Ltd
Lemobile Information Technology (Beijing) 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 Le Holdings Beijing Co Ltd, Lemobile Information Technology (Beijing) Co Ltd filed Critical Le Holdings Beijing Co Ltd
Priority to US15/246,535 priority Critical patent/US20170163787A1/en
Publication of WO2017096889A1 publication Critical patent/WO2017096889A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/445Program loading or initiating
    • G06F9/44536Selecting among different versions

Definitions

  • Embodiments of the present invention relate to the field of communications technologies, and in particular, to a method and apparatus for system lifting and lowering.
  • the replacement system includes both upgrade and downgrade.
  • the upgrade is changed from a lower version system to a higher version system
  • the downgrade is changed from a high version system to a lower version system. Since the high version system is an improvement to the lower version system, some system applications in the higher version system have more functions than the corresponding system applications in the lower version system. Therefore, the high version system can successfully read the user data generated in the low version system, and in many cases the low version system cannot successfully read the user data generated in the high version system. It can be seen that when the system is downgraded, there are often some applications that are incompatible, which may cause some problems in the user's use of the mobile phone.
  • the user data cannot be successfully read, so that the function corresponding to the user data cannot be used; for example, when the application is started, the user data that needs to be loaded cannot be successfully loaded, and the application cannot be opened; for example, in the application When you open your phone, you cannot successfully load a user data that needs to be loaded, so you cannot open your phone.
  • the user In order to solve the above problem, the user must restart the system to enter the system recovery mode to delete all user data, so that the current system does not need to read the user data generated in the previous system, in order to use each function in the current system normally.
  • the user data contains important information such as a phone number, a short message, and a chat log in the chat software, and the deletion of the information causes a large loss to the user. Therefore, how to avoid user data loss when the system is downgraded is A big problem today.
  • the embodiment of the invention provides a method and a device for lifting and lowering a system, which solves the problem that in the prior art, when there is an incompatibility problem after the system is downgraded and the user data must be deleted and solved, the user may be lost.
  • an embodiment of the present invention provides a method for system lifting and lowering, the method comprising:
  • the user data is backed up, wherein the whole package type indicates that the system data packet is complete and independent. a data packet for the lifting stage;
  • system data packet is executed to implement system downgrade.
  • an embodiment of the present invention provides a device for lifting a system, the device comprising:
  • An obtaining unit configured to acquire a system data packet
  • a backup unit configured to back up user data when determining that the data type of the system data packet acquired by the acquiring unit is a whole package type and determining that the current system operation is system degradation, wherein the whole package type indicates
  • the system data packet is a complete data packet that can be used independently for the lifting stage;
  • the execution unit is configured to execute the system data packet after the backup unit backs up the user data to implement system degradation.
  • the method and apparatus for the system lifting stage provided by the embodiment of the present invention can back up the user data first, and then execute the system data when determining that the data type of the acquired system data packet is a whole package type and the local system operation is system downgrading.
  • the package is implemented to degrade the system, so as to avoid the problem that the application is incompatible with the user data after the system is downgraded and the user data must be deleted to solve the problem, causing loss to the user.
  • FIG. 1 is a flowchart of a method for system lifting and lowering according to an embodiment of the present invention
  • FIG. 2 is a block diagram of a device for a system lifting stage according to an embodiment of the present invention
  • FIG. 3 is a structural block diagram of another apparatus for lifting and lowering a system according to an embodiment of the present invention.
  • An embodiment of the present invention provides a method for system lifting and lowering. As shown in FIG. 1, the method includes:
  • the system data packet is obtained first, and then the subsequent upgrade or downgrade operation is performed.
  • the terminal system lifting stage is mainly divided into two modes: the online system lifting stage and the offline system lifting stage. If the terminal performs the online system lifting level, the terminal downloads the system data packet online through the network; if the terminal performs the offline lifting level, when the terminal is in the shutdown state, the user can download the system data packet on the computer, and then the system is passed through the data line. The data packet is copied to the SD card of the terminal to obtain the system data packet.
  • the most commonly used system lifting technology in practical applications is the OTA (Over The Air) technology.
  • the terminal may be a mobile phone of the Android system, a tablet computer of the Android system, or other devices.
  • the user data is backed up.
  • the data types of system data packets are mainly divided into two types, namely, a full packet type and a differential packet type.
  • the whole package type indicates that the system data packet is a complete data packet that can be used independently for the lifting stage
  • the differential packet type indicates that the system data packet is differential and must be based on a certain version of the system.
  • Line upgraded packets That is to say, the whole package type system data package can realize system upgrade, and can also realize system downgrade, and the differential package type system data package can only implement system upgrade.
  • the application may be incompatible with the user data.
  • the user data needs to be deleted. Therefore, in order to avoid the loss of the user data, the user may be lost before the system is downgraded. Back up user data. After the original user data is deleted for solving the incompatibility problem, the user can import the backed up user data into the corresponding application and continue to use.
  • the terminal may automatically perform a backup operation or display a prompt message to allow the user to select whether to perform backup.
  • the terminal first enters the system recovery mode, and then executes the system data packet to achieve system degradation.
  • the system recovery mode is a mode that can modify the system data. In this mode, you can brush in a new system, or you can back up or upgrade the existing system, or you can restore the factory settings here.
  • the method for lifting and lowering the system provided by the embodiment of the present invention can first back up the user data and then execute the system data packet when determining that the data type of the acquired system data packet is a whole package type and the local system operation is a system degradation.
  • the system is downgraded to avoid the problem that the application is incompatible with the user data after the system is downgraded and the user data must be deleted to solve the problem, causing loss to the user.
  • the terminal may automatically back up the user data, or may first confirm the user and then perform backup.
  • the user may first confirm that the specific implementation manner of the backup may be: displaying the prompt information, and backing up the user data after receiving the confirmation backup instruction.
  • the prompt information is used to prompt the user whether to back up user data.
  • the terminal determines that the system operation is degraded, it can be displayed on the interface that after the system is replaced, there may be incompatibility problems.
  • user data needs to be deleted. Is the user data backed up first? Operation"; when the user clicks to confirm the backup, the terminal will receive a confirmation backup command and then back up the user data.
  • the high version system is an improvement to the lower version system, the high version system can be compatible with the data generated in the lower version system, so the system upgrade does not involve incompatibility problems, It does not involve the deletion of user data. Therefore, when the terminal determines that the data type of the system data packet is a whole package type and determines that the current system operation is a system upgrade, the system data packet is executed to implement system upgrade; and/or, when the terminal determines the data of the system data packet.
  • the type is differential packet type, it is determined that the system operation is a system upgrade, and system data packets are executed to implement system upgrade.
  • differential packet type system data packet can only implement system upgrade. Therefore, when it is determined that the data type of the system data packet is a packet classification type, the terminal can directly determine that the system operation is a system upgrade.
  • the terminal system manufacturer when developing a system data packet, the terminal system manufacturer adds basic information of the system data packet to the developed system data packet, so as to subsequently determine the system data packet according to the content in the basic information.
  • the data type and the version of the system packet, and before using the system packet to change the system, can determine whether the user data needs to be backed up based on the basic information. Therefore, after acquiring the system data packet, the terminal first obtains the target file from the system data packet, parses the target file, and finally determines the data type of the system data packet by using the analysis result.
  • the target file is a file added in the system data packet to describe basic information of the system data packet when generating the system data packet; the basic information includes the data type and version information of the system data packet.
  • the target file can be a file named ota_info.
  • the version information of the whole package type system data packet may include only one version number, that is, the version number of the system data packet;
  • the packet system packet is a differential packet that must be upgraded based on a certain version of the system. Therefore, the version information of the differential packet system packet needs to include two version numbers, that is, the original version number and the target version number.
  • the original version number is used to indicate the version number of the system on which the system upgrade is to be implemented by using the system data packet, that is, the version number of the current system of the terminal must be the same as the original version number, in order to successfully upgrade the system data packet;
  • the target version number It is used to indicate the version number of the system upgraded with the system packet, that is, the version number of the system packet.
  • version information of the package type system data packet may also include the original version number and the target version number, but the original version number is the same as the target version number and is the version number of the system data packet.
  • the terminal can determine whether the system operation is a system upgrade or a system degradation by comparing the version number of the system data packet with the version number of the current system. Specifically, if the version number of the system data packet is lower than the version number of the current system, the terminal determines that the current system operation is system degradation; if the version number of the system data packet is higher than the current system version number, the terminal determines the current system.
  • the operation is a system upgrade.
  • another embodiment of the present invention further provides a device for lifting and lowering a system, wherein the device is applied to a terminal, as shown in FIG. 2, the device includes: an acquiring unit 21, a backup unit 22 and execution unit 23. among them,
  • An obtaining unit 21 configured to acquire a system data packet
  • the obtaining unit 21 When the system of the terminal needs to be upgraded or downgraded, the obtaining unit 21 first acquires the system data packet, and then performs subsequent upgrade or downgrade operations.
  • the terminal system lifting stage is mainly divided into two modes: the online system lifting stage and the offline system lifting stage. If the terminal performs the online system lifting level, the obtaining unit 21 downloads the system data packet online through the network; if the terminal performs the offline lifting level, the user can download the system data packet on the computer and then pass the data line when the terminal is in the shutdown state. The system data packet is copied to the SD card of the terminal, so that the acquisition unit 21 obtains the system data packet.
  • the most commonly used system lifting technology in practical applications is the OTA (Over The Air) technology.
  • the backup unit 22 is configured to back up the user data when it is determined that the data type of the system data packet acquired by the obtaining unit 21 is a whole package type and it is determined that the current system operation is a system degradation.
  • the whole package type indicates that the system data packet is a complete data packet that can be used independently for the lifting stage. That is to say, the whole package type system data package can implement system upgrade, and can also achieve system downgrade.
  • the backup unit 22 may automatically perform a backup operation, or display a prompt message on the terminal interface, so that the user selects whether to perform backup.
  • the backup unit 22 Then back up the user data.
  • the executing unit 23 is configured to execute the system data packet after the backup unit 22 backs up the user data to implement system degradation.
  • the terminal first enters the system recovery mode, and then the execution unit 23 executes the system data packet to implement system degradation.
  • the system recovery mode is one that can perform system data Modified mode, in which you can swipe into a new system, or you can back up or upgrade the existing system, or you can restore the factory settings here.
  • the device of the system lifting and lowering level provided by the embodiment of the present invention can back up the user data and then execute the system data packet when determining that the data type of the acquired system data packet is a whole package type and the local system operation is a system degradation.
  • the system is downgraded to avoid the problem that the application is incompatible with the user data after the system is downgraded and the user data must be deleted to solve the problem, causing loss to the user.
  • the backup unit 22 includes:
  • the display module 221 is configured to display prompt information, where the prompt information is used to prompt the user whether to back up user data.
  • the backup module 222 is configured to back up user data after receiving the confirmation backup instruction.
  • the display module 221 may display on the interface that after the system is replaced, there may be an incompatibility problem.
  • the user data needs to be deleted. Is the user data backed up first? After the user clicks to confirm the backup, the terminal receives the confirmation backup instruction, and then the backup module 222 backs up the user data.
  • the executing unit 23 is further configured to: when determining that the data type of the system data packet acquired by the obtaining unit 21 is a whole package type and determining that the current system operation is a system upgrade, execute the system data packet to implement the system upgrade; and/ Or, when it is determined that the data type of the system data packet acquired by the obtaining unit 21 is a differential packet type, it is determined that the current system operation is a system upgrade, and the system data packet is executed to implement the system upgrade, wherein the differential packet type represents the system data packet.
  • the device further includes:
  • a first determining unit 24 configured to determine a data type of the system data packet
  • the first determining unit 24 includes:
  • the obtaining module 241 is configured to obtain an object file from a system data packet, where the target file is a file added in the system data packet to describe basic information of the system data packet when the system data packet is generated; the basic information includes system data. The data type and version information of the package.
  • the determining module 242 is configured to parse the target file acquired by the obtaining module 241, and determine the data type of the system data packet.
  • the version information of the whole package type system data packet may include only one version number, that is, the version number of the system data packet;
  • the packet system packet is a differential packet that must be upgraded based on a certain version of the system. Therefore, the version information of the differential packet system packet needs to include two version numbers, that is, the original version number and the target version number.
  • the original version number is used to indicate the version number of the system on which the system upgrade is to be implemented by using the system data packet, that is, the version number of the current system of the terminal must be the same as the original version number, in order to successfully upgrade the system data packet;
  • the target version number It is used to indicate the version number of the system upgraded with the system packet, that is, the version number of the system packet.
  • version information of the package type system data packet may also include the original version number and the target version number, but the original version number is the same as the target version number and is the version number of the system data packet.
  • the device further includes:
  • a second determining unit 25 configured to determine that the current system operation is system degradation
  • the second determining unit 25 is configured to determine, when the version number of the system data packet is lower than the version number of the current system, that the current system operation is system degradation;
  • the device further includes:
  • a third determining unit 26 configured to determine that the current system operation is a system upgrade
  • the third determining unit 26 is configured to determine that the current system operation is a system upgrade when the version number of the system data packet is higher than the version number of the current system.
  • the version number of the system data packet is stored in the target file.
  • the device embodiment corresponds to the foregoing method embodiment.
  • the device embodiment does not describe the details in the foregoing method embodiments one by one, but it should be clear that the device in this embodiment can implement the foregoing method. All the contents of the example.
  • the apparatus for lifting and lowering the system includes a memory and a processor.
  • the acquisition unit, the backup unit, and the execution unit are stored in the memory as a program unit, and the program unit stored in the memory is executed by the processor to implement a corresponding function.
  • the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located a place, or it can be distributed more On a network unit. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment. Those of ordinary skill in the art can understand and implement without deliberate labor.

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

一种系统升降级的方法和装置,其中,方法主要包括:获取系统数据包(101);当确定所述系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份(102),其中,所述整包型表示所述系统数据包为完整的、能够独立用于升降级的数据包;在对用户数据进行备份后,执行所述系统数据包,以实现系统降级(103)。与现有技术相比,能够在确定本次系统操作为系统降级时,先备份用户数据,再执行系统数据包,实现系统降级,从而避免在系统降级后存在不兼容问题必须删除用户数据时,给用户造成损失。

Description

系统升降级的方法和装置
本申请基于申请号为2015108883676、申请日为2015年12月07日的中国专利申请提出,并要求该中国专利申请的优先权,该中国专利申请的全部内容在此引入本申请作为参考。
技术领域
本发明实施例涉及通信技术领域,尤其涉及一种系统升降级的方法和装置。
背景技术
随着通信技术的发展,手机厂商不断对手机系统进行改进,生成不同版本的系统数据包,供用户选择需要的版本更换系统。
在实际应用中,更换系统包括升级和降级两种情况。其中,升级是由低版本系统变为高版本系统,降级是由高版本系统变为低版本系统。由于高版本系统是对低版本系统的改进,所以高版本系统中的某些系统应用的功能比低版本系统中对应的系统应用的功能多。因此,高版本系统能成功读取在低版本系统中产生的用户数据,而很多情况下低版本系统无法成功读取在高版本系统中产生的用户数据。由此可知,当对系统进行降级后,常常会存在某些应用不兼容的情况,从而在用户使用手机过程中会产生一些问题。例如,打开应用后无法成功读取某用户数据,从而无法使用该用户数据对应的功能;又如,在启动应用时无法成功加载需要加载的某用户数据,从而无法打开该应用;再如,在打开手机时无法成功加载需要加载的某用户数据,从而无法打开手机。
为解决上述问题,用户必须重启系统进入系统恢复模式将所有用户数据删除,使得当前系统不用读取在上一个系统中产生的用户数据,才能正常使用当前系统中的每一个功能。然而,用户数据中含有电话号码、短信以及聊天软件中的聊天记录等重要信息,将这些信息删除后,会对用户造成较大损失。因此,如何在进行系统降级的情况下避免用户数据丢失是当 今一大难题。
发明内容
本发明实施例提供一种系统升降级的方法和装置,用以解决现有技术中在系统降级后存在不兼容问题且必须删除用户数据予以解决时,会给用户造成损失的问题。
一方面,本发明实施例提供了一种系统升降级的方法,所述方法包括:
获取系统数据包;
当确定所述系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份,其中,所述整包型表示所述系统数据包为完整的、能够独立用于升降级的数据包;
在对用户数据进行备份后,执行所述系统数据包,以实现系统降级。
另一方面,本发明实施例提供了一种系统升降级的装置,所述装置包括:
获取单元,用于获取系统数据包;
备份单元,用于当确定所述获取单元获取的所述系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份,其中,所述整包型表示所述系统数据包为完整的、能够独立用于升降级的数据包;
执行单元,用于在所述备份单元对用户数据进行备份后,执行所述系统数据包,以实现系统降级。
本发明实施例提供的系统升降级的方法和装置,能够在确定获取的系统数据包的数据类型为整包型并且本地系统操作为系统降级时,先对用户数据进行备份,再执行该系统数据包,实现系统降级,从而避免在系统降级后存在应用与用户数据不兼容问题且必须删除用户数据予以解决时,给用户造成损失。
附图说明
为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作一简单地介绍,显而易见 地,下面描述中的附图是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1为本发明实施例提供的一种系统升降级的方法的流程图;
图2为本发明实施例提供的一种系统升降级的装置的组成框图;
图3为本发明实施例提供的另一种系统升降级的装置的组成框图。
具体实施方式
为使本发明实施例的目的、技术方案和优点更加清楚,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有作出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。
本发明实施例提供了一种系统升降级的方法,如图1所示,该方法包括:
101、获取系统数据包。
当终端的系统需要升级或者降级时,会先获取系统数据包,再进行后续升级或降级操作。在实际应用中,终端系统升降级主要分为两种方式:在线系统升降级和离线系统升降级。若终端进行在线系统升降级,则终端会通过网络在线下载系统数据包;若终端进行离线升降级,则在终端处于关机状态时,用户可在电脑上下载系统数据包,然后通过数据线将系统数据包复制到终端的SD卡中,从而获得系统数据包。此外,实际应用中最常用的系统升降技术为OTA(Over The Air,空中下载)技术。
需要说明的是,该终端可以为Android系统的手机,也可以为Android系统的平板电脑,也可以为其他设备。
102、当确定系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份。
在实际应用中,系统数据包的数据类型主要分为两种,即整包型和差分包型。其中,整包型表示系统数据包为完整的、能够独立用于升降级的数据包;差分包型表示系统数据包为差分的、必须基于某版本系统才能进 行升级的数据包。也就是说,整包型的系统数据包可以实现系统升级,也可以实现系统降级,而差分包型的系统数据包只能实现系统升级。
由于在进行系统降级后,可能会涉及应用与用户数据不兼容的问题,而解决该问题,需要删除用户数据,所以为避免删除用户数据后,给用户造成损失,可以在进行系统降级之前,先对用户数据进行备份。当后续为解决不兼容问题将原始的用户数据删除后,用户可以将备份的用户数据导入到对应的应用中继续使用。
需要说明的是,当需要对用户数据进行备份时,终端可以自动执行备份操作,也可以显示提示信息,让用户选择是否进行备份。
103、在对用户数据进行备份后,执行系统数据包,以实现系统降级。
具体的,终端会先进入系统恢复模式,然后才执行系统数据包,实现系统降级。其中,系统恢复模式是一种可以对系统数据进行修改的模式,在该模式下,可以刷入新的系统,也可以对已有的系统进行备份或升降级,也可以在此恢复出厂设置。
本发明实施例提供的系统升降级的方法,能够在确定获取的系统数据包的数据类型为整包型并且本地系统操作为系统降级时,先对用户数据进行备份,再执行该系统数据包,实现系统降级,从而避免在系统降级后存在应用与用户数据不兼容问题且必须删除用户数据予以解决时,给用户造成损失。
进一步的,在上述步骤102中提及,当需要对用户数据进行备份时,终端可以自动对用户数据进行备份,也可以先让用户确认,再进行备份。其中,让用户先确认,在进行备份的具体实现方式可以为:显示提示信息,在接收到确认备份指令后,备份用户数据。
具体的,提示信息用于提示用户是否备份用户数据。例如,当终端确定本次系统操作为降级时,可以在界面上显示“更换系统后,可能存在不兼容问题,为解决该问题需要删除用户数据,请问是否先对用户数据进行备份,再进行后续操作”;当用户点击确认备份后,终端会接收到确认备份指令,然后对用户数据进行备份。
进一步的,由于高版本系统是对低版本系统的改进,所以高版本系统能够兼容低版本系统中产生的数据,因此系统升级不涉及不兼容问题,从 而不涉及删除用户数据的情况。由此可知,当终端确定系统数据包的数据类型为整包型且确定本次系统操作为系统升级时,执行系统数据包,以实现系统升级;和/或,当终端确定系统数据包的数据类型为差分包型时,确定本次系统操作为系统升级,并执行系统数据包,以实现系统升级。
需要说明的是,差分包型系统数据包只能实现系统升级,因此,当确定该系统数据包的数据类型为查分包型时,终端可以直接确定本次系统操作为系统升级。
进一步的,在本发明中,终端系统厂商在开发系统数据包时,会在所开发的系统数据包中添加该系统数据包的基本信息,以便后续根据基本信息中的内容来判断系统数据包的数据类型和系统数据包的版本,以及在利用该系统数据包更改系统前,可以根据该基本信息判断是否需要对用户数据进行备份。因此,终端在获取系统数据包后,会先从系统数据包中获取目标文件,再解析该目标文件,最后通过解析结果确定系统数据包的数据类型。
其中,目标文件是在生成系统数据包时,在系统数据包中添加的、用于描述系统数据包的基本信息的文件;基本信息包括系统数据包的数据类型和版本信息。在实际应用中,当利用OTA技术实现系统升降级时,目标文件可以为名称为ota_info的文件。
由于整包型系统数据包是完整的、能够独立用于升降级的数据包,所以整包型系统数据包的版本信息中可以仅包含一个版本号,即该系统数据包的版本号;由于差分包型系统数据包是差分的、必须基于某版本系统才能进行升级的数据包,所以差分包型系统数据包的版本信息需要包括两个版本号,即原始版本号和目标版本号。其中,原始版本号用于表示利用该系统数据包实现系统升级必须基于的系统的版本号,即终端当前系统的版本号必须与原始版本号相同,才能使用该系统数据包成功升级;目标版本号用于表示利用该系统数据包升级后的系统的版本号,即该系统数据包的版本号。
需要说明的是,整包型系统数据包的版本信息中也可以包括原始版本号和目标版本号,但是原始版本号与目标版本号相同且均为该系统数据包的版本号。
此外,终端可以通过比较系统数据包的版本号与当前系统的版本号,来判断本次系统操作是系统升级,还是系统降级。具体的,若系统数据包的版本号低于当前系统的版本号,则终端确定本次系统操作为系统降级;若系统数据包的版本号高于当前系统的版本号,则终端确定本次系统操作为系统升级。
进一步的,依据上述方法实施例,本发明的另一个实施例还提供了一种系统升降级的装置,该装置应用于终端当中,如图2所示,该装置包括:获取单元21、备份单元22和执行单元23。其中,
获取单元21,用于获取系统数据包;
当终端的系统需要升级或者降级时,获取单元21会先获取系统数据包,再进行后续升级或降级操作。在实际应用中,终端系统升降级主要分为两种方式:在线系统升降级和离线系统升降级。若终端进行在线系统升降级,则获取单元21会通过网络在线下载系统数据包;若终端进行离线升降级,则在终端处于关机状态时,用户可在电脑上下载系统数据包,然后通过数据线将系统数据包复制到终端的SD卡中,从而获取单元21获得系统数据包。此外,实际应用中最常用的系统升降技术为OTA(Over The Air,空中下载)技术。
备份单元22,用于当确定获取单元21获取的系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份。
其中,整包型表示系统数据包为完整的、能够独立用于升降级的数据包。也就是说,整包型的系统数据包可以实现系统升级,也可以实现系统降级。
需要说明的是,当备份单元22需要对用户数据进行备份时,备份单元22可以自动执行备份操作,也可以在终端界面显示提示信息,让用户选择是否进行备份,当用户选择备份时,备份单元22再对用户数据进行备份。
执行单元23,用于在备份单元22对用户数据进行备份后,执行系统数据包,以实现系统降级。
具体的,终端会先进入系统恢复模式,然后执行单元23才执行系统数据包,实现系统降级。其中,系统恢复模式是一种可以对系统数据进行 修改的模式,在该模式下,可以刷入新的系统,也可以对已有的系统进行备份或升降级,也可以在此恢复出厂设置。
本发明实施例提供的系统升降级的装置,能够在确定获取的系统数据包的数据类型为整包型并且本地系统操作为系统降级时,先对用户数据进行备份,再执行该系统数据包,实现系统降级,从而避免在系统降级后存在应用与用户数据不兼容问题且必须删除用户数据予以解决时,给用户造成损失。
进一步的,如图3所示,备份单元22,包括:
显示模块221,用于显示提示信息,提示信息用于提示用户是否备份用户数据;
备份模块222,用于在接收到确认备份指令后,备份用户数据。
例如,当终端确定本次系统操作为降级时,显示模块221可以在界面上显示“更换系统后,可能存在不兼容问题,为解决该问题需要删除用户数据,请问是否先对用户数据进行备份,再进行后续操作”;当用户点击确认备份后,终端会接收到确认备份指令,然后备份模块222对用户数据进行备份。
进一步的,执行单元23,还用于当确定获取单元21获取的系统数据包的数据类型为整包型且确定本次系统操作为系统升级时,执行系统数据包,以实现系统升级;和/或,当确定获取单元21获取的系统数据包的数据类型为差分包型时,确定本次系统操作为系统升级,并执行系统数据包,以实现系统升级,其中,差分包型表示系统数据包为差分的、必须基于某版本系统才能进行升级的数据包。
进一步的,如图3所示,该装置还包括:
第一确定单元24,用于确定系统数据包的数据类型;
第一确定单元24包括:
获取模块241,用于从系统数据包中获取目标文件,目标文件是在生成系统数据包时,在系统数据包中添加的、用于描述系统数据包的基本信息的文件;基本信息包括系统数据包的数据类型和版本信息。
确定模块242,用于解析获取模块241获取的目标文件,确定系统数据包的数据类型。
由于整包型系统数据包是完整的、能够独立用于升降级的数据包,所以整包型系统数据包的版本信息中可以仅包含一个版本号,即该系统数据包的版本号;由于差分包型系统数据包是差分的、必须基于某版本系统才能进行升级的数据包,所以差分包型系统数据包的版本信息需要包括两个版本号,即原始版本号和目标版本号。其中,原始版本号用于表示利用该系统数据包实现系统升级必须基于的系统的版本号,即终端当前系统的版本号必须与原始版本号相同,才能使用该系统数据包成功升级;目标版本号用于表示利用该系统数据包升级后的系统的版本号,即该系统数据包的版本号。
需要说明的是,整包型系统数据包的版本信息中也可以包括原始版本号和目标版本号,但是原始版本号与目标版本号相同且均为该系统数据包的版本号。
进一步的,如图3所示,该装置还包括:
第二确定单元25,用于确定本次系统操作为系统降级;
第二确定单元25,用于当系统数据包的版本号低于当前系统的版本号时,确定本次系统操作为系统降级;
进一步的,如图3所示,该装置还包括:
第三确定单元26,用于确定本次系统操作为系统升级;
第三确定单元26,用于当系统数据包的版本号高于当前系统的版本号时,确定本次系统操作为系统升级。
进一步的,系统数据包的版本号存储在目标文件中。
该装置实施例与前述方法实施例对应,为便于阅读,本装置实施例不再对前述方法实施例中的细节内容进行逐一赘述,但应当明确,本实施例中的装置能够对应实现前述方法实施例中的全部内容。
上述系统升降级的装置包括存储器和处理器,上述获取单元、备份单元、和执行单元等均作为程序单元存储在存储器中,由处理器执行存储在存储器中的上述程序单元来实现相应的功能。
以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多 个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性的劳动的情况下,即可以理解并实施。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到各实施方式可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件。基于这样的理解,上述技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品可以存储在计算机可读存储介质中,如ROM/RAM、磁碟、光盘等,包括若干指令用以使得一台计算机设备(可以是个人计算机,服务器,或者网络设备等)执行各个实施例或者实施例的某些部分所述的方法。
最后应说明的是:以上实施例仅用以说明本发明的技术方案,而非对其限制;尽管参照前述实施例对本发明进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本发明各实施例技术方案的精神和范围。

Claims (12)

  1. 一种系统升降级的方法,其特征在于,所述方法包括:
    获取系统数据包;
    当确定所述系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份,其中,所述整包型表示所述系统数据包为完整的、能够独立用于升降级的数据包;
    在对用户数据进行备份后,执行所述系统数据包,以实现系统降级。
  2. 根据权利要求1所述的方法,其特征在于,对用户数据进行备份,包括:
    显示提示信息,所述提示信息用于提示用户是否备份用户数据;
    在接收到确认备份指令后,备份所述用户数据。
  3. 根据权利要求1或2所述的方法,其特征在于,所述方法进一步包括:
    当确定所述系统数据包的数据类型为整包型且确定本次系统操作为系统升级时,执行所述系统数据包,以实现系统升级;
    和/或,当确定所述系统数据包的数据类型为差分包型时,确定本次系统操作为系统升级,并执行所述系统数据包,以实现系统升级,其中,所述差分包型表示所述系统数据包为差分的、必须基于某版本系统才能进行升级的数据包。
  4. 根据权利要求3所述的方法,其特征在于,确定所述系统数据包的数据类型,包括:
    从所述系统数据包中获取目标文件,所述目标文件是在生成系统数据包时,在所述系统数据包中添加的、用于描述所述系统数据包的基本信息的文件;
    解析所述目标文件,确定所述系统数据包的数据类型。
  5. 根据权利要求4所述的方法,其特征在于,确定本次系统操作为系统降级,包括:
    若所述系统数据包的版本号低于当前系统的版本号,则确定所述本次系统操作为系统降级;
    确定本次系统操作为系统升级,包括:
    若所述系统数据包的版本号高于当前系统的版本号,则确定所述本次系统操作为系统升级。
  6. 根据权利要求5所述的方法,其特征在于,所述系统数据包的版本号存储在所述目标文件中。
  7. 一种系统升降级的装置,其特征在于,所述装置包括:
    获取单元,用于获取系统数据包;
    备份单元,用于当确定所述获取单元获取的所述系统数据包的数据类型为整包型且确定本次系统操作为系统降级时,对用户数据进行备份,其中,所述整包型表示所述系统数据包为完整的、能够独立用于升降级的数据包;
    执行单元,用于在所述备份单元对用户数据进行备份后,执行所述系统数据包,以实现系统降级。
  8. 根据权利要求7所述的装置,其特征在于,所述备份单元,包括:
    显示模块,用于显示提示信息,所述提示信息用于提示用户是否备份用户数据;
    备份模块,用于在接收到确认备份指令后,备份所述用户数据。
  9. 根据权利要求7或8所述的装置,其特征在于,所述执行单元,还用于当确定所述获取单元获取的所述系统数据包的数据类型为整包型且确定本次系统操作为系统升级时,执行所述系统数据包,以实现系统升级;和/或,当确定所述获取单元获取的所述系统数据包的数据类型为差分包型时,确定本次系统操作为系统升级,并执行所述系统数据包,以实现系统升级,其中,所述差分包型表示所述系统数据包为差分的、必须基于某版本系统才能进行升级的数据包。
  10. 根据权利要求9所述的装置,其特征在于,所述装置进一步包括:
    第一确定单元,用于确定所述系统数据包的数据类型;
    所述第一确定单元包括:
    获取模块,用于从所述系统数据包中获取目标文件,所述目标文件是在生成系统数据包时,在所述系统数据包中添加的、用于描述所述系统数据包的基本信息的文件;
    确定模块,用于解析所述获取模块获取的所述目标文件,确定所述系统数据包的数据类型。
  11. 根据权利要求10所述的装置,其特征在于,所述装置进一步包括:
    第二确定单元,用于确定本次系统操作为系统降级;
    所述第二确定单元,用于当所述系统数据包的版本号低于当前系统的版本号时,确定所述本次系统操作为系统降级;
    所述装置进一步包括:
    第三确定单元,用于确定本次系统操作为系统升级;
    所述第三确定单元,用于当所述系统数据包的版本号高于当前系统的版本号时,确定所述本次系统操作为系统升级。
  12. 根据权利要求11所述的装置,其特征在于,所述系统数据包的版本号存储在所述目标文件中。
PCT/CN2016/089472 2015-12-07 2016-07-08 系统升降级的方法和装置 Ceased WO2017096889A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US15/246,535 US20170163787A1 (en) 2015-12-07 2016-08-25 Method and electronic device for upgrading or downgrading system

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510888367.6A CN105867961A (zh) 2015-12-07 2015-12-07 系统升降级的方法和装置
CN201510888367.6 2015-12-07

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US15/246,535 Continuation US20170163787A1 (en) 2015-12-07 2016-08-25 Method and electronic device for upgrading or downgrading system

Publications (1)

Publication Number Publication Date
WO2017096889A1 true WO2017096889A1 (zh) 2017-06-15

Family

ID=56624370

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/089472 Ceased WO2017096889A1 (zh) 2015-12-07 2016-07-08 系统升降级的方法和装置

Country Status (2)

Country Link
CN (1) CN105867961A (zh)
WO (1) WO2017096889A1 (zh)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115391179A (zh) * 2022-07-29 2022-11-25 惠州市德赛西威汽车电子股份有限公司 一种升降级自动测试方法及存储介质

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107220345B (zh) * 2017-05-27 2020-09-29 北京酷我科技有限公司 一种App使用的数据库中用户数据保护方法
CN108008967B (zh) * 2017-12-22 2021-05-04 浪潮金融信息技术有限公司 应用程序的版本控制方法及装置、计算机可读存储介质、终端

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7051327B1 (en) * 2001-05-08 2006-05-23 Gateway Inc. System for providing data backup and restore with updated version by creating data package based upon configuration data application data and user response to suggestion
US20100223608A1 (en) * 2009-02-27 2010-09-02 Dehaan Micheal Paul Systems and methods for generating reverse installation file for network restoration
CN102722426A (zh) * 2012-05-24 2012-10-10 四川华立德科技有限公司 手机数据一键备份及恢复系统
CN103559059A (zh) * 2013-11-05 2014-02-05 广东新支点技术服务有限公司 一种快速的免介质Linux系统升级方法
CN104468784A (zh) * 2014-12-05 2015-03-25 北京速通科技有限公司 一种通过dsrc接口实现车载单元软件升级的系统及方法
CN104765657A (zh) * 2015-04-27 2015-07-08 广东欧珀移动通信有限公司 一种数据备份方法、数据恢复方法和相关装置
CN105094873A (zh) * 2014-05-19 2015-11-25 中兴通讯股份有限公司 一种手持终端系统切换方法及装置

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7051327B1 (en) * 2001-05-08 2006-05-23 Gateway Inc. System for providing data backup and restore with updated version by creating data package based upon configuration data application data and user response to suggestion
US20100223608A1 (en) * 2009-02-27 2010-09-02 Dehaan Micheal Paul Systems and methods for generating reverse installation file for network restoration
CN102722426A (zh) * 2012-05-24 2012-10-10 四川华立德科技有限公司 手机数据一键备份及恢复系统
CN103559059A (zh) * 2013-11-05 2014-02-05 广东新支点技术服务有限公司 一种快速的免介质Linux系统升级方法
CN105094873A (zh) * 2014-05-19 2015-11-25 中兴通讯股份有限公司 一种手持终端系统切换方法及装置
CN104468784A (zh) * 2014-12-05 2015-03-25 北京速通科技有限公司 一种通过dsrc接口实现车载单元软件升级的系统及方法
CN104765657A (zh) * 2015-04-27 2015-07-08 广东欧珀移动通信有限公司 一种数据备份方法、数据恢复方法和相关装置

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115391179A (zh) * 2022-07-29 2022-11-25 惠州市德赛西威汽车电子股份有限公司 一种升降级自动测试方法及存储介质

Also Published As

Publication number Publication date
CN105867961A (zh) 2016-08-17

Similar Documents

Publication Publication Date Title
US10742694B2 (en) Method for migrating data and terminal
CN110780930B (zh) 启动Android系统的方法、装置、电子设备及存储介质
WO2017088388A1 (zh) 应用的sdk的升级方法及系统
EP2613259A1 (en) Method and computation node for processing application data
WO2017185954A1 (zh) 一种实现usb设备管理的方法、主机和系统
CN105205142B (zh) 保存日志文件的方法、装置和移动终端
US20170163787A1 (en) Method and electronic device for upgrading or downgrading system
US20190121786A1 (en) Method for Data Migration and Terminal
US20170052773A1 (en) Application installs using remote applications
CN114153665A (zh) 一种基于协议接口的测试方法以及测试装置
CN104951348B (zh) 一种可中断的recovery升级方法及装置
WO2017096889A1 (zh) 系统升降级的方法和装置
CN113986376A (zh) 一种基于Flutter平台的资源文件更新方法及其相关设备
US20230401039A1 (en) Universal code editor
US10007529B2 (en) Data terminal running mode switching method, device, and data terminal
CN108228215A (zh) 终端设备的ota升级包的推送方法及装置
CN104105077A (zh) 一种手机升级方法及装置
WO2020113382A1 (zh) 硬件升级方法、装置、设备和存储介质
WO2014067368A1 (zh) 资源预览图的获取方法、装置以及设备
CN113422791A (zh) 云服务配置方法和装置、电子设备以及计算机可读存储介质
CN109981365A (zh) 数据监听方法、装置、用户设备及存储介质
CN114448791B (zh) 路由模块的配置方法、装置、电子设备及可读存储介质
CN118509426B (zh) 一种客户端目录资源的访问方法、装置及存储介质
US20250286952A1 (en) Call script modification using a troubleshooting log
US9268576B1 (en) Physical replica utilizing replica virtual storage for computer system

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16872089

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16872089

Country of ref document: EP

Kind code of ref document: A1