CN107957922A - A kind of memory power-off protection method - Google Patents

A kind of memory power-off protection method Download PDF

Info

Publication number
CN107957922A
CN107957922A CN201711442932.1A CN201711442932A CN107957922A CN 107957922 A CN107957922 A CN 107957922A CN 201711442932 A CN201711442932 A CN 201711442932A CN 107957922 A CN107957922 A CN 107957922A
Authority
CN
China
Prior art keywords
power
memory
protection method
storage region
reserved memory
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
CN201711442932.1A
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.)
Xuancheng New Maintenance Network Technology Co Ltd
Original Assignee
Xuancheng New Maintenance Network 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 Xuancheng New Maintenance Network Technology Co Ltd filed Critical Xuancheng New Maintenance Network Technology Co Ltd
Priority to CN201711442932.1A priority Critical patent/CN107957922A/en
Publication of CN107957922A publication Critical patent/CN107957922A/en
Pending legal-status Critical Current

Links

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/1471Saving, restoring, recovering or retrying involving logging of persistent data for recovery
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/26Power supply means, e.g. regulation thereof
    • G06F1/30Means for acting in the event of power-supply failure or interruption, e.g. power-supply fluctuations
    • 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/1441Resetting or repowering
    • 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/1448Management of the data involved in backup or backup restore
    • G06F11/1453Management of the data involved in backup or backup restore using de-duplication of the data

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Techniques For Improving Reliability Of Storages (AREA)
  • Power Sources (AREA)

Abstract

The present invention provides a kind of memory power-off protection method, is related to memory technology field, a kind of memory power-off protection method, comprises the following steps:S1:Divide the memory into normal storage region and reserved memory area;S2:Different activation voltage is distributed for normal storage region and reserved memory area;S3:When main power source is stopped power supply, cut-in stand-by power supply, activation reserved memory area is started to work;S4:When main power source restores electricity, the data in reserved memory area are write into normal storage region.A kind of memory power-off protection method power-off protection of the present invention is timely, and data storage is complete, and convenient operation.

Description

A kind of memory power-off protection method
Technical field
The present invention relates to memory technology field,
Especially, the present invention relates to a kind of memory power-off protection method.
Background technology
In general, household electrical appliance, communicator and embedded system, such as set-top box, use is used as using nonvolatile memory In the storage device of storage and processing data.Wherein flash memory is a kind of memory of nonvolatile type, is counted wherein According to can be electrically erased through the gate and rewrite.Because memory consumes lower-wattage, such as hard disk than the storage medium based on magnetic disk storage It equally may have access to, and there is compact size, so it is suitable for mancarried device.
Especially there is cluster-based storage, cluster-based storage refers to the cluster for being used to store being made of several universal storage devices, The performance and capacity for forming each storage system of cluster-based storage can be able to be superimposed and extended by way of cluster, generally be existed Management node is configured with cluster, the dispatch deal to carrying out data storage as other storage devices of memory node.
Cluster is during file is handled, it is possible that the situation that a certain equipment is stopped, is typically due to electricity Caused by the power down of source, after power down, the data in equipment caching can lose data because system exception is closed.
For cluster storage system, the method for typically using data redundancy carrys out the security of data in raising system, number Refer to repeat storage according to redundancy or repeat transmission data to prevent the loss of data, but repeatedly store and transmit data certainty Cost can be improved, and reduces the efficiency of system.
The content of the invention
It is an object of the invention to provide a kind of power-off protection is timely, data storage is complete, and the memory of convenient operation Power-off protection method.
To solve the above problems, the present invention adopts the following technical scheme that what is be achieved:
A kind of memory power-off protection method, comprises the following steps:
S1:Divide the memory into normal storage region and reserved memory area;
S2:Different activation voltage is distributed for normal storage region and reserved memory area;
S3:When main power source is stopped power supply, cut-in stand-by power supply, activation reserved memory area is started to work;
S4:When main power source restores electricity, the data in reserved memory area are write into normal storage region.
Preferably, when performing step S2, the activation voltage of normal storage region is main power voltage.
Preferably, when performing step S2, the activation voltage of reserved memory area is backup power source voltage.
Preferably, when performing step S1, the size that normal storage region and reserved memory area are deposited is to be deposited in memory Store up the integral multiple of page size.
Preferably, when performing step S3, reserved memory area only writes for data.
Preferably, when performing step S3, cut-in stand-by power supply, and send alarm to control centre.
Preferably, perform step S4 when, stand-by power supply is still working in the given time, to reserved memory area in number Stop power supply according to stand-by power supply after all writing normal storage region.
Preferably, when performing step S4, the time value of stand-by power supply work after default main power source is powered.
Preferably, after performing step S4, the data in reserved memory area are all wiped.
A kind of memory power-off protection method beneficial effect of the present invention is:Power-off protection is timely, and data storage is complete, and Convenient operation.
Brief description of the drawings
Fig. 1 is the flow diagram of one embodiment of the invention.
Embodiment
The present invention is described further with reference to the accompanying drawings and examples.
Memory particularly cluster-based storage is during file is handled, it is possible that the situation that a certain equipment is stopped, It is typically due to caused by power supply power-fail, after power down, the data in equipment caching can lose because system exception is closed Data.
As shown in Figure 1, being only one of embodiment of the present invention, in order to reach timely power-off protection, ensure that data are deposited Storage completely protects memory, and the present invention proposes a kind of memory power-off protection method, comprises the following steps:
S1:Divide the memory into normal storage region and reserved memory area;
As soon as memory can also be multiple, if memory is only a division region, if memory is Cluster-based storage, including multiple memories, that is more preferable, directly separates a small number of memories as reserved memory.
S2:Different activation voltage is distributed for normal storage region and reserved memory area;
Two storage regions do different functions respectively, can also separate and be managed, and activation voltage is different, can also avoid pre- The storage region abnormal activation stayed.
For further, when performing step S2, the activation voltage of normal storage region is main power voltage.It is pre- to retain The activation voltage in storage area domain is backup power source voltage.
That is when main power source is powered, reserved memory area will not be activated, and will not enter working status.It is and same Sample, when stand-by power supply starts power supply, normal storage region will not be activated, and will not carry out data access.
Followed by step S3:When main power source is stopped power supply, cut-in stand-by power supply, activation reserved memory area starts work Make;
Main power source is once stopped power supply, and stand-by power supply starts to power at once, and reserved memory area is activated start-up operation, is unlikely to During power-off, data can not write, and later data can not be integrated and caused damages.
It is finally step S4:When main power source restores electricity, by the data write-in normal storage area in reserved memory area Domain.
Once main power source restores electricity, it is possible to normal storage region is activated, and by the data in reserved memory area Write to normal storage region.
Data so in normal storage region will not omit, and the data of the front and rear even during power-off of power-off are normally deposited Storage.
Certainly, when performing step S1, the size that normal storage region and reserved memory area are deposited is to be deposited in memory Store up the integral multiple of page size.
Also mention above, memory can be the cluster that a storaging piece can also be multiple storaging piece compositions, then , it is necessary to which storaging piece is divided into two storage regions when memory is single storaging piece, two storage regions are must assure that at this time Size is the integral multiple of memory page size in memory, like that data will not be caused can not to read and write or waste memory space Situation.
It should be noted that when performing step S3, reserved memory area only writes for data, not for being read out.
It is reserved memory area after all, the data in it are simultaneously imperfect, do not run for reading, and in turnoff time Between, the present invention functions only as the work that the complete of data is protected during main power source power-off rather than substitutes memory when power is off.
Since only accomplishing to protect during power-off, memory can not work normally, then when performing step S3, cut-in stand-by electricity Source, and send alarm to control centre.
During power-off, notify that the staff of control centre is overhauled, if for main power source caused by other machines damage Stop power supply, carry out power supply repairing at once.
Also when performing step S4, stand-by power supply is still working in the given time, to reserved memory area in number Stop power supply according to stand-by power supply after all writing normal storage region.
By in reserved memory area data all write-in normal storage regions, it is necessary to assure reserved memory area can be just Often work and be read out, then be still to work normally in the stand-by power supply scheduled time, be powered for reserved memory area.
It is so natural, it is necessary in advance default main power source be powered after stand-by power supply work time value.
Finally, after performing step S4, the data in reserved memory area are all wiped.
During easy to power off again, reserved memory area can still carry out urgent data and preserve.
A kind of power-off protection of memory power-off protection method of the present invention is timely, and data storage is complete, and convenient operation.
The present invention is not limited to above-mentioned specific embodiment, and the invention may be variously modified and varied.Every foundation The technical spirit of the present invention should be included in the present invention to embodiment of above any modification, equivalent replacement, improvement and so on Protection domain.

Claims (9)

1. a kind of memory power-off protection method, it is characterised in that comprise the following steps:
S1:Divide the memory into normal storage region and reserved memory area;
S2:Different activation voltage is distributed for normal storage region and reserved memory area;
S3:When main power source is stopped power supply, cut-in stand-by power supply, activation reserved memory area is started to work;
S4:When main power source restores electricity, the data in reserved memory area are write into normal storage region.
A kind of 2. memory power-off protection method according to claim 1, it is characterised in that:When performing step S2, normally The activation voltage of storage region is main power voltage.
A kind of 3. memory power-off protection method according to claim 1, it is characterised in that:When performing step S2, reserve The activation voltage of storage region is backup power source voltage.
A kind of 4. memory power-off protection method according to claim 1, it is characterised in that:When performing step S1, normally The size that storage region and reserved memory area are deposited is the integral multiple of memory page size in memory.
A kind of 5. memory power-off protection method according to claim 1, it is characterised in that:When performing step S3, reserve Storage region only writes for data.
A kind of 6. memory power-off protection method according to claim 1, it is characterised in that:When performing step S3, switching Stand-by power supply, and send alarm to control centre.
A kind of 7. memory power-off protection method according to claim 1, it is characterised in that:It is spare when performing step S4 Power supply is still working in the given time, to reserved memory area in data all write-in normal storage regions after standby electricities Stop power supply in source.
A kind of 8. memory power-off protection method according to claim 7, it is characterised in that:When performing step S4, preset The time value that stand-by power supply works after main power source is powered.
A kind of 9. memory power-off protection method according to claim 1, it is characterised in that:, will after performing step S4 Data in reserved memory area are all wiped.
CN201711442932.1A 2017-12-27 2017-12-27 A kind of memory power-off protection method Pending CN107957922A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711442932.1A CN107957922A (en) 2017-12-27 2017-12-27 A kind of memory power-off protection method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711442932.1A CN107957922A (en) 2017-12-27 2017-12-27 A kind of memory power-off protection method

Publications (1)

Publication Number Publication Date
CN107957922A true CN107957922A (en) 2018-04-24

Family

ID=61957048

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711442932.1A Pending CN107957922A (en) 2017-12-27 2017-12-27 A kind of memory power-off protection method

Country Status (1)

Country Link
CN (1) CN107957922A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112621719A (en) * 2020-12-11 2021-04-09 珠海格力电器股份有限公司 Demonstrator system file protection method and device, storage medium and demonstrator
CN113468617A (en) * 2021-07-16 2021-10-01 浙江大华技术股份有限公司 Method, equipment and storage medium for power failure protection of equipment

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040103238A1 (en) * 2002-11-26 2004-05-27 M-Systems Flash Disk Pioneers Ltd. Appliance, including a flash memory, that is robust under power failure
CN107038131A (en) * 2016-02-04 2017-08-11 广明光电股份有限公司 Solid state hard disc power-off protection apparatus and method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040103238A1 (en) * 2002-11-26 2004-05-27 M-Systems Flash Disk Pioneers Ltd. Appliance, including a flash memory, that is robust under power failure
CN107038131A (en) * 2016-02-04 2017-08-11 广明光电股份有限公司 Solid state hard disc power-off protection apparatus and method

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112621719A (en) * 2020-12-11 2021-04-09 珠海格力电器股份有限公司 Demonstrator system file protection method and device, storage medium and demonstrator
CN113468617A (en) * 2021-07-16 2021-10-01 浙江大华技术股份有限公司 Method, equipment and storage medium for power failure protection of equipment

Similar Documents

Publication Publication Date Title
CN101183801B (en) Power-off protection method, system and device
CN105051703B (en) Method and apparatus for avoiding lower page error in data storage device
CN103942160B (en) Storage system, storage device and date storage method
CN101251826B (en) Flash memory, method and apparatus for data management of flash memory
US9075733B1 (en) Selective storage of address mapping metadata in a system having multiple memories
TWI524183B (en) Data writing method, memory control circuit unit and memory storage apparatus
CN101630293B (en) Data protection method, power-fail protection device and storage device
CN107038131A (en) Solid state hard disc power-off protection apparatus and method
CN101963891A (en) Method and device for data storage and processing, solid-state drive system and data processing system
CN102902637B (en) Solid-state hard disk data power-off protection method
CN102662804A (en) Power-down-prevention irreversible self-destroying method for solid state disk
CN101782875A (en) Storage unit and data storage method
CN102789431A (en) Data protection method and system
TWI534827B (en) Managing data using a number of non-volatile memory arrays
CN103092765B (en) Solid-state memory system, device and method for writing data
CN103399520B (en) For power failure data access method and the device of programmable logic controller system
CN105468544A (en) Method and apparatus for realizing power-failure-proof file system, and power-failure-proof file system
US10229000B2 (en) Erasure codes to prevent lower page corruption in flash memory
CN101661435A (en) Data processing apparatus
CN107957922A (en) A kind of memory power-off protection method
CN109597773A (en) A kind of SSD and its method for power fail safeguard of data, system, device
CN106294217A (en) A kind of SSD system and power-off protection method thereof
CN113711189A (en) System and method for managing reduced power failure energy requirements on solid state drives
CN103425546A (en) General high-efficient reliable Nor Flash data memory management method
CN105404468A (en) Green NAND solid-state disk application and driver therefor

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
RJ01 Rejection of invention patent application after publication

Application publication date: 20180424

RJ01 Rejection of invention patent application after publication