CN1160731C - Hard disk data protection method for computer - Google Patents

Hard disk data protection method for computer Download PDF

Info

Publication number
CN1160731C
CN1160731C CNB011201118A CN01120111A CN1160731C CN 1160731 C CN1160731 C CN 1160731C CN B011201118 A CNB011201118 A CN B011201118A CN 01120111 A CN01120111 A CN 01120111A CN 1160731 C CN1160731 C CN 1160731C
Authority
CN
China
Prior art keywords
sector
mapping
hard disk
piece
firm offer
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.)
Expired - Fee Related
Application number
CNB011201118A
Other languages
Chinese (zh)
Other versions
CN1338751A (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.)
Individual
Original Assignee
Individual
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 Individual filed Critical Individual
Priority to CNB011201118A priority Critical patent/CN1160731C/en
Publication of CN1338751A publication Critical patent/CN1338751A/en
Application granted granted Critical
Publication of CN1160731C publication Critical patent/CN1160731C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Signal Processing For Digital Recording And Reproducing (AREA)

Abstract

The present invention provides a method for protecting the hard disk data of a computer. In the method, an open region table is created to record all the hard disk regions which don't need to be protected, and a virtual disk table is created to most possibly record the remaining space in hard disk regions needing to be protected; the current size of the virtual disk is dynamically determined from OMB to the maximum reserved space, and the remaining space which exceeds the size of the virtual disk is not protected, and is freely allowed to be freely read and written. In the method, a mapping table is created to record mapping relations for mapping a writing operation to a hard disk region without data originally in a protected physical partition when the writing operation is carried out on the hard disk. An indexing table of the virtual disk table, an indexing table of the mapping table, and a virtual table and a mapping table used for managing limited quantity are also created in the present invention, and the created dynamic mapping table is used for recording the mapping relation of the reading and the writing of the hard disk with the number of times of the closest limited quantity; thereby, running speed can be increased to ensure that the read-write speed of the hard disk in the state of protection is affected to a minimum extent.

Description

A kind of guard method of computer hard disk data
(1) technical field:
The present invention relates to a kind of guard method of computer hard disk data.
(2) background technology:
Hard disk is the vitals of storage data in the computing machine, it is as the most frequently used external memory storage of computing machine, have the advantages that price is low, capacity big, the storage data for a long time, are not cut off the power supply and influenced, the warehouse of the Computer Storage data on coming true, existing computing machine do not have the hard disk performance that almost is far from being.Hard disk is normally combined by disk sheet group, various control circuit, opertaing device encapsulation, is a kind of precision equipment, is the important component part of guard of computer to Data Protection in the hard disk.Traditional hard disk data protection method is the anti-literary style of hard disk.The anti-fully mode of writing of this method usefulness is protected the data in the hard disk; but because operating system need dynamically mark off a block space as virtual memory in hard disk when operation; can frequently read and write in the operational process, so this method may have a strong impact on the normal operation of operating system.Advanced at present hard disk data protection method has adopted the dynamic virtual seagate; this method is in order to improve the R/W speed of hard disc under guard mode; restriction virtual hard disk size is fixing can not to surpass certain capacity; such as 603MB; sacrificed the available rate of hard disk so widely; as long as the data of revising and increasing surpass the size of virtual hard disk; even remaining hard drive space is far away more than the size of virtual hard disk; also can cause computer system to be shut down; must empty after the virtual hard disk, computing machine could continue normal operation.For example, suppose that the hard disk areas that needs protection is 20GB, have the 10GB data on the hard disk now, after the protection, even increase the new data of 603MB fully, the available rate of hard disk only has an appointment 50.30%; If revised the available data of 603MB, even do not increase any new data so, non-firm offer is also full, and the available rate of hard disk also just only has an appointment 50%; In a word, the hard disk utilization rate before the later hard disk available rate of protection equals to protect substantially.From the above, existing hard disk data protection method fails to solve well the contradiction between the available rate in R/W speed of hard disc under guard mode and hard disk protection zone.
(3) summary of the invention:
The objective of the invention is to, a kind of guard method of effective computer hard disk data is provided, this method has improved the available rate of hard disk greatly in the R/W speed of hard disc that has guaranteed to be under the guard mode.
For achieving the above object, the guard method of computer hard disk data provided by the invention comprises:
(1) the scanning DISK to Image is registered all Physical Extents;
(2) select the Physical Extents that to protect;
(3) scan the Physical Extents that to protect, register all remaining spaces;
(4) according to the size of the summation of the remaining space of above-mentioned steps (3) registration, dynamically determine current non-firm offer size from 0MB to maximum headspace;
(5) open up the memory block, record is mapped to write operation the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally when hard disk is carried out write operation;
(6) select the hard disk protection function,, then remove all mapping relations if select to recover the raw data function; If select to preserve the modification data function, then scan existing mapping relations successively, if " sector, source piece " in mapping relations be not as " the destination sector piece " of another mapping relations, " destination sector piece " in these mapping relations write back " sector, source piece ", nullify these mapping relations then;
(7) hard disk reading and writing operations is monitored,, revised mapping relations according to start sector number, the sector number of the hard drive space of write operation for write operation.
In above-mentioned steps (4), dynamically definite current non-firm offer size is finished according to following method to maximum headspace from 0MB: described headspace value is set at medium headspace MV and maximum headspace GV, if the sum total of remaining space is less than MV, then remaining space is all as current non-firm offer; If the sum total of remaining space is greater than GV, current non-firm offer size is GV, and redundant space is labeled as free space; Otherwise current non-firm offer size is MV, and redundant space is labeled as free space.
The above-mentioned memory block of opening up; record is when carrying out write operation to hard disk; write operation is mapped to the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally; be by creating mapping table; described mapping table comprises original start sector number, mapping start sector number, three fields of mapping length; when hard disk is carried out write operation, write operation is mapped to the mapping relations of the hard disk areas that does not have data originally with described mapping table record.
The present invention also comprises:
Establishment open zone table, described open zone table comprise start sector number and finish two fields of sector number, and being used to put down in writing does not have hard disk areas claimed, whenever can direct read.
Create the non-firm offer table, described non-firm offer table comprises start sector number, finishes sector number, three fields of length, is used for registering the remaining space that the hard disk areas that will protect does not have data.
Create dynamic mapping table, described dynamic mapping table comprises original start sector number, mapping start sector number, mapping length three fields, in order to the mapping relations of the disk read-write of putting down in writing nearest limited quantity number of times.
Create the concordance list of mapping table, the concordance list of described mapping table comprises the start sector number of mapping table in hard disk, the original start sector number of total mapping of mapping table record, three fields of original end sector number of total mapping of mapping table record are used to manage the mapping table of limited quantity.
Create the concordance list of non-firm offer table, the concordance list of described non-firm offer table comprises the start sector number of non-firm offer table in hard disk, the start sector number of total non-firm offer of non-firm offer table record, three fields of the end sector number of total non-firm offer of non-firm offer table record are used to manage the non-firm offer table of limited quantity.
In above-mentioned steps (7), described hard disk read operation comprises: start sector number, the sector number of definite hard drive space that will read are several sector pieces with the whole spatial division that will read, and then described sector piece are carried out following operation successively:
(a) search open zone table if the sector piece starts anew to have n sector in the open zone, directly reads this n sector; If the sector piece starts anew to have m sector not in the open zone, then dynamic mapping table is searched for as a sector piece m in this m sector;
(b) if sector piece m starts anew to have m1 the mapped mistake in sector, directly read m1 the sector of shining upon; If sector piece m starts anew to have m2 sector not have mapped mistake, then mapping table is searched for as a sector piece m2 in this m2 sector;
(c) if sector piece m2 all less than mapping, directly reads this m2 sector; If sector piece m2 starts anew to have m3 the mapped mistake in sector, then read m3 sector of this mapping, the mapping relations of this m3 sector are added dynamic mapping table; If sector piece m2 starts anew to have m4 sector not have mapped mistake, and m5 the mapped mistake in sector then directly reads this m4 sector, reads m5 sector of mapped mistake then, the mapping relations of this m5 sector are added dynamic mapping table.
In above-mentioned steps (7), described hard disk write operation comprises: determining to carry out start sector number, the sector number of the hard drive space of write operation, is several sector pieces with the whole spatial division that will carry out write operation, and described sector piece is carried out following operation successively:
(a) search open zone table if the sector piece starts anew to have n sector in the open zone, is directly write this n sector; If the sector piece starts anew to have m sector not in the open zone, then dynamic mapping table is searched for as a sector piece m in this m sector;
(b) if piece m whole mapped mistakes in sector are write m the sector of shining upon; If sector piece m has at least a sector not have mapped mistake, then search for mapping table;
(c) if piece m whole mapped mistakes in sector join dynamic mapping table with the mapping relations of m sector, write m the sector of shining upon then; If sector piece m has at least a sector not have mapped mistake, then search for the non-firm offer table;
(d) if sector piece m all at free space, directly writes this m sector; If have a sector at least not at free space, then in non-firm offer, distribute m sector, the mapping relations with this m sector join dynamic mapping table then, and the mapping relations of this m sector are joined mapping table, write m the sector of shining upon at last.
Because the present invention creates the open zone table; write down the hard disk areas that all do not need protection; create the non-firm offer table; write down the remaining space in the hard disk areas that needs protection most possibly; determine that dynamically current non-firm offer size is from 0MB to the headspace; remaining space more than current non-firm offer size does not add protection; allow freely to read and write; like this; both broken through of the restriction of current algorithm to the virtual hard disk fixed size; guarantee the normal operation of high-end system software and large scale system software, overthrown the equation of " protecting later hard disk available rate to equal to protect hard disk utilization rate before substantially " again, improved the available rate of hard disk greatly.In addition; the present invention has also created the concordance list of non-firm offer table, the concordance list of mapping table; be used to manage non-firm offer table, the mapping table of limited quantity; the dynamic mapping table of creating is in order to the mapping relations of the disk read-write of putting down in writing nearest limited quantity number of times; therefore can improve travelling speed, guarantee R/W speed of hard disc under guard mode suffered influence minimum.As seen, the present invention can solve the contradiction between the available rate in R/W speed of hard disc under guard mode and hard disk protection zone preferably.
(4) description of drawings:
Fig. 1 is the process flow diagram of the embodiment of the invention;
Fig. 2 be the embodiment of the invention read hard disk sector piece process flow diagram;
Fig. 3 be the embodiment of the invention write hard disk sector piece process flow diagram.
(5) embodiment:
For purpose of the present invention, technical scheme and beneficial effect there being more detailed clear and definite understanding, the invention will be further described below in conjunction with drawings and Examples.At first with reference to figure 1.Implement the present invention according to Fig. 1 and will be divided into three parts usually.First is an initialization section, and this part comprises step 1 to step 5, and second portion is for selecting the defencive function part, and this part comprises step 6, and third part is the real-time monitor portion of disk read-write, and this part comprises step 7.
At first carry out described first.In step 1, the scanning DISK to Image is registered all Physical Extents.In step 2, the Physical Extents that selection will be protected.In this step, need to create the open zone table, described open zone table comprises start sector number and finishes two fields of sector number, being used to put down in writing does not have hard disk areas claimed, whenever can direct read; Show all Physical Extents then, and select the Physical Extents that to protect, the Physical Extents of not protection is registered in the table of open zone.In step 3, the Physical Extents that scanning will be protected is registered all remaining spaces.This step need be created the non-firm offer table, and described non-firm offer table comprises start sector number, finishes sector number, three fields of length, is used for registering the remaining space that the hard disk areas that will protect does not have data.From first Physical Extents that will protect of selecting; to each Physical Extents that will protect; difference according to the file system of Physical Extents; for example at the difference of FAT16/32 (16/32 partition table), NTFS (NT file table); scanning whole Physical Extents, is that the hard disk fragment registers in the non-firm offer table one by one with the remaining space in the Physical Extents.In the practical application, the size of non-firm offer table is conditional, in enrollment process, after the non-firm offer table has been expired, adopts to abandon and stays big principle for a short time, registers remaining space most possibly.The non-firm offer table also comprises mode field in the reality, is free space, current non-firm offer or has expired non-firm offer in order to sign sector piece.In step 4,, determine that dynamically current non-firm offer size is from 0MB to the headspace according to the size of the summation of the remaining space of above-mentioned steps 3 registration.In this example, described headspace value is set at medium headspace MV and maximum headspace GV, wherein, MV is 4.71GB, and GV is 9.43GB.If the sum total of remaining space is less than 4.71GB, then remaining space is all as current non-firm offer; If the sum total of remaining space is greater than 9.43GB, then current non-firm offer size is 9.43GB, and redundant space is labeled as free space; Otherwise current non-firm offer size is 4.71GB, and redundant space is labeled as free space.When determining that current non-firm offer is big or small, the size according to the remaining space piece of registering adopts first big after small, principle from back to front, marks enough current non-firm offers in the non-firm offer table.In step 5, open up the memory block, record is mapped to write operation the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally when hard disk is carried out write operation, and purpose is to protect existing data not to be modified.Write down above-mentioned mapping relations by creating mapping table in the reality, described mapping table comprises original start sector number, mapping start sector number, three fields of mapping length.In computer system, to hard disk divide and read and write generally with bunch or piece be unit, bunch size 4KB, 8KB, 16KB, 32KB even 64KB, 128KB are arranged, so each mapping length can only be expressed with one 8 byte; In order to improve R/W speed of hard disc, and the restriction that breaks through the non-firm offer size, can increase the size of maximum mapping block in the reality, this example reaches this purpose by the figure place that increases the mapping length field, guarantee under the identical situation of mapping table list item number, improve the capacity of expressing mapping to greatest extent.After finishing above-mentioned work, can from current non-firm offer, distribute a block space, described open zone table, non-firm offer table, mapping table are write hard disk and preserve.
Carry out described second portion then.In step 6, select the hard disk protection function.Described hard disk protection function can be: recover raw data, when the junk data in the hard disk takies a large amount of hard drive spaces even cause system performance decline or hard disc data to suffer that destruction so that system can not normally move even collapse, the raw data the when user need return to protection; Preserve to revise data, under guard mode, when hard disc data has been carried out mandate, legal, correct modification, want these and revise and be not resumed function and abandon, the user just need will revise data and record in the hard disk authentic and validly before recovery; Described hard disk protection function can also be, changes guard mode, such as change password, parameter is set, reselects the Physical Extents that will protect, cancels all protections and unloading protecting card etc.
In the practical application, consider that from the security aspect above-mentioned three big basic functions can only realize before os starting.Therefore, in the process of computer starting, i.e. after BIOS (Basic Input or Output System (BIOS)) self check, before the os starting, can protect the mode of software ejection function menu to provide by hot key triggering.
If select to recover the raw data function, then remove all mapping relations and get final product; If select to preserve the modification data function, then scan existing mapping relations successively, promptly scan the mapping relations table, if " sector, source piece " in mapping relations be not as " the destination sector piece " of another mapping relations, just " the destination sector piece " in these mapping relations can be write back " sector, source piece ", nullify these mapping relations then, all be canceled up to all mapping relations.Reselect the fdisk that to protect if desired, can get back to above-mentioned steps 2 and reselect.
Carry out third part at last, disk read-write is monitored in real time.
Because the remaining space in the hard disk areas that will protect generally all is a Discrete Distribution, the summation of fragment is exactly a remaining space, and the fragment number in the hard disk areas that will protect may be very many like this, so the non-firm offer table also should be sufficiently many; Consider to account for computer resource and relevant computer system standard less, and in order to improve the speed of search non-firm offer table, the size of every non-firm offer table is limited, so the present invention also needs to create the concordance list of non-firm offer table.The concordance list of described non-firm offer table comprises the start sector number of non-firm offer table in hard disk, the start sector number of total non-firm offer of non-firm offer table record, and three fields of the end sector number of total non-firm offer of non-firm offer table record are used to manage the non-firm offer table of limited quantity.Based on same reason, the size of mapping table also is limited, in order to improve the available rate of hard disk, still have enough non-firm offers to use when on average having only 4KB even guarantee each mapping block for system, so abundant mapping table is arranged, therefore, in order to improve the speed of software search mapping table, the present invention also will create the concordance list of a mapping table.The concordance list of described mapping table comprises the start sector number of mapping table in hard disk, the original start sector number of total mapping of mapping table record, and three fields of original end sector number of total mapping of mapping table record are used to manage the mapping table of limited quantity.
Therefore, when step 7 pair hard disk is read and write real-time monitoring,, should revise mapping relations according to concrete operation for write operation.At first read in the open zone table, create the concordance list of non-firm offer table, the concordance list of establishment mapping table.Because mapping table may be huger, each read-write is all fully searched for and is lost time very much for one time, for improving R/W speed of hard disc, the present invention also creates dynamic mapping table, described dynamic mapping table comprises original start sector number, mapping start sector number, mapping length three fields, in order to the mapping relations of the disk read-write of putting down in writing nearest limited quantity number of times.
In the present embodiment, described reading and writing to hard disk are monitored in real time, and the one, forbid physical formatization.Logical formatting is actually read-write operation, can read and write and treat.The 2nd, reading and writing are monitored.Need to prove; for write operation; increase mapping relations if desired; should check following condition: 1. whether mapping table is full of 2. whether non-firm offer is full; when one of them is " expiring "; non-firm offer overflow error has just taken place, and system-down recovers raw data next time when requiring to start computing machine.
Fig. 2 be the embodiment of the invention read hard disk sector piece process flow diagram.According to Fig. 2, in the step 1 of carrying out read operation, start sector number, the sector number of definite hard drive space that will read, with the whole spatial division that will read is several sector pieces, selecting to enter step 2 behind first sector piece, search open zone table obtains the relation in sector piece and open zone; In step 3, judge the relation in described sector piece and described open zone, if the sector piece starts anew just to have n sector in the open zone, carry out step 4 and directly read this n sector, carry out step 16 then and continue following operation; If the sector piece starts anew just to have m sector not in the open zone, then carry out step 5 dynamic mapping table is searched for as a sector piece m in this m sector, obtain the relation of sector piece m and dynamic mapping table; Then carry out step 6, judge the relation of described sector piece m and described dynamic mapping table,, then carry out step 7, directly read m1 the sector of shining upon, carry out step 16 then and continue following operation if sector piece m starts anew just to have m1 the mapped mistake in sector; If sector piece m starts anew to have m2 sector not have mapped mistake, then carry out step 8 mapping table is searched for as a sector piece m2 in this m2 sector, obtain the relation of sector piece m2 and mapping table; Then carry out step 9, judge the relation of sector piece m2 and described mapping table,, carry out step 16 then and continue following operation if sector piece m2 directly carries out step 10 and reads this m2 sector all less than mapping; If sector piece m2 starts anew just to have m3 the mapped mistake in sector, then carry out m3 the sector that step 11 reads this mapping, carry out step 13 then the mapping relations of this m3 sector are added dynamic mapping table, then carry out step 16 and continue following operation; If sector piece m2 starts anew to have m4 sector not have mapped mistake, and m5 the mapped mistake in sector, then carry out step 12 and directly read this m4 sector, carry out m5 the sector that step 14 reads mapped mistake then, in step 15 mapping relations of this m5 sector are added dynamic mapping table, carry out step 16 then and continue following operation; In step 16, judge whether that all sector pieces all run through, if do not run through then carry out step 17 and select next sector piece, turn back to the read operation that described step 2 continues next sector piece then, otherwise finish this read operation.
Fig. 3 be the embodiment of the invention write hard disk sector piece process flow diagram.According to Fig. 3, in the step 1 of carrying out write operation, determine to carry out start sector number, the sector number of the hard drive space of write operation, with the whole spatial division that will carry out write operation is several sector pieces, selecting to enter step 2 behind first sector piece, search open zone table is to obtain the relation in sector piece and open zone; In step 3, judge the relation in described sector piece and described open zone, if the sector piece starts anew just to have n sector in the open zone, directly carry out step 4 and write this n sector, carry out step 16 then and continue following operation; If the sector piece starts anew just to have m sector not in the open zone, then dynamic mapping table is searched for as a sector piece m in this m sector, to obtain the relation of sector m piece and dynamic mapping table; In step 6, judge the relation of described sector piece m and described dynamic mapping table, if piece m whole mapped mistakes in sector are then carried out step 7 and write m the sector of shining upon, carry out step 16 then and continue following operation; If sector piece m has at least a sector not have mapped mistake, then search for mapping table with sector piece m, to obtain the relation of sector m piece and mapping table in step 8; In step 9, judge the relation of described sector piece m and described mapping table, if piece m whole mapped mistakes in sector are then carried out step 10 mapping relations of m sector are joined dynamic mapping table, write m the sector of shining upon then, then carry out step 16 and continue following operation; If sector piece m has at least a sector not have mapped mistake, then carry out step 11, with sector piece m search non-firm offer table, to obtain the relation of described sector m piece and described non-firm offer table; In step 12, judge the relation of described sector piece m and described non-firm offer table, if, then carrying out step 13 all at free space, sector piece m directly writes this m sector, carry out step 16 then and continue following operation; If sector piece m has a sector at least not at free space, then carry out step 14, in non-firm offer, distribute m sector, carry out step 15 then the mapping relations of this m sector are joined dynamic mapping table, and the mapping relations of this m sector are joined mapping table, write m the sector of shining upon at last; In step 16, judge whether that all sector pieces have all write, if do not write then carry out step 17 and select next sector piece, turn back to the write operation that described step 2 continues next sector piece then, otherwise finish this write operation.
In the above-described embodiments, owing to consider and account for computer resource and relevant computer system standard less, be 4KB so the size of the concordance list of mapping table, mapping table all is set at, so total mapping table list item number is 341 (individual mapping table) * 453 (an individual list item/mapping table)=154473.The data relationship of the total size of mapping block mean size and non-firm offer is: the total size=154473 * mapping block mean size of non-firm offer.As shown in the table:
The mapping block mean size 4KB 8KB 16KB 32KB 64KB
Non-firm offer is size always 603MB 1.18GB 2.36GB 4.71GB 9.43GB
Present embodiment improves the size of each mapping block by following two kinds of methods, guarantees under the identical situation of mapping table list item number, improves the capacity of expressing mapping to greatest extent.
The one, rational current non-firm offer using priciple.With the non-firm offer table non-firm offer is managed, and use non-firm offer backward in the past, mapping block is connected possessed necessary condition.
The 2nd, merge interconnective mapping block, improve the capacity that each mapping table list item is expressed mapping to greatest extent.
Present embodiment is divided into current non-firm offer size less than 4.71GB, 4.71GB, three kinds of situations of 9.43GB; and the remaining space more than current non-firm offer size does not add protection; allow freely to read and write; not only break through the restriction of non-firm offer size 603MB, and improved the hard disk available rate under guard mode greatly.

Claims (10)

1, a kind of guard method of computer hard disk data comprises:
(1) the scanning DISK to Image is registered all Physical Extents;
(2) select the Physical Extents that to protect;
(3) scan the Physical Extents that to protect, register all remaining spaces;
(4) according to the size of the summation of the remaining space of above-mentioned steps (3) registration, dynamically determine current non-firm offer size from 0MB to maximum headspace;
(5) open up the memory block, record is mapped to write operation the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally when hard disk is carried out write operation;
(6) select the hard disk protection function,, then remove all mapping relations if select to recover the raw data function; If select to preserve the modification data function, then scan existing mapping relations successively, if " sector, source piece " in mapping relations be not as " the destination sector piece " of another mapping relations, just " the destination sector piece " in these mapping relations can be write back " sector, source piece ", nullify these mapping relations then.
(7) hard disk reading and writing operations is monitored,, revised mapping relations according to start sector number, the sector number of the hard drive space of write operation for write operation.
2, the guard method of hard disc data according to claim 1, it is characterized in that: finish according to following method to maximum headspace from 0MB in the dynamically definite current non-firm offer size of described step (4): described headspace value is set at medium headspace MV and maximum headspace GV, if the sum total of remaining space is less than MV, then remaining space is all as current non-firm offer; If the sum total of remaining space is greater than GV, current non-firm offer size is GV, and redundant space is labeled as free space; Otherwise current non-firm offer size is MV, and redundant space is labeled as free space.
3, the guard method of hard disc data according to claim 2, it is characterized in that: when determining that current non-firm offer is big or small, size according to the remaining space piece of registering adopts first big after small, principle from back to front, marks enough current non-firm offers in the non-firm offer table; Redundant space is labeled as free space.
4, according to the guard method of claim 1,2 or 3 described hard disc datas; it is characterized in that: the described memory block of opening up; record is when carrying out write operation to hard disk; write operation is mapped to the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally; be by creating mapping table; described mapping table comprises original start sector number, mapping start sector number, three fields of mapping length; when hard disk is carried out write operation, write operation is mapped to the mapping relations that do not have the hard disk areas of data in the Physical Extents of protection originally with the record of described mapping table.
5, the guard method of hard disc data according to claim 4; it is characterized in that: this method also comprises creates the open zone table; described open zone table comprises start sector number and finishes two fields of sector number, and being used to put down in writing does not have hard disk areas claimed, whenever can direct read.
6, the guard method of hard disc data according to claim 5; it is characterized in that: this method also comprises creates the non-firm offer table; described non-firm offer table comprises start sector number, finishes sector number, three fields of length, is used for registering the remaining space that the hard disk areas that will protect does not have data.
7, the guard method of hard disc data according to claim 6; it is characterized in that: this method also comprises creates dynamic mapping table; described dynamic mapping table comprises original start sector number, mapping start sector number, mapping length three fields, in order to the mapping relations of the disk read-write of putting down in writing nearest limited quantity number of times.
8, the guard method of hard disc data according to claim 7 is characterized in that, this method also comprises:
Create the concordance list of mapping table, the concordance list of described mapping table comprises the start sector number of mapping table in hard disk, the original start sector number of total mapping of mapping table record, three fields of original end sector number of total mapping of mapping table record are used to manage the mapping table of limited quantity;
Create the concordance list of non-firm offer table, the concordance list of described non-firm offer table comprises the start sector number of non-firm offer table in hard disk, the start sector number of total non-firm offer of non-firm offer table record, three fields of the end sector number of total non-firm offer of non-firm offer table record are used to manage the non-firm offer table of limited quantity.
9, the guard method of hard disc data according to claim 8; it is characterized in that; described hard disk read operation comprises: start sector number, the sector number of definite hard drive space that will read; with the whole spatial division that will read is several sector pieces, and described sector piece is carried out following operation successively:
(1) search open zone table if the sector piece starts anew to have n sector in the open zone, directly reads this n sector; If the sector piece starts anew to have m sector not in the open zone, then dynamic mapping table is searched for as a sector piece m in this m sector;
(2) if sector piece m starts anew to have m1 the mapped mistake in sector, directly read m1 the sector of shining upon; If sector piece m starts anew to have m2 sector not have mapped mistake, then mapping table is searched for as a sector piece m2 in this m2 sector;
(3) if sector piece m2 all less than mapping, directly reads this m2 sector; If sector piece m2 starts anew to have m3 the mapped mistake in sector, then read m3 sector of this mapping, the mapping relations of this m3 sector are added dynamic mapping table; If sector piece m2 starts anew to have m4 sector not have mapped mistake, and m5 the mapped mistake in sector then directly reads this m4 sector, reads m5 sector of mapped mistake then, the mapping relations of this m5 sector are added dynamic mapping table.
10, the guard method of hard disc data according to claim 8; it is characterized in that: described hard disk write operation comprises: start sector number, the sector number of determining to carry out the hard drive space of write operation; with the whole spatial division that will carry out write operation is several sector pieces, and described sector piece is carried out following operation successively:
(1) search open zone table if the sector piece starts anew to have n sector in the open zone, is directly write this n sector; If the sector piece starts anew to have m sector not in the open zone, then dynamic mapping table is searched for as a sector piece m in this m sector;
(2) if piece m whole mapped mistakes in sector are write m the sector of shining upon; If sector piece m has at least a sector not have mapped mistake, then search for mapping table;
(3) if piece m whole mapped mistakes in sector join dynamic mapping table with the mapping relations of m sector, write m the sector of shining upon then; If sector piece m has at least a sector not have mapped mistake, then search for the non-firm offer table;
(4) if sector piece m all at free space, directly writes this m sector; If have a sector at least not at free space, then in non-firm offer, distribute m sector, the mapping relations with this m sector join dynamic mapping table then, and the mapping relations of this m sector are joined mapping table, write m the sector of shining upon at last.
CNB011201118A 2001-07-05 2001-07-05 Hard disk data protection method for computer Expired - Fee Related CN1160731C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB011201118A CN1160731C (en) 2001-07-05 2001-07-05 Hard disk data protection method for computer

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB011201118A CN1160731C (en) 2001-07-05 2001-07-05 Hard disk data protection method for computer

Publications (2)

Publication Number Publication Date
CN1338751A CN1338751A (en) 2002-03-06
CN1160731C true CN1160731C (en) 2004-08-04

Family

ID=4663905

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB011201118A Expired - Fee Related CN1160731C (en) 2001-07-05 2001-07-05 Hard disk data protection method for computer

Country Status (1)

Country Link
CN (1) CN1160731C (en)

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7287133B2 (en) * 2004-08-24 2007-10-23 Symantec Operating Corporation Systems and methods for providing a modification history for a location within a data store
KR100527274B1 (en) * 2004-06-04 2005-12-13 주식회사 르노소프트 Apparatus and method for protecting system data on computer hard-disk using system area information table and mapping table
CN100464314C (en) * 2006-03-23 2009-02-25 联想(北京)有限公司 Digital data transparency protected safety read-write system and method
CN100424652C (en) * 2006-07-28 2008-10-08 华南理工大学 Had disk self-recovery protecting method based on embedded operation system
CN100428196C (en) * 2006-12-22 2008-10-22 清华大学 Fast restore method for computer system
CN100573480C (en) * 2008-02-29 2009-12-23 中国科学院计算技术研究所 A kind of hard disk data protection method and system
CN102043727B (en) * 2009-10-10 2014-04-02 成都市华为赛门铁克科技有限公司 Method and device for recovering solid-state hard disc mapping table
CN101814038B (en) * 2010-03-23 2012-10-03 杭州顺网科技股份有限公司 Method for increasing booting speed of computer
CN101833485B (en) * 2010-03-23 2011-12-21 杭州顺网科技股份有限公司 System protection method based on snapshot
CN102902637B (en) * 2012-11-19 2015-04-22 北京理工大学 Solid-state hard disk data power-off protection method

Also Published As

Publication number Publication date
CN1338751A (en) 2002-03-06

Similar Documents

Publication Publication Date Title
US8069317B2 (en) Providing and utilizing high performance block storage metadata
CN102667740B (en) Boundary alignment by data storage device subregion Yu physical data sector
EP1739535B1 (en) File system storing transaction records in flash-like media
US8667029B2 (en) Optimized startup verification of file system integrity
US7809777B2 (en) File system having deferred verification of data integrity
JP5881859B2 (en) Storage device
JP2007012060A (en) File system having inverted hierarchical structure
US11321229B2 (en) System controller and system garbage collection method
CN1160731C (en) Hard disk data protection method for computer
US8209513B2 (en) Data processing system with application-controlled allocation of file storage space
CN100507864C (en) Data protection and restore method based on instant restore type protection card for hard disk
CN101246429A (en) Electronic systems using flash memory modules as main storage and related system booting methods
CN114201648A (en) System and method for efficiently expanding key value hash table
JP3431581B2 (en) Disk control system and data relocation method
JPH09288547A (en) Array-type storage device
US7167964B1 (en) Memory defragmentation in chipcards
EP1046996A1 (en) Memory defragmentation in chipcards
US11789622B2 (en) Method, device and computer program product for storage management
CN1959587A (en) Method for realizing isolation among multiple users of using same computer
CN1225476A (en) Method for quick protection and recovery for hard disc data of computer
JP4040797B2 (en) Disk control device and recording medium
KR100859989B1 (en) Apparatus for managing space information of flash memory and method of the same
CN117170942B (en) Database backup method based on file system snapshot and related equipment
CN101819544A (en) Hard disk data protection and method of reducing based on dynamic data area
Long et al. WA-Zone: Wear-Aware Zone Management Optimization for LSM-Tree on ZNS SSDs

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C17 Cessation of patent right
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20040804

Termination date: 20110705