[go: up one dir, main page]

CN118672934A - Method for testing rollback accuracy of post-factory recovery data in multi-mode scene - Google Patents

Method for testing rollback accuracy of post-factory recovery data in multi-mode scene Download PDF

Info

Publication number
CN118672934A
CN118672934A CN202411170079.2A CN202411170079A CN118672934A CN 118672934 A CN118672934 A CN 118672934A CN 202411170079 A CN202411170079 A CN 202411170079A CN 118672934 A CN118672934 A CN 118672934A
Authority
CN
China
Prior art keywords
rollback
data
scene
mode
index
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.)
Granted
Application number
CN202411170079.2A
Other languages
Chinese (zh)
Other versions
CN118672934B (en
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.)
Jiaxing Jiasai Information Technology Co ltd
Original Assignee
Jiaxing Jiasai Information 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 Jiaxing Jiasai Information Technology Co ltd filed Critical Jiaxing Jiasai Information Technology Co ltd
Priority to CN202411170079.2A priority Critical patent/CN118672934B/en
Publication of CN118672934A publication Critical patent/CN118672934A/en
Application granted granted Critical
Publication of CN118672934B publication Critical patent/CN118672934B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/36Prevention of errors by analysis, debugging or testing of software
    • G06F11/362Debugging of software
    • G06F11/366Debugging of software using diagnostics
    • 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
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/30Computing systems specially adapted for manufacturing

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention relates to the technical field of data rollback testing, in particular to a method for testing the rollback accuracy of post-factory recovery data in a multi-mode scene. The method comprises the following steps: under different mode scenes, respectively acquiring network variation indexes of system data before and after rollback in the factory restoration process; determining a data consistency index according to system data; determining the reliability degree of file change according to data consistency indexes in different mode scenes; determining a parallel test interaction index according to the change of the equipment configuration parameters, and determining the scene change reliability degree of the rollback process by combining the parallel test interaction index and the network change index; determining test indexes of data rollback in a multi-mode scene by combining the file change reliability degree and the scene change reliability degree; and (5) carrying out exception analysis on the factory restoration process according to the test indexes. The method and the device can effectively realize the abnormal analysis of the data rollback process, and improve the suitability and the test effect of the data rollback accuracy test in the multimode scene.

Description

一种多模式场景下恢复出厂后数据回滚准确性测试方法A method for testing the accuracy of data rollback after factory reset in a multi-mode scenario

技术领域Technical Field

本发明涉及数据回滚测试技术领域,具体涉及一种多模式场景下恢复出厂后数据回滚准确性测试方法。The present invention relates to the technical field of data rollback testing, and in particular to a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario.

背景技术Background Art

在当前的计算机系统和数据管理环境中,数据恢复和系统回滚的准确性测试是至关重要的。特别是在多模式场景下,如物联网设备、云计算平台、大型数据中心等复杂环境中,确保在发生故障或需要恢复到出厂设置时数据的完整性和准确性显得尤为重要。数据回滚指的是将系统或设备恢复到其出厂设置时的状态,包括恢复到初始配置、初始数据状态以及初始软件版本等。系统能够正确地将已经存在的数据、配置和软件版本回滚到初始状态或设定状态,以保证系统的可靠性和数据的完整性。In the current computer system and data management environment, accuracy testing of data recovery and system rollback is critical. Especially in multi-mode scenarios, such as complex environments such as IoT devices, cloud computing platforms, and large data centers, it is particularly important to ensure the integrity and accuracy of data when a failure occurs or when it needs to be restored to factory settings. Data rollback refers to restoring a system or device to its factory settings, including restoring to the initial configuration, initial data state, and initial software version. The system can correctly roll back existing data, configurations, and software versions to the initial state or set state to ensure system reliability and data integrity.

现有方法通常针对特定类型的数据或特定的系统环境下进行优化,这种方式下,由于现代系统架构往往是分布式的、异构的,涉及多个硬件平台和软件组件的复杂组合,多模式场景中每个模式场景均具有对应的配置要求、网络要求以及文件形式要求,且不同的模式场景在同一设备中也会互相影响,由此,会导致在多模式场景下数据回滚准确性测试的适配性较差,测试效果不足。Existing methods are usually optimized for specific types of data or specific system environments. In this way, since modern system architectures are often distributed and heterogeneous, involving a complex combination of multiple hardware platforms and software components, each mode scenario in the multi-mode scenario has corresponding configuration requirements, network requirements, and file format requirements, and different mode scenarios will also affect each other in the same device. As a result, the adaptability of data rollback accuracy testing in multi-mode scenarios is poor and the test effect is insufficient.

发明内容Summary of the invention

为了解决在多模式场景下数据回滚准确性测试的适配性较差,测试效果不足的技术问题,本发明提供一种多模式场景下恢复出厂后数据回滚准确性测试方法,所采用的技术方案具体如下:In order to solve the technical problems of poor adaptability and insufficient test effect of data rollback accuracy test in multi-mode scenarios, the present invention provides a method for testing the accuracy of data rollback after factory restoration in multi-mode scenarios. The technical scheme adopted is as follows:

本发明提出了一种多模式场景下恢复出厂后数据回滚准确性测试方法,方法包括:The present invention proposes a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario, the method comprising:

在不同模式场景下,分别获取恢复出厂过程中回滚前与回滚后的系统数据,以及回滚过程中的网络变动指标,其中,所述系统数据包括文件数量、文件大小、文件时间戳和设备配置参数;In different mode scenarios, the system data before and after the rollback during the factory restore process, as well as the network change indicators during the rollback process, are obtained respectively, wherein the system data includes the number of files, file size, file timestamp, and device configuration parameters;

根据同一模式场景下回滚前后同名文件的文件数量、文件大小和文件时间戳差异,确定每一模式场景回滚过程的数据一致性指标;针对不同模式场景下的数据一致性指标,确定多模式场景下数据回滚的文件变化可靠程度;Determine the data consistency index of the rollback process for each mode scenario based on the number of files, file size, and file timestamp differences of the same-name files before and after rollback in the same mode scenario; determine the reliability of file changes in data rollback in multi-mode scenarios based on the data consistency index in different mode scenarios;

根据任一模式场景与其他模式场景在回滚前后设备配置参数的变化,确定每一模式场景的并行测试交互指标,结合所述并行测试交互指标和所述网络变动指标,确定所述回滚过程的场景变化可靠程度;Determine the parallel test interaction index of each mode scenario according to the changes in device configuration parameters of any mode scenario and other mode scenarios before and after rollback, and determine the reliability of the scenario change in the rollback process by combining the parallel test interaction index and the network change index;

结合所述文件变化可靠程度和所述场景变化可靠程度,确定多模式场景下数据回滚的测试指标;根据所述测试指标实现恢复出厂过程的异常分析。In combination with the reliability of the file change and the reliability of the scenario change, the test index of data rollback in the multi-mode scenario is determined; and the abnormal analysis of the factory recovery process is implemented according to the test index.

进一步地,所述模式场景回滚过程的数据一致性指标的获取方法,包括:Furthermore, the method for obtaining the data consistency index of the mode scenario rollback process includes:

对回滚前与回滚后的文件进行一对一同名匹配,确定已匹配的文件对和未匹配的文件;Perform one-to-one same-name matching on the files before and after the rollback to determine matched file pairs and unmatched files;

将所述文件对中两个文件大小的差异,作为大小差异因子;Taking the difference in the sizes of the two files in the file pair as a size difference factor;

将所述文件对中两个文件的文件时间戳的差异,作为时间差异因子;Taking the difference between the file timestamps of the two files in the file pair as a time difference factor;

将所有未匹配的文件的数量,作为数量差异因子;The number of all unmatched files is used as the quantity difference factor;

结合所述大小差异因子、所述时间差异因子和所述数量差异因子,得到对应模式场景回滚过程的数据一致性指标。The size difference factor, the time difference factor and the quantity difference factor are combined to obtain a data consistency index of the rollback process of the corresponding mode scenario.

进一步地,所述结合所述大小差异因子、所述时间差异因子和所述数量差异因子,得到对应模式场景回滚过程的数据一致性指标,包括:Furthermore, the data consistency index of the rollback process of the corresponding mode scenario is obtained by combining the size difference factor, the time difference factor and the quantity difference factor, including:

计算所述大小差异因子、所述时间差异因子和所述数量差异因子的乘积,得到回滚差异指标;Calculate the product of the size difference factor, the time difference factor and the quantity difference factor to obtain a rollback difference index;

对所述回滚差异指标进行负相关的归一化处理,得到数据一致性指标。The rollback difference index is subjected to negative correlation normalization processing to obtain a data consistency index.

进一步地,所述多模式场景下数据回滚的文件变化可靠程度的获取方法,包括:Furthermore, the method for obtaining the reliability of file changes for data rollback in the multi-mode scenario includes:

计算所有模式场景下数据一致性指标的均值,并进行归一化得到回滚一致性系数;Calculate the mean of the data consistency index in all mode scenarios and normalize it to obtain the rollback consistency coefficient;

将任意两个不同模式场景下数据一致性指标的差值绝对值作为对应两个不同模式场景的模式一致性差异;计算所有模式场景的所述模式一致性差异的均值,得到多模式差异均值;The absolute value of the difference between the data consistency indexes in any two different mode scenarios is taken as the mode consistency difference corresponding to the two different mode scenarios; the mean of the mode consistency difference of all mode scenarios is calculated to obtain the multi-mode difference mean;

对所述多模式差异均值进行负相关映射并归一化处理,得到回滚稳定性系数;Performing negative correlation mapping and normalization processing on the multi-mode difference means to obtain a rollback stability coefficient;

正向融合所述回滚一致性系数和所述回滚稳定性系数,得到多模式场景下数据回滚的文件变化可靠程度。The rollback consistency coefficient and the rollback stability coefficient are forwardly integrated to obtain the reliability of file changes in data rollback in a multi-mode scenario.

进一步地,对所述多模式差异均值进行负相关映射并归一化处理,得到回滚稳定性系数,包括:Furthermore, negative correlation mapping is performed on the multi-mode difference means and normalized to obtain a rollback stability coefficient, including:

将所述多模式差异均值的负数进行最大最小值归一化处理,得到回滚稳定性系数。The negative number of the multi-mode difference mean is normalized to the maximum and minimum values to obtain the rollback stability coefficient.

进一步地,所述设备配置参数包括子网掩码,所述模式场景的并行测试交互指标的获取方法,包括:Furthermore, the device configuration parameters include a subnet mask, and the method for obtaining the parallel test interaction index of the mode scenario includes:

将任一模式场景作为待测场景,将所述待测场景与其他每一模式场景在数据回滚前的子网掩码数值差异进行求均,得到回滚前掩码变化系数;Take any mode scenario as the scenario to be tested, average the difference in subnet mask values between the scenario to be tested and each other mode scenario before data rollback, and obtain the mask change coefficient before rollback;

将所述待测场景与其他每一模式场景在数据回滚后的子网掩码数值差异进行求均,得到回滚后掩码变化系数;Averaging the difference in subnet mask values between the scenario to be tested and each other mode scenario after data rollback to obtain a mask change coefficient after rollback;

计算所述回滚前掩码变化系数和所述回滚后掩码变化系数的差值,并进行最大最小值归一化处理得到并行测试交互指标。The difference between the mask change coefficient before the rollback and the mask change coefficient after the rollback is calculated, and a maximum and minimum value normalization process is performed to obtain a parallel test interaction index.

进一步地,所述网络变动指标包括网络延迟时长,结合所述并行测试交互指标和所述网络变动指标,确定所述回滚过程的场景变化可靠程度,包括:Furthermore, the network change index includes a network delay duration, and the reliability of the scene change of the rollback process is determined by combining the parallel test interaction index and the network change index, including:

计算每一模式场景下所述并行测试交互指标和对应网络延迟时长的乘积,对该乘积值求负数并进行最大最小值归一化处理,得到模式场景的目标变化程度;Calculate the product of the parallel test interaction index and the corresponding network delay duration in each mode scenario, negate the product value and perform maximum and minimum value normalization processing to obtain the target change degree of the mode scenario;

将所有模式场景的目标变化程度的均值作为回滚过程的场景变化可靠程度。The mean of the target change degrees of all mode scenarios is taken as the reliability of the scenario change in the rollback process.

进一步地,结合所述文件变化可靠程度和所述场景变化可靠程度,确定多模式场景下数据回滚的测试指标,包括:Furthermore, combining the reliability of the file change and the reliability of the scenario change, the test index of data rollback in the multi-mode scenario is determined, including:

计算所述文件变化可靠程度和所述场景变化可靠程度的乘积,作为多模式场景下数据回滚的测试指标。The product of the file change reliability and the scene change reliability is calculated as a test indicator for data rollback in a multi-mode scene.

进一步地,根据所述测试指标实现恢复出厂过程的异常分析,包括:Furthermore, an abnormal analysis of the factory recovery process is performed according to the test indicators, including:

在所述测试指标大于预设指标阈值时,确定所述数据回滚操作正常;否则,确定所述数据回滚操作异常。When the test indicator is greater than a preset indicator threshold, it is determined that the data rollback operation is normal; otherwise, it is determined that the data rollback operation is abnormal.

进一步地,所述预设指标阈值为0.3。Furthermore, the preset indicator threshold is 0.3.

本发明具有如下有益效果:The present invention has the following beneficial effects:

本发明实施例通过获取不同模式场景下恢复出厂过程中回滚前与回滚后的系统数据以及回滚过程中的网络变动指标,从而对多模式场景进行数据回滚分析,相较于单模式场景的回滚分析,多模式场景由于涉及到不同模式场景可能产生的联动,以及不同模式场景的配置区别,从而导致直接根据单模式场景的回滚文件分析的准确较低,由此,本发明实施例通过文件数量、文件大小、文件时间戳几个维度从而确定数据回滚的文件变化可靠程度,则文件变化可靠程度能够有效表征数据回滚过程中是否存在数据的残留或者丢失的异常情况;之后,获取并行测试交互指标和网络变动指标,确定回滚过程的场景变化可靠程度,则场景变化可靠程度能够准确表征回滚过程中的网络环境变化特征,进而结合多场景的文件变化和多模式场景数据回滚时网络的变化情况,获得最终的测试指标,该测试指标即为考虑到多模式场景的复杂性和网络波动所得到的指标信息,能够有效实现数据回滚过程的异常分析,提升多模式场景下数据回滚准确性测试的适配性和测试效果。The embodiment of the present invention obtains system data before and after rollback and network change indicators during the rollback process in different mode scenarios, thereby performing data rollback analysis on the multi-mode scenario. Compared with the rollback analysis of the single-mode scenario, the multi-mode scenario involves possible linkages between different mode scenarios and configuration differences between different mode scenarios, resulting in lower accuracy of the rollback file analysis directly based on the single-mode scenario. Therefore, the embodiment of the present invention determines the file change reliability of data rollback through the dimensions of file quantity, file size, and file timestamp. The file change reliability can effectively characterize whether there is an abnormal situation of data residue or loss during the data rollback process; then, the parallel test interaction index and the network change index are obtained to determine the scene change reliability of the rollback process. The scene change reliability can accurately characterize the network environment change characteristics during the rollback process, and then combine the file changes in multiple scenarios and the network changes during the data rollback of the multi-mode scenario to obtain the final test index. The test index is the index information obtained by considering the complexity of the multi-mode scenario and the network fluctuation, which can effectively realize the abnormal analysis of the data rollback process and improve the adaptability and test effect of the data rollback accuracy test in the multi-mode scenario.

附图说明BRIEF DESCRIPTION OF THE DRAWINGS

为了更清楚地说明本发明实施例或现有技术中的技术方案和优点,下面将对实施例或现有技术描述中所需要使用的附图作简单的介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它附图。In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

图1为本发明一个实施例所提供的一种多模式场景下恢复出厂后数据回滚准确性测试方法流程图;FIG1 is a flow chart of a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by an embodiment of the present invention;

图2为本发明一个实施例所提供的一种多模式场景下恢复出厂后数据回滚准确性测试系统的结构图。FIG2 is a structural diagram of a system for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by an embodiment of the present invention.

具体实施方式DETAILED DESCRIPTION

为了更进一步阐述本发明为达成预定发明目的所采取的技术手段及功效,以下结合附图及较佳实施例,对依据本发明提出的一种多模式场景下恢复出厂后数据回滚准确性测试方法,其具体实施方式、结构、特征及其功效,详细说明如下。在下述说明中,不同的“一个实施例”或“另一个实施例”指的不一定是同一实施例。此外,一或多个实施例中的特定特征、结构或特点可由任何合适形式组合。In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined purpose of the invention, the following is a detailed description of the specific implementation method, structure, features and effects of a method for testing the accuracy of data rollback after factory recovery in a multi-mode scenario proposed by the present invention, in combination with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.

除非另有定义,本文所使用的所有的技术和科学术语与属于本发明的技术领域的技术人员通常理解的含义相同。Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs.

下面结合附图具体的说明本发明所提供的一种多模式场景下恢复出厂后数据回滚准确性测试方法的具体方案。The following is a detailed description of a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by the present invention in conjunction with the accompanying drawings.

请参阅图1,其示出了本发明一个实施例提供的一种多模式场景下恢复出厂后数据回滚准确性测试方法流程图,该方法包括:Please refer to FIG. 1 , which shows a flow chart of a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by an embodiment of the present invention. The method includes:

S101:在不同模式场景下,分别获取恢复出厂过程中回滚前与回滚后的系统数据,以及回滚过程中的网络变动指标,其中,系统数据包括文件数量、文件大小、文件时间戳和设备配置参数。S101: Under different mode scenarios, respectively obtain system data before and after rollback during factory recovery, and network change indicators during the rollback process, wherein the system data includes file quantity, file size, file timestamp, and device configuration parameters.

本发明实施例的实施场景包括:恢复出厂后的数据回滚场景,多模式场景通常指的是测试在不同的操作模式或环境条件下进行,包括但不限于:正常模式、安全模式、恢复模式、虚拟化环境、故障恢复模式等。The implementation scenarios of the embodiments of the present invention include: data rollback scenarios after factory restoration, and multi-mode scenarios generally refer to tests performed under different operating modes or environmental conditions, including but not limited to: normal mode, safe mode, recovery mode, virtualized environment, fault recovery mode, etc.

需要说明的是,现有的测试方法可能未能覆盖所有可能的恢复模式和场景,导致部分数据或功能未被测试到,缺乏全面的验证方法来确保恢复的数据和设备状态的准确性和一致性。且现代系统往往是分布式的、异构的,涉及多个硬件平台和软件组件的复杂组合,而系统架构的复杂性增加不同模式场景下的数据管理和恢复的难度,由此,需要针对不同模式场景下的情况实现数据回滚的准确测试。It should be noted that existing testing methods may not cover all possible recovery modes and scenarios, resulting in some data or functions not being tested, and lack of comprehensive verification methods to ensure the accuracy and consistency of recovered data and device status. In addition, modern systems are often distributed and heterogeneous, involving a complex combination of multiple hardware platforms and software components. The complexity of the system architecture increases the difficulty of data management and recovery in different modes and scenarios. Therefore, it is necessary to accurately test data rollback in different modes and scenarios.

其中,恢复出厂即为数据恢复至刚出厂的预设状态,需要说明的是,数据恢复仅表征对用户使用过程所产生的数据进行删除和恢复,针对系统文件整体的变化较小,因此,通过对系统数据和回滚过程中的网络变动指标进行具体分析,能够有效判断数据回滚效果。Among them, factory restore means restoring the data to the preset state when it just leaves the factory. It should be noted that data recovery only represents the deletion and recovery of data generated during the user's use process, and the overall changes to the system files are small. Therefore, by conducting a specific analysis of the system data and network change indicators during the rollback process, the data rollback effect can be effectively judged.

其中,系统数据包括文件数量、文件大小、文件时间戳和设备配置参数。文件时间戳即为文件产生变化时所记录的时间点,而网络变动指标即为回滚过程中的网络延迟、丢包等指标信息,这类信息的获取均是针对回滚前后的系统进行分析获取,对此不做限制。Among them, system data includes file quantity, file size, file timestamp and device configuration parameters. File timestamp is the time point recorded when the file changes, and network change indicators are network delay, packet loss and other indicator information during the rollback process. This type of information is obtained by analyzing the system before and after the rollback, and there is no restriction on this.

S102:根据同一模式场景下回滚前后同名文件的文件数量、文件大小和文件时间戳差异,确定每一模式场景回滚过程的数据一致性指标;针对不同模式场景下的数据一致性指标,确定多模式场景下数据回滚的文件变化可靠程度。S102: Determine the data consistency index of the rollback process of each mode scenario based on the number of files, file sizes and file timestamp differences of the files with the same name before and after the rollback in the same mode scenario; determine the reliability of file changes in data rollback in multi-mode scenarios based on the data consistency indexes in different mode scenarios.

其中,同名文件,即为文件名相同的文件,需要说明的是,由于整体系统架构为多层架构,也即文件夹内包含有文件夹的层层嵌套式架构,由此,本发明将每一文件夹作为一个完整的个体进行分析,也即对应的文件大小即为文件夹所包含所有数据的大小,则对应的同名文件夹即表示名称相同的文件夹,例如在回滚前后系统均会有“tool”文件夹,则将回滚前后“tool”文件夹作为同名文件,则对应的部分同名文件会产生变化,也有未产生数据变化的情况。再需要说明的是,由于系统中可能包含有多个同名文件夹,例如data文件夹,由此,本发明实施例的同名文件夹也有相同文件位置的含义,也即文件位置未发生变化,且文件名相同的文件夹为同名文件夹;因此,本发明实施例中根据同一模式场景下回滚前后同名文件的文件数量、文件大小和文件时间戳差异,确定每一模式场景回滚过程的数据一致性指标。Among them, the same-name files are files with the same file name. It should be noted that since the overall system architecture is a multi-layer architecture, that is, a nested architecture in which folders are contained within folders, the present invention analyzes each folder as a complete individual, that is, the corresponding file size is the size of all data contained in the folder, and the corresponding same-name folders represent folders with the same name. For example, the system will have a "tool" folder before and after the rollback, and the "tool" folders before and after the rollback will be treated as files with the same name, and the corresponding part of the same-name files will change, and there will also be cases where no data changes occur. It should be further noted that since the system may contain multiple folders with the same name, such as a data folder, the same-name folders in the embodiment of the present invention also have the meaning of the same file location, that is, the file location has not changed, and the folders with the same file name are the same-name folders; therefore, in the embodiment of the present invention, the data consistency index of the rollback process of each mode scenario is determined according to the number of files, file size and file timestamp differences of the same-name files before and after the rollback in the same mode scenario.

进一步地,在本发明的一些实施例中,模式场景回滚过程的数据一致性指标的获取方法,包括:对回滚前与回滚后的文件进行一对一同名匹配,确定已匹配的文件对和未匹配的文件;将文件对中两个文件大小的差异,作为大小差异因子;将文件对中两个文件的文件时间戳的差异,作为时间差异因子;将所有未匹配的文件的数量,作为数量差异因子;结合大小差异因子、时间差异因子和数量差异因子,得到对应模式场景回滚过程的数据一致性指标。Furthermore, in some embodiments of the present invention, a method for obtaining data consistency indicators of a pattern scenario rollback process includes: performing one-to-one same-name matching on files before and after the rollback to determine matched file pairs and unmatched files; taking the difference in size between two files in the file pair as a size difference factor; taking the difference in file timestamps between the two files in the file pair as a time difference factor; taking the number of all unmatched files as a number difference factor; and combining the size difference factor, the time difference factor, and the number difference factor to obtain a data consistency indicator of the corresponding pattern scenario rollback process.

需要注意的是,为保证计算结果有意义,在包含有具体的分式计算时,为防止分母为0,在分母出现0的情况下,通过对分母添加调参因子以规避为0的情况,调参因子的数值由实施者根据实际情况自行设定,例如0.01,本申请不做特殊限制。It should be noted that in order to ensure that the calculation results are meaningful, when specific fractional calculations are involved, in order to prevent the denominator from being 0, when the denominator is 0, a parameter adjustment factor is added to the denominator to avoid the situation where it is 0. The value of the parameter adjustment factor is set by the implementer according to the actual situation, for example 0.01, and this application does not impose any special restrictions.

需要说明的是,为了方便运算,本发明实施例中所参与运算的所有指标数据均经过数据预处理,进而取消量纲影响。具体去量纲影响的手段为本领域技术人员熟知的技术手段,在此不做限定。It should be noted that, in order to facilitate calculation, all indicator data involved in the calculation in the embodiment of the present invention are preprocessed to eliminate the dimension effect. The specific means of eliminating the dimension effect are technical means well known to those skilled in the art and are not limited here.

其中,数据一致性指标,即为回滚前后数据的一致性程度,可以理解的是,验证设备某个场景模式恢复出厂后该场景模式的用户数据是否被准确还原的功能。若执行过程中发现文件夹数据变化较多,则表示产生了额外的数据删减增改,进而表示受到了执行恢复出厂的模式的影响。The data consistency index is the consistency of the data before and after the rollback. It can be understood that it is a function to verify whether the user data of a scene mode is accurately restored after the device is restored to factory mode. If a lot of folder data changes are found during the execution process, it means that additional data deletion, addition and modification have occurred, which means that the mode of factory restoration has been affected.

其中,将文件对中两个文件大小的差异,作为大小差异因子,文件大小,即为文件中数据的内存占用量,其具体符号为kb,也即将两个文件占用内存的数值差异,作为大小差异因子。The difference in the sizes of the two files in the file pair is used as the size difference factor. The file size is the memory usage of the data in the file, and its specific symbol is kb. That is, the numerical difference in the memory usage of the two files is used as the size difference factor.

本发明实施例中,差异,具体表示为两个数值之间的差异特征,可以计算两个数值之间的差值绝对值,从而表示差异,也即文件对中两个文件大小的差异,表示两个文件占用内存的数值的差值绝对值,其他差异计算同理,对此不做赘述。In the embodiment of the present invention, the difference is specifically expressed as a difference feature between two numerical values. The absolute value of the difference between the two numerical values can be calculated to represent the difference, that is, the difference in the sizes of two files in the file pair, which represents the absolute value of the difference in the numerical values occupied by the two files in memory. Other differences are calculated in the same way and will not be elaborated on here.

其中,将文件对中两个文件的文件时间戳的差异,作为时间差异因子,由于文件时间戳表示文件产生变化时所记录的时间点,则对应的时间差异因子表示两个文件产生变化的时间差,时间差异因子越大,表示对应的进行数据回滚前后的时间差越大,也即数据产生变化的情况更多且更复杂,整体回滚过程也易由于持续时间过长产生异常,由此,本发明实施例通过时间差异因子对该特征的分析。Among them, the difference in file timestamps of the two files in the file pair is used as the time difference factor. Since the file timestamp represents the time point recorded when the file changes, the corresponding time difference factor represents the time difference between the two files. The larger the time difference factor, the larger the corresponding time difference before and after the data rollback, that is, the more and more complicated the data changes, and the overall rollback process is also prone to abnormalities due to excessive duration. Therefore, the embodiment of the present invention analyzes this feature through the time difference factor.

其中,将所有未匹配的文件的数量,作为数量差异因子,未匹配的文件,即为数据回滚前拥有,但是回滚后消失,或者数据回滚前没有,回滚后所产生的文件,该文件数量越多,越表示对应过程的复杂度越高。Among them, the number of all unmatched files is used as the quantity difference factor. The unmatched files are files that existed before the data rollback but disappeared after the rollback, or files that did not exist before the data rollback but were generated after the rollback. The more the number of these files, the higher the complexity of the corresponding process.

由此,本发明结合大小差异因子、时间差异因子和数量差异因子,得到对应模式场景回滚过程的数据一致性指标。Therefore, the present invention combines the size difference factor, the time difference factor and the quantity difference factor to obtain the data consistency index of the rollback process of the corresponding mode scenario.

进一步地,在本发明的一些实施例中,计算大小差异因子、时间差异因子和数量差异因子的乘积,得到回滚差异指标;对回滚差异指标进行负相关的归一化处理,得到数据一致性指标。Furthermore, in some embodiments of the present invention, the product of the size difference factor, the time difference factor and the quantity difference factor is calculated to obtain a rollback difference index; the rollback difference index is negatively correlated and normalized to obtain a data consistency index.

由于大小差异因子、时间差异因子和数量差异因子的数值越大,均表示对应回滚前后的产生较大的数据复杂度变化,由此,回滚差异指标的数值越大,表示回滚前后数据变化越大,进行负相关归一化得到数据一致性指标。Since the larger the values of the size difference factor, time difference factor, and quantity difference factor are, the larger the data complexity changes before and after the corresponding rollback are, the larger the value of the rollback difference index is, the greater the data changes before and after the rollback are, and the data consistency index is obtained by negative correlation normalization.

需要说明的是,正相关关系表示自变量与因变量之间存在自变量越大,因变量就越大的同向变化关系;负相关关系表示自变量与因变量之间存在自变量越小,因变量反而越大的反向变化关系;正相关关系与负相关关系的具体表现形式,由实际应用进行确定,本申请不做特殊限制。It should be noted that a positive correlation indicates that there is a same-direction change relationship between the independent variable and the dependent variable, that is, the larger the independent variable is, the larger the dependent variable is; a negative correlation indicates that there is an inverse change relationship between the independent variable and the dependent variable, that is, the smaller the independent variable is, the larger the dependent variable is; the specific manifestations of the positive correlation and the negative correlation are determined by actual applications, and this application does not impose any special restrictions.

由此,本发明实施例中可以计算回滚差异指标的负数值,并对该负数进行最大最小值归一化,得到数据一致性指标,或者,也可以计算回滚差异指标的倒数,对该倒数进行线性归一化得到数据一致性指标,对此不做限制。Therefore, in an embodiment of the present invention, the negative value of the rollback difference index can be calculated, and the negative value can be normalized by the maximum and minimum values to obtain the data consistency index, or the inverse of the rollback difference index can be calculated, and the inverse can be linearly normalized to obtain the data consistency index, and there is no limitation on this.

可以理解的是,数据一致性指标能够准确表征回滚前后数据的一致性程度,为了避免单一模式场景的影响,本发明实施例可以结合所有模式场景分别获取其对应的数据一致性指标,实现文件变化可靠程度的分析。It is understandable that the data consistency index can accurately characterize the consistency degree of data before and after rollback. In order to avoid the influence of a single mode scenario, the embodiment of the present invention can combine all mode scenarios to obtain their corresponding data consistency indicators respectively, so as to realize the analysis of the reliability of file changes.

进一步地,在本发明的一些实施例中,多模式场景下数据回滚的文件变化可靠程度的获取方法,包括:计算所有模式场景下数据一致性指标的均值,并进行归一化得到回滚一致性系数;将任意两个不同模式场景下数据一致性指标的差值绝对值作为对应两个不同模式场景的模式一致性差异;计算所有模式场景的模式一致性差异的均值,得到多模式差异均值;对多模式差异均值进行负相关映射并归一化处理,得到回滚稳定性系数;正向融合回滚一致性系数和回滚稳定性系数,得到多模式场景下数据回滚的文件变化可靠程度。Furthermore, in some embodiments of the present invention, a method for obtaining the reliability of file changes in data rollback in a multi-mode scenario includes: calculating the mean of the data consistency index in all mode scenarios, and normalizing it to obtain a rollback consistency coefficient; taking the absolute value of the difference between the data consistency index in any two different mode scenarios as the mode consistency difference corresponding to the two different mode scenarios; calculating the mean of the mode consistency differences of all mode scenarios to obtain a multi-mode difference mean; performing negative correlation mapping on the multi-mode difference mean and normalizing it to obtain a rollback stability coefficient; forwardly fusing the rollback consistency coefficient and the rollback stability coefficient to obtain the reliability of file changes in data rollback in the multi-mode scenario.

需要说明的是,结合所有场景分析时,不仅需要分析对应数据一致性指标的总体数值大小,还需要对整体的稳定性进行分析,由此,本发明实施例通过计算回滚稳定性系数,从而对不同模式场景下的回滚状态的稳定性进行分析。It should be noted that when analyzing all scenarios, it is necessary not only to analyze the overall numerical size of the corresponding data consistency index, but also to analyze the overall stability. Therefore, the embodiment of the present invention calculates the rollback stability coefficient to analyze the stability of the rollback state under different mode scenarios.

本发明实施例中,对多模式差异均值进行负相关映射并归一化处理,得到回滚稳定性系数,包括:将多模式差异均值的负数进行最大最小值归一化处理,得到回滚稳定性系数。In an embodiment of the present invention, negative correlation mapping is performed on the multi-mode difference means and normalized to obtain a rollback stability coefficient, including: normalizing the negative number of the multi-mode difference means to the maximum and minimum values to obtain the rollback stability coefficient.

也即是说,本发明实施例通过求负数的形式实现负相关映射,并使用最大最小值归一化的方式实现归一化处理,进而得到回滚稳定性系数。That is to say, the embodiment of the present invention realizes negative correlation mapping by obtaining negative numbers, and realizes normalization processing by using the maximum and minimum value normalization method, thereby obtaining the rollback stability coefficient.

回滚稳定系数能够表征数据回滚在不同模式场景下的稳定型特征,正向融合回滚一致性系数和回滚稳定性系数,得到多模式场景下数据回滚的文件变化可靠程度。则本发明实施例中的正向融合,即为对应正相关的数值融合,本发明实施例中可以计算回滚一致性系数和回滚稳定性系数的乘积,作为文件变化可靠程度,或者,也可以计算回滚一致性系数和回滚稳定性系数的和值,作为文件变化可靠程度,对此不做限制。The rollback stability coefficient can characterize the stability characteristics of data rollback in different mode scenarios. The rollback consistency coefficient and the rollback stability coefficient are forward integrated to obtain the reliability of file changes in data rollback in multi-mode scenarios. The forward integration in the embodiment of the present invention is the corresponding positively correlated numerical integration. In the embodiment of the present invention, the product of the rollback consistency coefficient and the rollback stability coefficient can be calculated as the reliability of file changes, or the sum of the rollback consistency coefficient and the rollback stability coefficient can be calculated as the reliability of file changes. There is no limitation on this.

S103:根据任一模式场景与其他模式场景在回滚前后设备配置参数的变化,确定每一模式场景的并行测试交互指标,结合并行测试交互指标和网络变动指标,确定回滚过程的场景变化可靠程度。S103: Determine the parallel test interaction index of each mode scenario according to the changes in device configuration parameters of any mode scenario and other mode scenarios before and after rollback, and determine the reliability of the scenario change in the rollback process by combining the parallel test interaction index and the network change index.

其中,设备配置参数为对应子网掩码,由于在进行数据回滚时,会产生网络识别的变化,也即产生子网掩码的变化,子网掩码一般情况下其变化是按照顺序进行数值增加,由此,在子网掩码数值变化波动较大时,也即产生多次网络变化,则对应的表示多模式场景下进行并行测试的网络变化过程较为复杂,由此,得到并行测试交互指标表征网络变化过程的复杂程度。Among them, the device configuration parameter is the corresponding subnet mask. When the data is rolled back, changes will occur in the network identification, that is, changes will occur in the subnet mask. Under normal circumstances, the subnet mask changes in numerical value in sequence. Therefore, when the subnet mask value fluctuates greatly, that is, multiple network changes occur, the corresponding network change process for parallel testing in multi-mode scenarios is more complicated. Therefore, the parallel test interaction index is obtained to characterize the complexity of the network change process.

进一步地,在本发明的一些实施例中,将任一模式场景作为待测场景,将待测场景与其他每一模式场景在数据回滚前的子网掩码数值差异进行求均,得到回滚前掩码变化系数;将待测场景与其他每一模式场景在数据回滚后的子网掩码数值差异进行求均,得到回滚后掩码变化系数;计算回滚前掩码变化系数和回滚后掩码变化系数的差值,并进行最大最小值归一化处理得到并行测试交互指标。Furthermore, in some embodiments of the present invention, any mode scenario is taken as the scenario to be tested, and the difference in subnet mask values between the scenario to be tested and each other mode scenario before data rollback is averaged to obtain the mask change coefficient before rollback; the difference in subnet mask values between the scenario to be tested and each other mode scenario after data rollback is averaged to obtain the mask change coefficient after rollback; the difference between the mask change coefficient before rollback and the mask change coefficient after rollback is calculated, and the maximum and minimum value normalization processing is performed to obtain the parallel test interaction index.

通过计算回滚前掩码变化系数得到回滚前的子网掩码的数值分布,计算回滚后掩码变化系数,得到回滚后的子网掩码的数值分布,进而分析其数值分布差异,得到并行测试交互指标,也即并行测试交互指标的数值越大,则子网掩码的变化越大,也即数据产生较为复杂的子网掩码变化情况。By calculating the mask change coefficient before rollback, the numerical distribution of the subnet mask before rollback is obtained. By calculating the mask change coefficient after rollback, the numerical distribution of the subnet mask after rollback is obtained. Then, the difference in numerical distribution is analyzed to obtain the parallel test interaction index. That is, the larger the value of the parallel test interaction index, the greater the change of the subnet mask, that is, the data produces more complex subnet mask changes.

本发明实施例中的网络变动指标可以具体为网络延迟时长,也即通过网络延迟时长进行具体分析。The network variation index in the embodiment of the present invention may specifically be the network delay duration, that is, specific analysis is performed through the network delay duration.

进一步地,在本发明的一些实施例中,结合并行测试交互指标和网络变动指标,确定回滚过程的场景变化可靠程度,包括:计算每一模式场景下并行测试交互指标和对应网络延迟时长的乘积,对该乘积值求负数并进行最大最小值归一化处理,得到模式场景的目标变化程度;将所有模式场景的目标变化程度的均值作为回滚过程的场景变化可靠程度。Furthermore, in some embodiments of the present invention, the parallel test interaction index and the network change index are combined to determine the reliability of the scene change in the rollback process, including: calculating the product of the parallel test interaction index and the corresponding network delay duration in each mode scenario, negating the product value and performing maximum and minimum value normalization processing to obtain the target change degree of the mode scenario; and taking the average of the target change degrees of all mode scenarios as the reliability of the scene change in the rollback process.

需要说明的是,网络延迟时长越大,则表示对应网络变化越复杂,极易产生回滚异常,或者极易由于回滚异常导致复杂的网络变化,由此,计算每一模式场景下并行测试交互指标和对应网络延迟时长的乘积,对该乘积值求负数并进行最大最小值归一化处理,得到模式场景的目标变化程度,则目标变化程度数值越大,表示网络波动越小,由此,计算所有模式场景的目标变化程度的均值作为回滚过程的场景变化可靠程度。It should be noted that the longer the network delay time is, the more complex the corresponding network changes are, which is prone to rollback anomalies, or it is prone to complex network changes due to rollback anomalies. Therefore, the product of the parallel test interaction index and the corresponding network delay time is calculated in each mode scenario, the product value is negative and normalized to the maximum and minimum values to obtain the target change degree of the mode scenario. The larger the target change degree value is, the smaller the network fluctuation is. Therefore, the average value of the target change degree of all mode scenarios is calculated as the reliability of the scene change in the rollback process.

S104:结合文件变化可靠程度和场景变化可靠程度,确定多模式场景下数据回滚的测试指标;根据测试指标实现恢复出厂过程的异常分析。S104: Determine test indicators for data rollback in multi-mode scenarios based on the reliability of file changes and the reliability of scenario changes; and perform abnormal analysis of the factory recovery process based on the test indicators.

其中,文件变化可靠程度是在回滚数据的维度上进行可靠性分析,而场景变化可靠程度是在整体网络变化场景上进行可靠性分析,由此,本发明结合文件变化可靠程度和场景变化可靠程度,实现整体数据回滚的测试。避免仅根据单一模式下数据回滚情况进行整体数据回滚的测试,保证数据回滚的多场景稳定性,以及复杂系统的适用效果。Among them, the reliability of file changes is a reliability analysis based on the dimension of rollback data, while the reliability of scene changes is a reliability analysis based on the overall network change scene. Therefore, the present invention combines the reliability of file changes and the reliability of scene changes to achieve the test of overall data rollback. It avoids testing the overall data rollback based only on the data rollback situation in a single mode, ensuring the multi-scenario stability of data rollback and the applicability of complex systems.

进一步地,在本发明实施例中,结合文件变化可靠程度和场景变化可靠程度,确定多模式场景下数据回滚的测试指标,包括:计算文件变化可靠程度和场景变化可靠程度的乘积,作为多模式场景下数据回滚的测试指标。Furthermore, in an embodiment of the present invention, the file change reliability and the scene change reliability are combined to determine the test index for data rollback in a multi-mode scenario, including: calculating the product of the file change reliability and the scene change reliability as the test index for data rollback in a multi-mode scenario.

其中,由于文件变化可靠程度的取值范围为归一化后的数值,且场景变化可靠程度的取值范围同样为归一化后的数值,由此,本发明实施例中计算文件变化可靠程度和场景变化可靠程度的乘积,从而得到多模式场景下数据回滚的测试指标。Among them, since the value range of file change reliability is a normalized value, and the value range of scene change reliability is also a normalized value, the product of file change reliability and scene change reliability is calculated in the embodiment of the present invention to obtain the test index of data rollback in a multi-mode scenario.

可以理解的是,该测试指标的取值范围也同样为[0,1],在测试指标的数值越大时,表示文件变化可靠程度和场景变化可靠程度的数值均越大,也即整体数据回滚的稳定性及文件变化均越优,由此,可以基于测试指标实现回滚操作准确的测试分析。It can be understood that the value range of this test indicator is also [0,1]. When the value of the test indicator is larger, the reliability of file changes and the reliability of scene changes are larger, that is, the stability of the overall data rollback and the file changes are better. Therefore, accurate test analysis of the rollback operation can be achieved based on the test indicator.

进一步地,在本发明的一些实施例中,根据测试指标实现恢复出厂过程的异常分析,包括:在测试指标大于预设指标阈值时,确定数据回滚操作正常;否则,确定数据回滚操作异常。Furthermore, in some embodiments of the present invention, an abnormality analysis of the factory recovery process is implemented based on the test index, including: when the test index is greater than a preset index threshold, determining that the data rollback operation is normal; otherwise, determining that the data rollback operation is abnormal.

其中,预设指标阈值为测试指标的门限值,具体为0.3,当然,在本发明的另一些实施例中,也可以根据实际检测需求确定预设阈值,对此不做限制。The preset indicator threshold is a threshold value of the test indicator, specifically 0.3. Of course, in other embodiments of the present invention, the preset threshold may also be determined according to actual detection requirements, and there is no limitation to this.

也即是说,在测试指标大于0.3时,确定数据回滚操作正常;在测试指标小于等于0.3时,确定数据回滚操作异常。从而能够实现更为准确有效的数据回滚准确性测试。That is to say, when the test index is greater than 0.3, it is determined that the data rollback operation is normal; when the test index is less than or equal to 0.3, it is determined that the data rollback operation is abnormal. Thus, a more accurate and effective data rollback accuracy test can be achieved.

本发明实施例通过获取不同模式场景下恢复出厂过程中回滚前与回滚后的系统数据以及回滚过程中的网络变动指标,从而对多模式场景进行数据回滚分析,相较于单模式场景的回滚分析,多模式场景由于涉及到不同模式场景可能产生的联动,以及不同模式场景的配置区别,从而导致直接根据单模式场景的回滚文件分析的准确较低,由此,本发明实施例通过文件数量、文件大小、文件时间戳几个维度从而确定数据回滚的文件变化可靠程度,则文件变化可靠程度能够有效表征数据回滚过程中是否存在数据的残留或者丢失的异常情况;之后,获取并行测试交互指标和网络变动指标,确定回滚过程的场景变化可靠程度,则场景变化可靠程度能够准确表征回滚过程中的网络环境变化,进而结合多场景的文件变化和多模式场景数据回滚时网络的变化情况,获得最终的测试指标,该测试指标即为考虑到多模式场景的复杂性和网络波动所得到的指标信息,能够有效实现恢复出厂过程的异常分析。The embodiment of the present invention obtains system data before and after rollback and network change indicators during the rollback process in different mode scenarios, thereby performing data rollback analysis on the multi-mode scenario. Compared with the rollback analysis of the single-mode scenario, the multi-mode scenario involves possible linkages between different mode scenarios and configuration differences between different mode scenarios, resulting in lower accuracy of the rollback file analysis directly based on the single-mode scenario. Therefore, the embodiment of the present invention determines the file change reliability of data rollback through the dimensions of file quantity, file size, and file timestamp. The file change reliability can effectively characterize whether there is an abnormal situation of data residue or loss during the data rollback process; then, the parallel test interaction index and the network change index are obtained to determine the scene change reliability of the rollback process. The scene change reliability can accurately characterize the network environment changes during the rollback process, and then combine the file changes in multiple scenarios and the changes in the network during the data rollback of the multi-mode scenario to obtain the final test index. The test index is the index information obtained by considering the complexity of the multi-mode scenario and the network fluctuation, which can effectively realize the abnormal analysis of the factory recovery process.

本发明的另一些实施例还提供了一种多模式场景下恢复出厂后数据回滚准确性测试系统,参见图2,图2为本发明一个实施例所提供的一种多模式场景下恢复出厂后数据回滚准确性测试系统的结构图,系统600包括存储器601、处理器602以及存储在存储器601中并可在处理器602上运行的计算机程序603,处理器602执行计算机程序603时实现如前述一种多模式场景下恢复出厂后数据回滚准确性测试方法的步骤。Some other embodiments of the present invention also provide a system for testing the accuracy of data rollback after factory restoration in a multi-mode scenario. See Figure 2. Figure 2 is a structural diagram of a system for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by an embodiment of the present invention. The system 600 includes a memory 601, a processor 602, and a computer program 603 stored in the memory 601 and executable on the processor 602. When the processor 602 executes the computer program 603, the steps of the method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario as described above are implemented.

本实施例还提供一种计算机可读存储介质,该计算机可读存储介质中存储有计算机程序代码,当该计算机程序代码在计算机上运行时,使得计算机执行上述相关方法步骤实现上述实施例提供的一种多模式场景下恢复出厂后数据回滚准确性测试方法。This embodiment also provides a computer-readable storage medium, which stores computer program code. When the computer program code runs on a computer, the computer executes the above-mentioned related method steps to implement a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by the above embodiment.

本实施例还提供了一种计算机程序产品,当该计算机程序产品在计算机上运行时,使得计算机执行上述相关步骤,以实现上述实施例提供的一种多模式场景下恢复出厂后数据回滚准确性测试方法。This embodiment also provides a computer program product. When the computer program product runs on a computer, it enables the computer to execute the above-mentioned related steps to implement a method for testing the accuracy of data rollback after factory restoration in a multi-mode scenario provided by the above embodiment.

其中,本实施例提供的系统、计算机可读存储介质或计算机程序产品均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。Among them, the system, computer-readable storage medium or computer program product provided in this embodiment is used to execute the corresponding method provided above. Therefore, the beneficial effects that can be achieved can refer to the beneficial effects in the corresponding method provided above, and will not be repeated here.

需要说明的是:上述本发明实施例先后顺序仅仅为了描述,不代表实施例的优劣。在附图中描绘的过程不一定要求示出的特定顺序或者连续顺序才能实现期望的结果。在某些实施方式中,多任务处理和并行处理也是可以的或者可能是有利的。It should be noted that the sequence of the above embodiments of the present invention is for description only and does not represent the advantages and disadvantages of the embodiments. The processes depicted in the accompanying drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。The various embodiments in this specification are described in a progressive manner, and the same or similar parts between the various embodiments can be referenced to each other, and each embodiment focuses on the differences from other embodiments.

Claims (10)

1. The method for testing the rollback accuracy of the data after factory restoration in the multi-mode scene is characterized by comprising the following steps:
under different mode scenes, respectively acquiring system data before rollback and after rollback in a factory restoration process and a network variation index in the rollback process, wherein the system data comprises the number of files, the size of the files, the time stamp of the files and the configuration parameters of equipment;
Determining a data consistency index of the rollback process of each mode scene according to the number of files, the sizes of the files and the timestamp differences of the files with the same name before and after rollback in the same mode scene; determining the file change reliability degree of data rollback in a multi-mode scene according to the data consistency indexes in different mode scenes;
According to the change of the configuration parameters of the equipment before and after rollback of any mode scene and other mode scenes, determining a parallel test interaction index of each mode scene, and determining the scene change reliability degree of the rollback process by combining the parallel test interaction index and the network variation index;
determining a test index of data rollback in a multi-mode scene by combining the file change reliability degree and the scene change reliability degree; and according to the test indexes, the abnormality analysis of the factory restoration process is realized.
2. The method for testing the rollback accuracy of the data after the factory recovery in the multimode scene according to claim 1, wherein the method for acquiring the data consistency index of the rollback process of the multimode scene comprises the following steps:
Matching the files before rolling back and after rolling back in one-to-one identical name, and determining matched file pairs and unmatched files;
Taking the difference of the sizes of the two files in the file pair as a size difference factor;
taking the difference of the file time stamps of the two files in the pair of files as a time difference factor;
Taking the quantity of all unmatched files as a quantity difference factor;
and combining the size difference factor, the time difference factor and the quantity difference factor to obtain a data consistency index of the corresponding mode scene rollback process.
3. The method for testing the rollback accuracy of the data after the factory recovery in the multimode scene according to claim 2, wherein the step of combining the size difference factor, the time difference factor and the quantity difference factor to obtain the data consistency index of the rollback process of the corresponding mode scene comprises the following steps:
Calculating the product of the size difference factor, the time difference factor and the quantity difference factor to obtain a rollback difference index;
and carrying out negative correlation normalization processing on the rollback difference index to obtain a data consistency index.
4. The method for testing the accuracy of the rollback of the data after the factory recovery in the multimode scene according to claim 1 is characterized in that the method for acquiring the file change reliability of the rollback of the data in the multimode scene comprises the following steps:
Calculating the average value of the data consistency indexes in all mode scenes, and normalizing to obtain a rollback consistency coefficient;
taking the absolute value of the difference value of the data consistency index in any two different mode scenes as the mode consistency difference of the two corresponding different mode scenes; calculating the average value of the mode consistency differences of all the mode scenes to obtain a multi-mode difference average value;
performing negative correlation mapping and normalization processing on the multi-mode difference mean value to obtain a rollback stability coefficient;
and forward fusing the rollback consistency coefficient and the rollback stability coefficient to obtain the file change reliability degree of data rollback in the multi-mode scene.
5. The method for testing the rollback accuracy of the data after factory restoration in the multimode scene according to claim 4, wherein the method for performing negative correlation mapping and normalization processing on the multimode difference mean value to obtain the rollback stability coefficient comprises the following steps:
And carrying out maximum and minimum value normalization processing on the negative number of the multi-mode difference mean value to obtain a rollback stability coefficient.
6. The method for testing the rollback accuracy of data after factory restoration in a multimode scene according to claim 1, wherein the device configuration parameters comprise a subnet mask, and the method for acquiring the parallel test interaction index of the multimode scene comprises the following steps:
Taking any mode scene as a scene to be measured, and averaging the difference of the subnet mask values of the scene to be measured and each other mode scene before data rollback to obtain a mask change coefficient before rollback;
Averaging the subnet mask value difference of the scene to be tested and other scenes of each mode after data rollback to obtain a mask change coefficient after rollback;
and calculating the difference value of the mask change coefficient before rollback and the mask change coefficient after rollback, and carrying out maximum and minimum normalization processing to obtain the parallel test interaction index.
7. The method for testing the rollback accuracy of data after factory restoration in a multimode scene according to claim 1, wherein the network variation index comprises a network delay time, and determining the scene change reliability degree of the rollback process by combining the parallel test interaction index and the network variation index comprises:
Calculating the product of the parallel test interaction index and the corresponding network delay duration under each mode scene, solving the negative number of the product value, and carrying out maximum and minimum normalization processing to obtain the target change degree of the mode scene;
and taking the average value of the target change degrees of all the mode scenes as the scene change reliability degree of the rollback process.
8. The method for testing the accuracy of the rollback of the data after the factory recovery in the multimode scene according to claim 1, wherein the step of determining the test index of the rollback of the data in the multimode scene by combining the file change reliability degree and the scene change reliability degree comprises the following steps:
And calculating the product of the file change reliability degree and the scene change reliability degree to serve as a test index of data rollback in the multi-mode scene.
9. The method for testing the rollback accuracy of the data after the factory recovery in the multimode scene according to claim 1, wherein the method for realizing the exception analysis of the factory recovery process according to the test index comprises the following steps:
when the test index is larger than a preset index threshold, determining that the data rollback operation is normal; otherwise, determining that the data rollback operation is abnormal.
10. The method for testing the rollback accuracy of post-factory data in a multimode scenario of claim 9, wherein the preset index threshold is 0.3.
CN202411170079.2A 2024-08-26 2024-08-26 Method for testing rollback accuracy of post-factory recovery data in multi-mode scene Active CN118672934B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202411170079.2A CN118672934B (en) 2024-08-26 2024-08-26 Method for testing rollback accuracy of post-factory recovery data in multi-mode scene

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202411170079.2A CN118672934B (en) 2024-08-26 2024-08-26 Method for testing rollback accuracy of post-factory recovery data in multi-mode scene

Publications (2)

Publication Number Publication Date
CN118672934A true CN118672934A (en) 2024-09-20
CN118672934B CN118672934B (en) 2024-12-10

Family

ID=92732862

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202411170079.2A Active CN118672934B (en) 2024-08-26 2024-08-26 Method for testing rollback accuracy of post-factory recovery data in multi-mode scene

Country Status (1)

Country Link
CN (1) CN118672934B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN120429182A (en) * 2025-07-08 2025-08-05 深圳卓创智能科技有限公司 Laptop multi-scenario stress testing method and system for factory inspection

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8296271B1 (en) * 2005-03-28 2012-10-23 Federal Home Loan Mortgage Corporation System and method for optimizing data recovery in a parallel database
US20140068022A1 (en) * 2012-08-28 2014-03-06 VCE Company LLC Deployed application factory reset
CN110287120A (en) * 2019-06-28 2019-09-27 深圳前海微众银行股份有限公司 A unit testing system and testing method
WO2020172881A1 (en) * 2019-02-28 2020-09-03 云图有限公司 Block generation method and apparatus, computer device and storage medium
CN112463644A (en) * 2020-12-17 2021-03-09 深圳软牛科技有限公司 Regression testing method, device, equipment and storage medium of data recovery software
CN116700884A (en) * 2023-04-26 2023-09-05 安超云软件有限公司 Snapshot rollback data consistency test method, device, equipment and medium
CN116931995A (en) * 2023-07-19 2023-10-24 元心信息科技集团有限公司 System upgrading method and device, electronic equipment and storage medium
CN117271243A (en) * 2023-09-27 2023-12-22 苏州元脑智能科技有限公司 Method, system, equipment and medium for testing consistency of data in backtracking area of solid state disk
US20240126664A1 (en) * 2022-10-12 2024-04-18 Esper.io, Inc. Mobile Device Management Agent Rollback Systems and Methods

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8296271B1 (en) * 2005-03-28 2012-10-23 Federal Home Loan Mortgage Corporation System and method for optimizing data recovery in a parallel database
US20140068022A1 (en) * 2012-08-28 2014-03-06 VCE Company LLC Deployed application factory reset
WO2020172881A1 (en) * 2019-02-28 2020-09-03 云图有限公司 Block generation method and apparatus, computer device and storage medium
CN110287120A (en) * 2019-06-28 2019-09-27 深圳前海微众银行股份有限公司 A unit testing system and testing method
WO2020259516A1 (en) * 2019-06-28 2020-12-30 深圳前海微众银行股份有限公司 Unit testing system and unit testing method
CN112463644A (en) * 2020-12-17 2021-03-09 深圳软牛科技有限公司 Regression testing method, device, equipment and storage medium of data recovery software
US20240126664A1 (en) * 2022-10-12 2024-04-18 Esper.io, Inc. Mobile Device Management Agent Rollback Systems and Methods
CN116700884A (en) * 2023-04-26 2023-09-05 安超云软件有限公司 Snapshot rollback data consistency test method, device, equipment and medium
CN116931995A (en) * 2023-07-19 2023-10-24 元心信息科技集团有限公司 System upgrading method and device, electronic equipment and storage medium
CN117271243A (en) * 2023-09-27 2023-12-22 苏州元脑智能科技有限公司 Method, system, equipment and medium for testing consistency of data in backtracking area of solid state disk

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
吕韬;田峰;李征宇;张雪;: "分布式关系型数据库恢复点目标测试方法", 工业技术创新, no. 03, 11 June 2020 (2020-06-11) *
斯琴高娃;: "ASP.NET程序中动态创建数据库时的事务与并发控制问题的解决", 电脑编程技巧与维护, no. 15, 18 October 2008 (2008-10-18) *
黄寅飞;黄俊杰;王泊;武剑锋;白硕;: "证券交易系统中的事务恢复方法", 计算机工程, no. 24, 20 December 2010 (2010-12-20) *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN120429182A (en) * 2025-07-08 2025-08-05 深圳卓创智能科技有限公司 Laptop multi-scenario stress testing method and system for factory inspection
CN120429182B (en) * 2025-07-08 2025-09-09 深圳卓创智能科技有限公司 Laptop multi-scenario stress testing method and system for factory inspection

Also Published As

Publication number Publication date
CN118672934B (en) 2024-12-10

Similar Documents

Publication Publication Date Title
CN108388489B (en) Server fault diagnosis method, system, equipment and storage medium
TW201941058A (en) Anomaly detection method and device
CN101576844A (en) Method and system for testing software system performances
CN110543420B (en) A software testing method, system, terminal and storage medium
CN113157577A (en) PaaS cloud platform fault testing method and device
CN109714201B (en) Network system reliability assessment method, device, computer equipment and storage medium
CN118672934A (en) Method for testing rollback accuracy of post-factory recovery data in multi-mode scene
CN109582578B (en) System, method, computer readable medium and electronic device for software test case
CN106021054A (en) Method and apparatus for testing upgrading and downgrading stability of BMC
CN110825466A (en) Program jamming processing method and jamming processing device
CN110580220B (en) Method for measuring code segment execution time and terminal equipment
CN112131086A (en) Performance tuning method, device and equipment of application server
CN114490361A (en) Test script quality obtaining method and device, computer equipment and storage medium
CN111143209A (en) Layered pressure testing method and device, electronic equipment and storage medium
US20150160944A1 (en) System wide performance extrapolation using individual line item prototype results
CN111125222B (en) Data testing method and device
CN115687951B (en) Reliability evaluation method and device of hybrid electronic system
CN111654405A (en) Method, device, equipment and storage medium for fault node of communication link
CN114020527B (en) Snapshot recovery method, device, computer equipment and storage medium
WO2021223214A1 (en) Interface performance test method and apparatus, and server and computer-readable storage medium
CN113535841A (en) Data verification method, device and equipment and computer readable storage medium
CN119276940A (en) Grayscale publishing method, device, electronic device and storage medium
CN113676377B (en) Online user number evaluation method, device, equipment and medium based on big data
CN118093354A (en) Test code generation method and device, electronic equipment and storage medium
CN115509941A (en) Data interface testing method and device

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
GR01 Patent grant
GR01 Patent grant