[go: up one dir, main page]
More Web Proxy on the site http://driver.im/

CN114237980A - A device data self-recovery method - Google Patents

A device data self-recovery method Download PDF

Info

Publication number
CN114237980A
CN114237980A CN202111417030.9A CN202111417030A CN114237980A CN 114237980 A CN114237980 A CN 114237980A CN 202111417030 A CN202111417030 A CN 202111417030A CN 114237980 A CN114237980 A CN 114237980A
Authority
CN
China
Prior art keywords
partition
recovery
self
data
factory
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111417030.9A
Other languages
Chinese (zh)
Inventor
欧阳其平
叶金湖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Huidu Technology Co ltd
Original Assignee
Hunan Grayscale 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 Hunan Grayscale Information Technology Co ltd filed Critical Hunan Grayscale Information Technology Co ltd
Priority to CN202111417030.9A priority Critical patent/CN114237980A/en
Publication of CN114237980A publication Critical patent/CN114237980A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1446Point-in-time backing up or restoration of persistent data
    • G06F11/1458Management of the backup or restore process
    • G06F11/1469Backup restoration techniques
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/14Error detection or correction of the data by redundancy in operation
    • G06F11/1402Saving, restoring, recovering or retrying
    • G06F11/1415Saving, restoring, recovering or retrying at system level
    • G06F11/1417Boot up procedures

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (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

本发明涉及数据恢复技术领域,且公开了一种设备数据自恢复方法,包括以下步骤:S1、给每个设备分配唯一编号;S2、出厂前flash上预留一个备份分区;S3、设备由u‑boot引导,引导内核前,先检查各个分区是否有新的坏块,如果有则尝试修复,修复失败时,则进入恢复出厂设置流程,进行恢复出厂设置;S4、设备在恢复出厂设置后首次启动,将会向服务器拉取原有数据。本发明提出一种设备数据自恢复方法,本发明为了提升系统安全性,本专利提出了将数据存储到云服务器的方法。服务器上存储一份与设备一致的内容,当设备出现文件系统损坏时,设备先进行恢复出厂设置,再上报设备本身ID到服务器,拉去本设备原有数据,则可将设备的数据恢复成损坏前的样子。

Figure 202111417030

The invention relates to the technical field of data recovery, and discloses a device data self-recovery method, comprising the following steps: S1, assigning a unique number to each device; S2, reserving a backup partition on the flash before leaving the factory; S3, the device is stored by u ‑boot, before booting the kernel, check whether there are new bad blocks in each partition. If there are any new bad blocks, try to repair them. If the repair fails, enter the process of restoring the factory settings to restore the factory settings; S4, the device is the first time after restoring the factory settings On startup, the original data will be pulled from the server. The present invention proposes a method for self-recovery of device data. In order to improve system security, the present invention proposes a method for storing data in a cloud server. A copy of the content consistent with the device is stored on the server. When the file system of the device is damaged, the device will first restore the factory settings, and then report the device ID to the server. If the original data of the device is pulled, the data of the device can be restored to before damage.

Figure 202111417030

Description

Equipment data self-recovery method
Technical Field
The invention relates to the field of data recovery, in particular to a device data self-recovery method.
Background
Due to unstable power supply, the embedded device is often powered off in the data writing process. The read and write of the flash are usually performed in units of blocks (generally 512 bytes), if the device fails to power when the data is not written, a dirty block occurs, the block is marked as a bad block when the system is started next time, a file located in the block will be damaged, and if the block is a partition table, the risk that the whole partition file is lost exists.
In order to solve the above problem, the present application provides a device data self-recovery method.
Disclosure of Invention
Objects of the invention
In order to solve the technical problems in the background art, the invention provides an equipment data self-recovery method. The server stores a content consistent with the equipment, when the file system of the equipment is damaged, the equipment restores factory settings, reports the ID of the equipment to the server, and pulls out the original data of the equipment, so that the data of the equipment can be restored to the original data before damage.
(II) technical scheme
In order to solve the above problems, the present invention provides a device data self-recovery method, which includes the following steps:
s1, allocating a unique number to each device;
s2, reserving a backup partition on the flash before leaving the factory;
s3, the device is guided by a u-boot, before guiding the kernel, whether each partition has a new bad block is checked, if yes, repair is tried, and when repair fails, a factory setting recovery flow is entered, and factory setting recovery is carried out;
s4, the device is started for the first time after the factory setting is restored, and original data are pulled to the server.
Preferably, in S1, a unique number may be assigned to the CPUID, flash id, mac address or software.
Preferably, in S2, the backup partition includes a software version and a system version that are the same as those of the device when shipped from the factory.
Preferably, in S3, the partition in which the u-boot program is located is also a read-only partition.
Preferably, in S3, if there is no damaged block, the normal system is booted.
Preferably, in S4, the method further comprises booting a normal system.
Preferably, the server stores a copy of the content consistent with the device.
Preferably, the partition is a read-only partition.
The technical scheme of the invention has the following beneficial technical effects:
in order to improve the system security, the patent provides a method for storing data to a cloud server. The server stores a content consistent with the equipment, when the file system of the equipment is damaged, the equipment restores factory settings, reports the ID of the equipment to the server, and pulls out the original data of the equipment, so that the data of the equipment can be restored to the original data before damage; the system safety is improved, and the risk of data loss is reduced.
Drawings
Fig. 1 is a simple logic diagram of a device data self-recovery method according to the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention will be described in further detail with reference to the accompanying drawings in conjunction with the following detailed description. It should be understood that the description is intended to be exemplary only, and is not intended to limit the scope of the present invention. Moreover, in the following description, descriptions of well-known structures and techniques are omitted so as to not unnecessarily obscure the concepts of the present invention.
As shown in fig. 1, the method for self-recovering device data according to the present invention includes the following steps:
s1, assigning a unique number (which can be a CPUID, a flash id, a mac address or a unique number assigned by software) to each device;
s2, reserving a backup partition on the flash before leaving the factory, wherein the backup partition comprises a software version and a system version which are the same as those of the equipment when leaving the factory, and the partition is a read-only partition;
s3, the device is guided by a u-boot program (the partition where the u-boot program is located is also a read-only partition), before guiding the kernel, whether each partition has a new bad block is checked, if so, repair is tried, and when the repair fails, a factory setting recovery flow is entered to recover factory settings;
s4, the device is started for the first time after the factory setting is restored, and original data are pulled to the server.
In an alternative embodiment, a copy of the device-consistent content is stored on the server.
In the invention, in order to improve the system security, the patent provides a method for storing data to a cloud server. The server stores a content consistent with the equipment, when the file system of the equipment is damaged, the equipment firstly restores factory settings (the factory setting partition is a read-only partition, and the risk of writing the file damage partition does not exist), then reports the ID of the equipment to the server, and pulls the original data of the equipment, so that the data of the equipment can be restored to the original data before damage; the system safety is improved, and the risk of data loss is reduced.
It is to be understood that the above-described embodiments of the present invention are merely illustrative of or explaining the principles of the invention and are not to be construed as limiting the invention. Therefore, any modification, equivalent replacement, improvement and the like made without departing from the spirit and scope of the present invention should be included in the protection scope of the present invention. Further, it is intended that the appended claims cover all such variations and modifications as fall within the scope and boundaries of the appended claims or the equivalents of such scope and boundaries.

Claims (8)

1. A device data self-recovery method is characterized by comprising the following steps:
s1, allocating a unique number to each device;
s2, reserving a backup partition on the flash before leaving the factory;
s3, the device is guided by a u-boot, before guiding the kernel, whether each partition has a new bad block is checked, if yes, repair is tried, and when repair fails, a factory setting recovery flow is entered, and factory setting recovery is carried out;
s4, the device is started for the first time after the factory setting is restored, and original data are pulled to the server.
2. The device data self-recovery method of claim 1, wherein in S1, CPUID, flash id, mac address or software assigned unique number can be used.
3. The method for self-restoring device data according to claim 1, wherein in S2, the backup partition includes a software version and a system version that are the same as those of the device when it leaves a factory.
4. The device data self-recovery method of claim 1, wherein in S3, the partition in which the u-boot program is located is also a read-only partition.
5. The device data self-recovery method of claim 1, wherein in S3, if there is no damaged block, a normal system is booted.
6. The method for self-recovery of device data according to claim 1, further comprising booting a normal system in S4.
7. The method of claim 1, wherein a piece of content consistent with the device is stored on the server.
8. A method for self-recovery of device data according to claim 3, wherein the partition is a read-only partition.
CN202111417030.9A 2021-11-26 2021-11-26 A device data self-recovery method Pending CN114237980A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111417030.9A CN114237980A (en) 2021-11-26 2021-11-26 A device data self-recovery method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111417030.9A CN114237980A (en) 2021-11-26 2021-11-26 A device data self-recovery method

Publications (1)

Publication Number Publication Date
CN114237980A true CN114237980A (en) 2022-03-25

Family

ID=80751520

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111417030.9A Pending CN114237980A (en) 2021-11-26 2021-11-26 A device data self-recovery method

Country Status (1)

Country Link
CN (1) CN114237980A (en)

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101477482A (en) * 2008-10-14 2009-07-08 深圳市共进电子有限公司 Method for recovering flash memory data at power-off of built-in Linux system
CN106028306A (en) * 2016-05-03 2016-10-12 广东欧珀移动通信有限公司 Method and device for restoring factory settings of terminal equipment and terminal equipment
CN106100911A (en) * 2016-08-23 2016-11-09 上海斐讯数据通信技术有限公司 Cloud collocation method, router, Cloud Server and the system of a kind of router
CN111405322A (en) * 2020-03-05 2020-07-10 青岛聚看云科技有限公司 Method and device for acquiring login information
CN111400094A (en) * 2020-03-13 2020-07-10 苏州浪潮智能科技有限公司 Method, device, equipment and medium for restoring factory settings of server system
CN112202972A (en) * 2020-09-30 2021-01-08 上海商米科技集团股份有限公司 System and method for protecting terminal equipment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101477482A (en) * 2008-10-14 2009-07-08 深圳市共进电子有限公司 Method for recovering flash memory data at power-off of built-in Linux system
CN106028306A (en) * 2016-05-03 2016-10-12 广东欧珀移动通信有限公司 Method and device for restoring factory settings of terminal equipment and terminal equipment
CN106100911A (en) * 2016-08-23 2016-11-09 上海斐讯数据通信技术有限公司 Cloud collocation method, router, Cloud Server and the system of a kind of router
CN111405322A (en) * 2020-03-05 2020-07-10 青岛聚看云科技有限公司 Method and device for acquiring login information
CN111400094A (en) * 2020-03-13 2020-07-10 苏州浪潮智能科技有限公司 Method, device, equipment and medium for restoring factory settings of server system
CN112202972A (en) * 2020-09-30 2021-01-08 上海商米科技集团股份有限公司 System and method for protecting terminal equipment

Similar Documents

Publication Publication Date Title
US8812910B2 (en) Pilot process method for system boot and associated apparatus
CN113626256B (en) Virtual machine disk data backup method, device, terminal and storage medium
US20070055969A1 (en) System and method for updating firmware
JP2013520744A (en) Method and apparatus for generating minimum boot image
CN106775610B (en) Electronic equipment starting method and electronic equipment
JPWO2013103023A1 (en) Information processing apparatus, information processing method, and computer program
CN104216793A (en) Application program backing up and restoring method and device
CN104915263A (en) Process fault processing method and device based on container technology
EP3147797B1 (en) Data management method, node and system for database cluster
CN111143132B (en) BIOS recovery method, device, equipment and readable storage medium
CN111552592A (en) Double-backup starting method and system
CN109062600B (en) Method and system for realizing online upgrade of firmware in solid state disk
CN114064352B (en) Memory storage device
CN103207816A (en) Linux system repairing method
CN111045712A (en) Single system upgrading method and system with backup function
KR101548452B1 (en) Method and apparatus for recovering metadata in electronic device based on non-volatile memeory
CN105426268B (en) A kind of method of file system corruption when preventing the protective relaying device from powering off
CN104572198B (en) A kind of service restoration method and device
CN114237980A (en) A device data self-recovery method
US20150269237A1 (en) Disaster Recovery of Converged Infrastructure Platforms
CN113342365A (en) Operating system deployment method, device, equipment and computer-readable storage medium
CN111124294B (en) Sector mapping information management method and device, storage medium and equipment
CN118152181A (en) Solid state disk data recovery method, terminal equipment, electronic equipment and storage medium
CN115562593A (en) Abnormal RAID member disk processing method, device and medium
CN109558274B (en) Information processing method, device and computer readable storage medium

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
TA01 Transfer of patent application right

Effective date of registration: 20240527

Address after: 518000 18 / F, block a, 18 / F, block B, No. 196, Tangtou Avenue, Langxin community, Shiyan street, Bao'an District, Shenzhen City, Guangdong Province

Applicant after: SHENZHEN HUIDU TECHNOLOGY Co.,Ltd.

Country or region after: China

Address before: 410000 room 1201, building 17-1, Xinggong Industrial Technology Park, No. 100 Luyun Road, high tech Development Zone, Changsha, Hunan

Applicant before: Hunan grayscale information technology Co.,Ltd.

Country or region before: China

TA01 Transfer of patent application right