CN102385610A - Method of video recording document storage and data recovery of digital hard-disc video recorder and system thereof - Google Patents

Method of video recording document storage and data recovery of digital hard-disc video recorder and system thereof Download PDF

Info

Publication number
CN102385610A
CN102385610A CN2011102526268A CN201110252626A CN102385610A CN 102385610 A CN102385610 A CN 102385610A CN 2011102526268 A CN2011102526268 A CN 2011102526268A CN 201110252626 A CN201110252626 A CN 201110252626A CN 102385610 A CN102385610 A CN 102385610A
Authority
CN
China
Prior art keywords
tree
district
data file
data
summary info
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
CN2011102526268A
Other languages
Chinese (zh)
Other versions
CN102385610B (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.)
Hangzhou Hikvision Digital Technology Co Ltd
Original Assignee
Hangzhou Hikvision Digital 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 Hangzhou Hikvision Digital Technology Co Ltd filed Critical Hangzhou Hikvision Digital Technology Co Ltd
Priority to CN201110252626.8A priority Critical patent/CN102385610B/en
Publication of CN102385610A publication Critical patent/CN102385610A/en
Application granted granted Critical
Publication of CN102385610B publication Critical patent/CN102385610B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Signal Processing For Digital Recording And Reproducing (AREA)
  • Management Or Editing Of Information On Record Carriers (AREA)

Abstract

The invention relates to security fields and discloses a method of video recording document storage and data recovery of a digital hard-disc video recorder and a system thereof. A data document area and a summary information area are pre-arranged on a hard disc, the data document area comprises a plurality of pre-established data documents, each data document comprises index information and video recording data, and the summary information area comprises at least one B+ tree. The index information of the data documents is dispersed by means of abrasive balance characteristics of B+ tree structure operation so as to reduce the rate of hard-disc faults, eliminate hotspot areas, guarantee completeness and order of all the data documents and summary information of the video recording documents in the B+ tree of the summary information area, and accordingly ensure correctness of the video recording documents of the digital hard-disc video recorder and provide a recovery method of complete data. The system can not be broken down by single-point faults.

Description

The digital hard disc video recorder video file is preserved method and the system of recovering with data thereof
Technical field
The present invention relates to safety-security area, particularly digital hard disc video recorder middle pitch video file storage and recovery technology thereof.
Background technology
Digital video recorder (Digital Video Recorder; Be called for short " DVR ") be the computer system that a cover carries out the image stores processor; Have to image or voice record a video for a long time, the function of recording, telemonitoring and control; Be widely used in the security protection industry field, its audio frequency and video memory technology has just become the topic of a hot topic.
Application number is to have proposed a kind of digital hard disc video recorder file management method that prevents that file fragmentation from producing in 200510050829.3 the Chinese patent; The file of predistribution fixed size on hard disk; Make that same file can be on physical hard disk continuously; Prevented the generation of hard disk fragment effectively, simultaneously through index file centralized management these a predistribution file and video informations.
Inventor of the present invention finds; The shortcoming of this scheme is that all information are all managed through index file; The operation of hard disk write all need read and write index, so the index file region becomes the hot spot region of total system, in case be destroyed then whole file management method can't continue.On the other hand, the hot spot region may become the total system bottleneck of performance.Because digital hard disc video recorder needs 24 hours * 365 days uninterrupted recording data, very high to the requirement of stability and continuation, hot spot region and data security are complete to be urgent problem.
Summary of the invention
The object of the present invention is to provide a kind of digital hard disc video recorder video file to preserve method and the system of recovering with data thereof, utilized of the index information dispersion of the abrasion equilibration characteristic of B+ tree construction operation, reduced the hard disk failure probability data file; Eliminated the hot spot region; Guaranteed the complete sum order of the B+ tree of all data file summary infos in the summary info district of video file; Thereby the correct and partial data restoration methods of the video file of digital hard disc video recorder is provided, and system can not paralyse because of Single Point of Faliure.
For solving the problems of the technologies described above; Embodiment of the present invention provides a kind of store method of digital hard disc video recorder video file; Data file district and summary info district are set on hard disk in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Method may further comprise the steps:
When certain passage is begun to record a video,, find the operable data file of this passage, and upgrade the summary info of this data file in the B+ tree through retrieval to the B+ tree;
In the video data recording process, the index information in this data file is upgraded.
Embodiment of the present invention also provides a kind of data reconstruction method of digital hard disc video recorder video file; Data file district and summary info district are set on hard disk in advance; Comprise a plurality of data files of creating in advance in the data file district; Comprise index information and video recording data in each data file, the summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
For each data file in the data file district, carry out following steps:
The index information of read data files;
From index information, extract summary info;
Summary info is inserted in the B+ tree in summary info district.
Embodiment of the present invention also provides a kind of saved system of digital hard disc video recorder video file, and system comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Retrieval module, when being used for certain passage begun to record a video, retrieval B+ tree is found the operable data file of this passage;
The first summary update module when being used for retrieval module and finding data file, is upgraded the summary info of this data file in the B+ tree;
The index upgrade module is used in the video data recording process, and the index information in the data file that retrieval module is found upgrades.
Embodiment of the present invention also provides a kind of data recovery system of digital hard disc video recorder video file, and system comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Read module is used for the index information of read data files;
The abstract extraction module is used for extracting summary info from the index information that read module reads;
Insert module is used for the summary info that the abstract extraction module is extracted is inserted into the B+ tree in summary info district.
Embodiment of the present invention compared with prior art, the key distinction and effect thereof are:
Because hard disk summary info district uses B+ tree store data structure; Wherein the summary info key word of storage hits in leaf node in order and when search; Promptly very fast extraction summary info data; Thereby use B+ tree store data structure to be fit to document indexing system more, improve search efficiency and accuracy rate; The mode of reading and writing through priority again; Reached the not only anti-effect of makeing mistakes but also preventing focus; Eliminated simultaneously because system's focus frequent access causes Single Point of Faliure disk leak to make the systemic breakdown problem; System bottleneck problem when having solved the index information of search data file, thus total system stability improved.Comprise at least two B+ trees simultaneously in the summary info district, can recover through this B+ is set, thus the security that improves digital hard disc video recorder.
Data file storage order according to video file in the file data district; Last data file until this video file; Obtain the summary info of each data file of video file in the said data file district one by one; Be used to accomplish the index reconstruct of the summary info of B+ tree; Utilized the abrasion equilibration characteristic of B+ tree construction operation, guaranteed the complete sum order of the B+ tree of all data file summary infos in the summary info district of video file, thereby the correct and partial data restoration methods of the video file of digital hard disc video recorder is provided.Index is put in the data file, sets management profile with B+, and summary info is distinguished into 2 main B+ trees in district and subsequent use B+ tree; Read-write successively is with the index information dispersion of data file, no longer centralized management; No longer frequently read and write certain FX (perhaps being called the index area), reduced the hard disk failure probability; Eliminated the hot spot region, improved total system stability, system can not paralyse because of Single Point of Faliure.
Further; When the index information district of data file correspondence physical damage; Can this data file be labeled as damage; Then this data file will no longer be used, and set record in the summary info at B+, continue to use the problem that hard disk areas causes loss of data of having damaged when avoiding the digital hard disc video recorder video file to preserve or play;
Further; In the summary info district, carry out main B+ tree district and be equipped with the setting that the B+ tree is distinguished; Still can use fully B+ tree district management video file, can be so that when in the data file district of hard disk, preserving video file data, according to document format data and the size created in advance; Preserve the video recording data respectively in each data file in the data file district; And in its index information, deposit the index information of this data file, according to this index information or data file writable status the summary info in one of them B+ tree district in the summary info district in said B+ tree district is at least once upgraded data file summary info that uses when reaching the file system index search and index information cooperation renewal synchronously simultaneously; Increase the real-time of system, guaranteed data integrity and accuracy.
Further; When the data file corresponding physical is damaged the index information district; Can this data file be labeled as and damage and will no longer be used; And in B+ tree summary info record, continue to use the problem that hard disk areas causes loss of data of having damaged in the time of can avoiding the digital hard disc video recorder video file to preserve or play.
Further, utilize B+ tree management data document information, when reducing memory consumption, kept work efficiency almost constant, improved the hard-disc storage and the management function of this embedded system of digital hard disc video recorder.
Description of drawings
Fig. 1 is the schematic flow sheet of a kind of store method of digital hard disc video recorder video file in the first embodiment of the invention;
Fig. 2 is a kind of digital hard disc video recorder video file fdisk synoptic diagram in the second embodiment of the invention;
Fig. 3 is the schematic flow sheet of a kind of store method of digital hard disc video recorder video file in the second embodiment of the invention;
Fig. 4 is the schematic flow sheet of a kind of data reconstruction method of digital hard disc video recorder video file in the third embodiment of the invention;
Fig. 5 is the schematic flow sheet of a kind of data reconstruction method of digital hard disc video recorder video file in the four embodiment of the invention;
Fig. 7 is the structural representation of a kind of saved system of digital hard disc video recorder video file in the fifth embodiment of the invention;
Fig. 8 is the structural representation of a kind of data recovery system of digital hard disc video recorder video file in the seventh embodiment of the invention;
Fig. 9 is the structural representation of a kind of data recovery system of digital hard disc video recorder video file in the eighth embodiment of the invention.
Embodiment
In following narration, many ins and outs have been proposed in order to make the reader understand the application better.But, persons of ordinary skill in the art may appreciate that even without these ins and outs with based on the many variations and the modification of following each embodiment, also can realize each claim of the application technical scheme required for protection.
For making the object of the invention, technical scheme and advantage clearer, will combine accompanying drawing that embodiment of the present invention is done to describe in detail further below.
First embodiment of the invention relates to a kind of store method of digital hard disc video recorder video file.The store method of this digital hard disc video recorder video file is described below, and subregion on hard disk when passage is recorded a video, is retrieved this fdisk data file and upgraded its summary info in advance; When the recording channel video information, the index information of updated data file; When data file is write when full, the summary info of updated data file once more.
Specifically,
Data file district and summary info district are set on hard disk in advance; Comprise a plurality of data files of creating in advance in the data file district; Comprise index information and video recording data in each data file, the summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Said method comprising the steps of:
When certain passage is begun to record a video,, find the operable data file of this passage, and upgrade the summary info of this data file in the B+ tree through retrieval to said B+ tree;
In the video data recording process, the index information in this data file is upgraded.
Because hard disk summary info district uses B+ tree store data structure; Wherein the summary info key word of storage hits in leaf node in order and when search; Promptly very fast extraction summary info data; Thereby use B+ tree store data structure to be fit to document indexing system more, improve search efficiency and accuracy rate.The mode of reading and writing through priority again; Reached the not only anti-effect of makeing mistakes but also preventing focus; Eliminated simultaneously because system's focus frequent access causes Single Point of Faliure disk leak to make the systemic breakdown problem; System bottleneck problem when having solved the index information of search data file, thus total system stability improved.Comprise at least two B+ trees simultaneously in the summary info district, can recover through this B+ is set, thus the security that improves digital hard disc video recorder.
In the video data recording process; Index information in this data file upgrades; Can take periodic mode, also can or set individual data file data information and cover zone bit and carry out the whether all test of covering and upgrade according to predefined duration.
Data file comprises but is not limited to the mode to create in advance, also can be through the data file of not visited be for a long time emptied or cover, thus the preservation of obtaining new video file.
In the process that the index information in this data file is upgraded; At least once upgrade in the B+ tree summary info to this data file; Can take periodic mode, also can or set individual data file index information and cover test that zone bit carries out whether all covering and upgrade the summary info of B+ in setting according to predefined duration.
Data through the collection of file data passage; In the process of the data message in the refresh data file; When data file write full or cover full after, can be according to the periodically or real-time monitoring and diagnosis corresponding manner of predetermined duration, the index information of at least updated data file.
Index information comprises summary info, carries out index search when being used for the data file search, and wherein, summary info comprises data file data stream start time, data stream concluding time, data file skew, data file class, data file attaching information.
In the video data recording process, the index information in this data file is carried out after the updating steps, further comprising the steps of:
Current data file write full after, upgrade in the B+ tree summary info to this data file.
In addition, be appreciated that in other preferred embodiments of the present invention that current data file is write completely in a covered manner or to refresh and emptied the mode that rewrites again and carry out video file and preserve.
Fig. 1 is the schematic flow sheet of the store method of this digital hard disc video recorder video file.As a preference of the present invention, for the hard disk that subregion is set, the store method of this digital hard disc video recorder video file as shown in Figure 1, specifically,
In step 101, judged whether the passage video recording;
If then get into step 102; Otherwise, return step 101;
In step 102, when certain passage begins to record a video, retrieval B+ tree;
After this get into step 103, find the operable data file of the passage that begins to record a video;
After this get into step 104, upgrade the summary info of this data file in this B+ tree;
After this get into step 105, in the video data recording process, the index information in this data file is upgraded;
After this get into step 106, judge whether current data file is write full;
If then get into step 107; Otherwise, return step 105;
In step 107, in the video data recording process, the index information in this data file is upgraded, if current data file write full after, then upgrade in the B+ tree summary info, after this process ends to this data file.
Second embodiment of the invention relates to a kind of store method of digital hard disc video recorder video file.Fig. 3 is the schematic flow sheet of the store method of this digital hard disc video recorder video file.
Second embodiment improves on the basis of first embodiment; Main improvements are: in the summary info district, carry out main B+ tree district and be equipped with the setting that B+ sets the district; In the time of can preventing use therein main B+ tree district physical hard disk permanent damages; Still B+ tree district management video file fully be can use, the video recording security of digital hard disc video recorder and the integrality of video file guaranteed.
Through at least one B+ tree district is set in the summary info district; Can be so that when in the data file district of hard disk, preserving video file data; According to document format data and the size created in advance; Preserve the video recording data respectively in each data file in the data file district; And in its index information, deposit the index information of this data file, according to this index information or data file writable status the summary info in one of them B+ tree district in the summary info district in B+ tree district is at least once upgraded data file summary info that uses when reaching the file system index search and index information cooperation renewal synchronously simultaneously; Increase the real-time of system, guaranteed data integrity and accuracy.
Specifically, the summary info district comprises main B+ tree district and is equipped with B+ tree district, and each B+ tree district comprises at least one B+ tree.
In other preferences of the present invention; According to this index information or data file writable status; The summary info that two B+ that main B+ tree in the summary info district is distinguished set at least once upgrades simultaneously, when this main B+ tree damages, can proceed to read and write through another B+ tree.When this main B+ tree district suffers the physics permanent damages, just need be through the preservation of being recorded a video in another B+ tree district.
When certain passage is begun to record a video, through retrieval, find the operable data file of this passage, and upgrade in the step of the summary info of this data file in the B+ tree the B+ tree, can also comprise following substep:
If detect the corresponding index information district physical damage of data file, then set writing the damage mark in the summary info of data file at B+.When the index information district of data file correspondence physical damage; Can this data file be labeled as damage; Then this data file will no longer be used; And in B+ tree summary info record, continue to use the problem that hard disk areas causes loss of data of having damaged when avoiding the digital hard disc video recorder video file to preserve or play.
Preferably, fdisk structural representation as shown in Figure 2 is provided with data file district and summary info district in advance on hard disk; The data file district comprises a plurality of data files; Comprise index information and video recording data in each data file, the summary info zoning is divided into main B+ tree district and these two B+ tree districts, subsequent use B+ tree district, and each B+ tree district comprises two B+ trees; When the data file district at hard disk carries out the video file data preservation; According to document format data and the size created in advance, preserve the video recording data respectively in each data file in the data file district, and in its index information part, deposit the index information of this data file.
Fig. 3 is based on the schematic flow sheet of the store method of this improved digital hard disc video recorder video file.As a preference of the present invention, the store method of this digital hard disc video recorder video file as shown in Figure 3, specifically,
In step 301, open certain paths N video recording;
After this get into step 302,, find the operable data file of this passage, upgrade the summary info of B+ tree about this data file through retrieving main B+ tree;
After this get into step 303, whenever upgrade index information at a distance from one period set time in the data recording process, index information essential record data begin information such as concluding time, data slot size;
After this get into step 304, write when full, upgrade the summary info of B+ tree once more about this data file when data file;
After this get into step 305, judge whether work as prepass continues video recording;
If not, process ends then; Otherwise, return step 302.
Third embodiment of the invention relates to a kind of data reconstruction method of digital hard disc video recorder video file.The data reconstruction method of this digital hard disc video recorder video file, subregion on hard disk for each data file in the data file district, reads index information and extracts summary info in advance, this summary info is inserted in the B+ tree in summary info district again.
Specifically,
Data file district and summary info district are set on hard disk in advance; Comprise a plurality of data files of creating in advance in the data file district; Comprise index information and video recording data in each data file, the summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree.
For each data file in the data file district, carry out following steps:
The index information of read data files.
From index information, extract summary info.
Summary info is inserted in the B+ tree in summary info district.
Data file storage order according to video file in the file data district; Last data file until this video file; Obtain the summary info of each data file of video file in the data file district one by one; Be used to accomplish the index reconstruct of the summary info of B+ tree; Utilized the abrasion equilibration characteristic of B+ tree construction operation, guaranteed the complete sum order of the B+ tree of all data file summary infos in the summary info district of video file, thereby the correct and partial data restoration methods of the video file of digital hard disc video recorder is provided.Index is put in the data file, sets management profile with B+, and summary info is distinguished into 2 main B+ trees in district and subsequent use B+ tree, read-write successively, both anti-makeing mistakes, anti-again focus.
The index information of data file is disperseed, and no longer certain FX (index area) is is no longer frequently read and write in centralized management, has reduced the hard disk failure probability.Eliminated the hot spot region, improved total system stability, system can not paralyse because of Single Point of Faliure.
According to the data file storage order of video file in the file data district, obtain a data files of video file in the data file district, up to last data file of this video file.
In other embodiments of the present invention; Include, but are not limited to insert and recover to the video file sequential access or in the extraction one by one of the summary info of the B+ in summary info district tree; Can be after all summary infos of whole disposable data file index files that obtains video file in the data file district; Be inserted in the B+ tree same, make the summary info of this B+ tree revert to summary info, wherein store the summary info of the data file of video file in this B+ tree.Also can carry out the recovery of the B+ tree summary info of video file according to certain duration or disk read-write strategy.
Fig. 4 is based on the schematic flow sheet of the data reconstruction method of this improved digital hard disc video recorder video file.As a preference of the present invention, the data reconstruction method of this digital hard disc video recorder video file as shown in Figure 4, specifically,
In step 401, the index information of read data files;
After this get into step 402, from index information, extract summary info;
After this get into step 403, summary info is inserted in the B+ tree in summary info district.
Four embodiment of the invention relates to a kind of data reconstruction method of digital hard disc video recorder video file.
The 4th embodiment improves on the basis of the 3rd embodiment; Main improvements are: after the index information of read data files; Detect whether physical damage of the corresponding index information district of data file; Then write bad piece mark to what damaged, avoid loss of data in this summary info district; In addition, hard disk is carried out subregion, when main B+ tree damages, can summary info be inserted in the B+ tree in subsequent use B+ tree district in summary info district.
Specifically,
After the step of the index information of read data files, further comprising the steps of:
If detect the corresponding index information district physical damage of data file, then set writing the damage mark in the summary info of data file at B+.
When the data file corresponding physical is damaged the index information district; Can this data file be labeled as and damage and will no longer be used; And in B+ tree summary info record, continue to use the problem that hard disk areas causes loss of data of having damaged in the time of can avoiding the digital hard disc video recorder video file to preserve or play.
When the index information district of data file correspondence physical damage; Can this data file be labeled as damage; Then this data file will no longer be used; And in B+ tree summary info record, continue to use the problem that hard disk areas causes loss of data of having damaged when avoiding the digital hard disc video recorder video file to preserve or play.
The summary info district comprises main B+ tree district and is equipped with B+ tree district, and each B+ tree district comprises at least one B+ tree.
When main B+ sets district's physical damage, in the step in summary info being inserted into the B+ tree in summary info district, summary info is inserted in the B+ tree that the B+ tree is distinguished fully.
Utilize B+ tree management data document information, when reducing memory consumption, kept work efficiency almost constant, improved the hard-disc storage and the management function of this embedded system of digital hard disc video recorder.
Data file storage order according to video file in the file data district; Last data file until this video file; The summary info that obtains each data file of video file in the data file district is one by one accomplished the index reconstruct of the summary info of B+ tree, has utilized the abrasion equilibration characteristic of B+ tree construction operation.
If the B+ tree district physical damage at the B+ that passage often uses tree place; Just can be in the video file data file; Be inserted into the B+ tree in the subsequent use B+ tree district through extracting its summary info of its index information; Recovery is to the function of hard-disc storage digital hard disc video recorder video file; Guarantee the complete sum order of the B+ tree of all data file summary infos in the summary info district of video file, thereby the correct and partial data restoration methods of the video file of digital hard disc video recorder is provided, and improved system stability and lasting effectiveness.
If the B+ that passage often uses tree is destroyed, can search the index information that reads each data file one by one according to the order of sequence, the summary info that extracts and insert in the index information is set to B+, and main B+ tree is recovered.
Fig. 5 is based on the schematic flow sheet of the data reconstruction method of this improved digital hard disc video recorder video file.As a preference of the present invention, the data reconstruction method of this digital hard disc video recorder video file as shown in Figure 5, specifically,
In step 501, judge that whether hard disk summary info district master B+ tree distinguish physical damage;
If not, then get into step 502; Otherwise, get into step 508;
In step 502, the index information of read data files;
After this get into step 503, judge whether physical damage of index information district;
If then get into step 507; Otherwise, get into step 504;
In step 507, mark master B+ tree district B+ tree summary info damages, and after this returns step 502;
In step 504, extract this summary info;
After this get into step 505, insert summary info in the B+ tree in main B+ tree district;
After this get into step 506, whether the judgment data file is last;
If not, then return step 502; Otherwise, process ends;
In step 508, the index information of read data files;
After this get into step 509, judge whether physical damage of index information district;
If then get into step 513; Otherwise, get into step 510;
In step 513, the subsequent use B+ tree of mark district B+ tree summary info damages, and after this returns step 508;
In step 510, extract summary info;
After this get into step 511, insert summary info in the B+ tree that is equipped with B+ tree district;
After this get into step 512, whether the judgment data file is last;
If not, then return step 508; Otherwise, process ends;
Fig. 6 is based on the schematic flow sheet of the data reconstruction method of this improved digital hard disc video recorder video file.As a preference of the present invention, the data reconstruction method of this digital hard disc video recorder video file as shown in Figure 6, specifically,
In step 601, read first data file index information;
After this get into step 602, extract summary info and upgrade the summary info that is equipped with B+ tree district B+ tree;
After this get into step 603, judge whether it is last data file;
If then return step 601; Otherwise, get into step 604;
In step 604, read next data file index information, after this process ends;
Each method embodiment of the present invention all can be realized with modes such as software, hardware, firmwares.No matter the present invention be with software, hardware, or the firmware mode realize; Instruction code can be stored in the storer of computer-accessible of any kind (for example permanent or revisable; Volatibility or non-volatile; Solid-state or non-solid-state, fixing perhaps removable medium or the like).Equally; Storer can for example be programmable logic array (Programmable Array Logic; Abbreviation " PAL "), RAS (Random Access Memory; Abbreviation " RAM "), programmable read only memory (Programmable Read Only Memory is called for short " PROM "), ROM (read-only memory) (Read-Only Memory is called for short " ROM "), Electrically Erasable Read Only Memory (Electrically Erasable Programmable ROM; Abbreviation " EEPROM "), disk, CD, digital versatile disc (Digital Versatile Disc is called for short " DVD ") or the like.
Fifth embodiment of the invention relates to a kind of saved system of digital hard disc video recorder video file.Fig. 7 is the structural representation of the saved system of this digital hard disc video recorder video file.The saved system system of this digital hard disc video recorder video file comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree.
Retrieval module, when being used for certain passage begun to record a video, retrieval B+ tree is found the operable data file of this passage.
The first summary update module when being used for retrieval module and finding data file, is upgraded the summary info of this data file in the B+ tree.
The index upgrade module is used in the video data recording process, and the index information in the data file that retrieval module is found upgrades.
State and also comprise with lower module:
Judge module is used to judge whether current data file is write full.
The second summary update module is write fullly if be used for current data file that judge module judges, upgrades in the B+ tree summary info to this data file.
First embodiment is and the corresponding method embodiment of this embodiment, this embodiment can with the enforcement of working in coordination of first embodiment.The correlation technique details of mentioning in first embodiment is still effective in this embodiment, in order to reduce repetition, repeats no more here.Correspondingly, the correlation technique details of mentioning in this embodiment also can be applicable in first embodiment.
Sixth embodiment of the invention relates to a kind of saved system of digital hard disc video recorder video file.
The 6th embodiment improves on the basis of the 5th embodiment, and main improvements are: hard disk has been waken up with a start main and has been equipped with B+ set subregion, increased the stability and the reliability of saved system.
The summary info district comprises main B+ tree district and is equipped with B+ tree district, and each B+ tree district comprises at least one B+ tree.
Second embodiment is and the corresponding method embodiment of this embodiment, this embodiment can with the enforcement of working in coordination of second embodiment.The correlation technique details of mentioning in second embodiment is still effective in this embodiment, in order to reduce repetition, repeats no more here.Correspondingly, the correlation technique details of mentioning in this embodiment also can be applicable in second embodiment.
Seventh embodiment of the invention relates to a kind of data recovery system of digital hard disc video recorder video file.Fig. 8 is the structural representation of the data recovery system of this digital hard disc video recorder video file.The data recovery system system of this digital hard disc video recorder video file comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree.
Read module is used for the index information of read data files.
The abstract extraction module is used for extracting summary info from the index information that read module reads.
Insert module is used for the summary info that the abstract extraction module is extracted is inserted into the B+ tree in summary info district.
The 3rd embodiment is and the corresponding method embodiment of this embodiment, this embodiment can with the enforcement of working in coordination of the 3rd embodiment.The correlation technique details of mentioning in the 3rd embodiment is still effective in this embodiment, in order to reduce repetition, repeats no more here.Correspondingly, the correlation technique details of mentioning in this embodiment also can be applicable in the 3rd embodiment.
Eighth embodiment of the invention relates to a kind of data recovery system of digital hard disc video recorder video file.Fig. 9 is the structural representation of the data recovery system of this digital hard disc video recorder video file.
The 8th embodiment improves on the basis of the 7th embodiment, and main improvements are: in data recovery system, increased writing module, damaged judge module; In read module, increased the submodule detection sub-module, when the main B+ tree that said damage judge module is judged was distinguished physical damage, insert module also was inserted into summary info in the B+ tree in the said B+ of being equipped with tree district.
Specifically,
Read module also comprises following submodule:
Whether detection sub-module is used to detect the corresponding index information district physics of data file and damages.
System also comprises with lower module:
Writing module detects the corresponding index information district physical damage of data file if be used for detection module, then sets writing the damage mark in the summary info of data file at B+.
The summary info district comprises main B+ tree district and is equipped with B+ tree district, and each B+ tree district comprises at least one B+ tree.
Damage judge module, be used to judge that whether master B+ tree in hard disk summary info district distinguish physical damage;
When the main B+ tree that said damage judge module is judged was distinguished physical damage, said insert module was inserted into summary info in the B+ tree in the said B+ of being equipped with tree district.
The 4th embodiment is and the corresponding method embodiment of this embodiment, this embodiment can with the enforcement of working in coordination of the 4th embodiment.The correlation technique details of mentioning in the 4th embodiment is still effective in this embodiment, in order to reduce repetition, repeats no more here.Correspondingly, the correlation technique details of mentioning in this embodiment also can be applicable in the 4th embodiment.
Need to prove; Each module of mentioning in each equipment embodiment of the present invention all is a logic module, and physically, a logic module can be a physical module; It also can be the part of a physical module; Can also realize that the physics realization mode of these logic modules itself is not most important with the combination of a plurality of physical modules, the combination of the function that these logic modules realized is the key that just solves technical matters proposed by the invention.In addition, for outstanding innovation part of the present invention, above-mentioned each the equipment embodiment of the present invention will not introduced with solving the not too close module of technical matters relation proposed by the invention, and this does not show that there is not other module in the said equipment embodiment.
Though through reference some preferred implementation of the present invention; The present invention is illustrated and describes; But those of ordinary skill in the art should be understood that and can do various changes to it in form with on the details, and without departing from the spirit and scope of the present invention.

Claims (12)

1. the store method of a digital hard disc video recorder video file; It is characterized in that; Data file district and summary info district are set on hard disk in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Said method comprising the steps of:
When certain passage is begun to record a video,, find the operable data file of this passage, and upgrade the summary info of this data file in the B+ tree through retrieval to said B+ tree;
In the video data recording process, the index information in this data file is upgraded.
2. the store method of digital hard disc video recorder video file according to claim 1 is characterized in that,, in the video data recording process, the index information in this data file is carried out after the updating steps said, and is further comprising the steps of:
Current data file write full after, upgrade in the B+ tree summary info to this data file.
3. according to the store method of each described digital hard disc video recorder video file in the claim 1 to 2, it is characterized in that said summary info district comprises main B+ tree district and is equipped with B+ tree district, each B+ tree district comprises at least one B+ tree.
4. the data reconstruction method of a digital hard disc video recorder video file; It is characterized in that; Data file district and summary info district are set on hard disk in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
For each data file in the said data file district, carry out following steps:
The index information of read data files;
From said index information, extract summary info;
Said summary info is inserted in the B+ tree in said summary info district.
5. the data reconstruction method of digital hard disc video recorder video file according to claim 4 is characterized in that, and is after the step of the index information of said read data files, further comprising the steps of:
If detect the corresponding index information district physical damage of data file, then set writing the damage mark in the summary info of data file at said B+.
6. according to the data reconstruction method of claim 4 or 5 described digital hard disc video recorder video files, it is characterized in that said summary info district comprises main B+ tree district and is equipped with B+ tree district, each B+ tree district comprises at least one B+ tree;
When said main B+ sets district's physical damage, in the step in the said B+ that summary info is inserted into said summary info district sets, summary info is inserted into the said B+ of being equipped with sets in the B+ tree of distinguishing.
7. the saved system of a digital hard disc video recorder video file is characterized in that, said system comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Retrieval module when being used for certain passage begun to record a video, is retrieved said B+ tree, finds the operable data file of this passage;
The first summary update module when being used for said retrieval module and finding said data file, is upgraded the summary info of this data file in the B+ tree;
The index upgrade module is used in the video data recording process, and the index information in the said data file that said retrieval module is found upgrades.
8. the saved system of digital hard disc video recorder video file according to claim 7 is characterized in that, states also to comprise with lower module:
Judge module is used to judge whether current data file is write full;
The second summary update module is write fullly if be used for current data file that said judge module judges, upgrades in the B+ tree summary info to this data file.
9. according to the saved system of each described digital hard disc video recorder video file in the claim 7 to 9, it is characterized in that said summary info district comprises main B+ tree district and is equipped with B+ tree district, each B+ tree district comprises at least one B+ tree.
10. the data recovery system of a digital hard disc video recorder video file is characterized in that, said system comprises with lower module:
Hard disk; Data file district and summary info district are set in advance, comprise a plurality of data files of creating in advance in the data file district, comprise index information and video recording data in each data file; The summary info district comprises a B+ tree at least, stores the summary info of each data file in this B+ tree;
Read module is used to read the index information of said data file;
The abstract extraction module is used for extracting summary info from the index information that said read module reads;
Insert module is used for the summary info that said abstract extraction module is extracted is inserted into the B+ tree in summary info district.
11. the data recovery system of digital hard disc video recorder video file according to claim 10 is characterized in that, said read module also comprises following submodule:
Whether detection sub-module is used to detect the corresponding index information district physics of data file and damages;
Said system also comprises with lower module:
Writing module detects the corresponding index information district physical damage of data file if be used for said detection module, then sets writing the damage mark in the summary info of data file at said B+.
12. the data recovery system according to claim 10 or 11 described digital hard disc video recorder video files is characterized in that, said summary info district comprises main B+ tree district and is equipped with B+ tree district, and each B+ tree district comprises at least one B+ tree;
Said system also comprises with lower module:
Damage judge module, be used to judge that whether master B+ tree in hard disk summary info district distinguish physical damage;
When the main B+ tree that said damage judge module is judged was distinguished physical damage, said insert module was inserted into summary info in the B+ tree in the said B+ of being equipped with tree district.
CN201110252626.8A 2011-08-30 2011-08-30 Digital hard disc video recorder video file is preserved method and the system thereof recovered with data Active CN102385610B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110252626.8A CN102385610B (en) 2011-08-30 2011-08-30 Digital hard disc video recorder video file is preserved method and the system thereof recovered with data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110252626.8A CN102385610B (en) 2011-08-30 2011-08-30 Digital hard disc video recorder video file is preserved method and the system thereof recovered with data

Publications (2)

Publication Number Publication Date
CN102385610A true CN102385610A (en) 2012-03-21
CN102385610B CN102385610B (en) 2016-05-04

Family

ID=45825027

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110252626.8A Active CN102385610B (en) 2011-08-30 2011-08-30 Digital hard disc video recorder video file is preserved method and the system thereof recovered with data

Country Status (1)

Country Link
CN (1) CN102385610B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103514226A (en) * 2012-06-28 2014-01-15 浙江大华技术股份有限公司 Rapid indexing method and device for file storage of digital video recorder
CN103886883A (en) * 2014-03-20 2014-06-25 公安部物证鉴定中心 Method and system for recovering lossy video monitoring data
CN104301682A (en) * 2014-10-22 2015-01-21 厦门市美亚柏科信息股份有限公司 Monitoring video fragment restoration method and device
CN104317833A (en) * 2014-10-10 2015-01-28 深圳市锐明视讯技术有限公司 Method and device for recovering system file indexes
CN104333725A (en) * 2014-11-27 2015-02-04 天津天地伟业数码科技有限公司 Streaming storage equipment of embedded hard disk video and method of streaming storage equipment of embedded hard disk video
CN106326139A (en) * 2015-06-30 2017-01-11 华平智慧信息技术(深圳)有限公司 Audio/video data file circulating memory method and system
CN111078159A (en) * 2019-12-31 2020-04-28 深圳市思博慧数据科技有限公司 Writing method for avoiding writing damage of DVR storage card

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1750164A (en) * 2005-07-20 2006-03-22 杭州海康威视数字技术有限公司 Digital hard disc recorder file managing method for preventing file fragment production
CN101568968A (en) * 2006-12-21 2009-10-28 汤姆森许可贸易公司 Method for creating a new summary of an audiovisual document that already includes a summary and reports and a receiver that can implement said method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1750164A (en) * 2005-07-20 2006-03-22 杭州海康威视数字技术有限公司 Digital hard disc recorder file managing method for preventing file fragment production
CN101568968A (en) * 2006-12-21 2009-10-28 汤姆森许可贸易公司 Method for creating a new summary of an audiovisual document that already includes a summary and reports and a receiver that can implement said method

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103514226B (en) * 2012-06-28 2017-11-10 浙江大华技术股份有限公司 A kind of fast indexing method and device of the storage of digital hard disc video recorder file
CN103514226A (en) * 2012-06-28 2014-01-15 浙江大华技术股份有限公司 Rapid indexing method and device for file storage of digital video recorder
CN103886883A (en) * 2014-03-20 2014-06-25 公安部物证鉴定中心 Method and system for recovering lossy video monitoring data
CN103886883B (en) * 2014-03-20 2016-08-17 公安部物证鉴定中心 A kind of to damaging the method and system that video monitoring data recovers
CN104317833A (en) * 2014-10-10 2015-01-28 深圳市锐明视讯技术有限公司 Method and device for recovering system file indexes
CN104317833B (en) * 2014-10-10 2019-03-26 深圳市锐明技术股份有限公司 A kind of method and device of recovery system file index
CN104301682A (en) * 2014-10-22 2015-01-21 厦门市美亚柏科信息股份有限公司 Monitoring video fragment restoration method and device
CN104301682B (en) * 2014-10-22 2017-07-11 厦门市美亚柏科信息股份有限公司 The restoration methods and device of a kind of monitor video fragment
CN104333725B (en) * 2014-11-27 2018-03-27 天地伟业技术有限公司 The streaming storage device and its method of built-in hard disk video tape recorder
CN104333725A (en) * 2014-11-27 2015-02-04 天津天地伟业数码科技有限公司 Streaming storage equipment of embedded hard disk video and method of streaming storage equipment of embedded hard disk video
CN106326139A (en) * 2015-06-30 2017-01-11 华平智慧信息技术(深圳)有限公司 Audio/video data file circulating memory method and system
CN111078159A (en) * 2019-12-31 2020-04-28 深圳市思博慧数据科技有限公司 Writing method for avoiding writing damage of DVR storage card
CN111078159B (en) * 2019-12-31 2023-11-03 深圳市思博慧数据科技有限公司 Writing method for avoiding DVR storage card writing damage

Also Published As

Publication number Publication date
CN102385610B (en) 2016-05-04

Similar Documents

Publication Publication Date Title
CN102385610A (en) Method of video recording document storage and data recovery of digital hard-disc video recorder and system thereof
CN1609984B (en) Method and apparatus for recording data and recovering recorded data
CN100578470C (en) Audio/video data access method and device based on raw device
CN103226965B (en) Based on the audio/video data access method of time bitmap
CN101706822B (en) Method and device for improving speed of mounting journal file system
JP2007012058A (en) File system for storing transaction records in flash-like media
CN104899114B (en) A kind of continuous time data guard method on solid state hard disc
RU2006127439A (en) QUICK ACCESS TO DISC MANAGEMENT INFORMATION
US20090037646A1 (en) Method of using a flash memory for a circular buffer
CN102932621A (en) Method and device for storing data
CN104239438A (en) File information storage method and file information read-write method based on separate storage
CN102722443A (en) Bad block management method for flash memory
CN103729262A (en) Operating system hot backup method and device and file system reconstruction method
CN104063187A (en) Hard disk file system suitable for security application and operation method thereof
US20140379649A1 (en) Distributed storage system and file synchronization method
CN100543748C (en) A kind of method and system of utilizing file allocation table to carry out the file tracking
CN116088770A (en) Data management method, device, system, electronic equipment and storage medium
WO2008136563A1 (en) Method of storing meta-data and system for storing meta-data
CN102253938B (en) Method and device for writing and restoring file
TW200713240A (en) Data recording methods and systems for rewritable disks
KR101258589B1 (en) Information storage medium recording data according to journaling file system, method and apparatus of writing/recovering data using journaling file system
CN105446652A (en) Method and device for storing camera shooting data
CN102279779A (en) Method and device for realizing redundancy backup of video data on digital video recorder
CN108197218B (en) Method for inheriting SSD (solid State disk) key log
CN102117623B (en) Method and device for recovering magnetic tape metadata

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