CN108932249A - A kind of method and device managing file system - Google Patents
A kind of method and device managing file system Download PDFInfo
- Publication number
- CN108932249A CN108932249A CN201710375466.3A CN201710375466A CN108932249A CN 108932249 A CN108932249 A CN 108932249A CN 201710375466 A CN201710375466 A CN 201710375466A CN 108932249 A CN108932249 A CN 108932249A
- Authority
- CN
- China
- Prior art keywords
- file system
- file
- destination
- data
- check value
- 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
Links
- 238000000034 method Methods 0.000 title claims abstract description 36
- 238000003860 storage Methods 0.000 claims description 19
- 230000008439 repair process Effects 0.000 claims description 17
- 238000010586 diagram Methods 0.000 description 16
- 238000013461 design Methods 0.000 description 14
- 238000012795 verification Methods 0.000 description 10
- 238000012545 processing Methods 0.000 description 9
- 238000004590 computer program Methods 0.000 description 8
- 238000004891 communication Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 6
- 230000008569 process Effects 0.000 description 6
- 238000007689 inspection Methods 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 125000004122 cyclic group Chemical group 0.000 description 2
- 238000005516 engineering process Methods 0.000 description 2
- 238000004422 calculation algorithm Methods 0.000 description 1
- 238000000151 deposition Methods 0.000 description 1
- 210000001145 finger joint Anatomy 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 230000014759 maintenance of location Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F11/00—Error detection; Error correction; Monitoring
- G06F11/07—Responding to the occurrence of a fault, e.g. fault tolerance
- G06F11/14—Error detection or correction of the data by redundancy in operation
- G06F11/1402—Saving, restoring, recovering or retrying
- G06F11/1446—Point-in-time backing up or restoration of persistent data
- G06F11/1448—Management of the data involved in backup or backup restore
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Quality & Reliability (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
A kind of method and device managing file system, causes user that cannot timely use file system to consistency check when solving the problems, such as carry file system existing in the prior art.It is described management file system method include:When not carrying out consistency check to corresponding first file system of the first data subregion, carry first file system;When reading file destination by first file system, judge whether the first check value of the file destination is correct;If first check value of the file destination is incorrect, which is repaired by file system check Fsck tool.
Description
Technical field
This application involves field of computer technology more particularly to a kind of method and devices for managing file system.
Background technique
File system (file system, FS) in computer requires file structure complete, between metadata, metadata
It is consistent between data, wherein metadata refers to the data for describing data attribute.But the consistency of file system sometimes
It is likely to be broken, such as when system is powered down, the data in memory can lose, or due to disk failures, such as Bad Track,
The consistency of file system data will be destroyed.For the inconsistent file system of examination and maintenance, file system can provide text
Part systems inspection (FS check, Fsck) tool come facilitate user check and repair file system.
Fsck tool can check the consistency of file system before carry file system, such as examine in starting at the beginning of system
The consistency of file system is looked into, alternatively, checking the consistency of file system when reloading file system.Fsck checks consumption
Time data subregion corresponding to file system size and the data subregion quantity of documents it is related, data subregion is got over
Greatly, quantity of documents is more, and Fsck checks that the time of consumption is more long.
Currently, big data business requires the size of data subregion increasing, the data stored in data subregion are increasingly
It is more, cause in carry file system need take considerable time carry out file system consistency check, prevent user from
Timely use file system.
Summary of the invention
The application provides a kind of method and device for managing file system, to solve carry text existing in the prior art
The problem of consistency check when part system causes user that cannot timely use file system.
In a first aspect, the embodiment of the present application provides a kind of method for managing file system, including:In system BootLoader text
When part system, and after system operation when carry file system again, the file system of carry will be needed to be considered as and met unanimously
Property require, not to file system carry out consistency check, direct carry file system.It is read in File system in application
When file destination, file system can verify file destination, if check value mistake, it is determined that and mistake occurs for file destination,
It determines that the data consistency in file system is destroyed, Fsck tool is called to carry out consistency reparation to file system.
In above-mentioned technical proposal, node does not carry out consistency check to file system before carry file system, so that
File system can timely carry, user can use file system as early as possible.During reading file by file system,
Once guaranteeing that the data of file system are consistent it was found that file error, then can call Fsck tool to repair file system
Property.In file system file occur a possibility that mistake it is lower when, the number repaired by Fsck to file system is very
It is few, compared with the scheme for carrying out consistency check before each carry file system in the prior art, it can effectively reduce
The number that Fsck is checked, reduces the time-consuming of consistency check, and then the efficiency of file system can be improved.
As a kind of optional design, when the first check value of the file destination in file system is incorrect, text
The reliability of part system reduces, and unloads the file system, ensures the correctness of business, guarantees that user obtains correct file.
As a kind of optional design, when the first check value of the file destination in file system is incorrect, text
Most of file in part system may be still correctly that file system still has the energy for providing a user correct file
Power, not unloading of file system, but a reading mode is set by file system, it allows users to continue to access in file system
There is no mistake file, improve the performance of entire file system.Moreover, setting a reading mode, energy for file system
Mistake occurs after enough new data being avoided to be written into file system, guarantees the reliability of data.
As a kind of optional design, if the first check value of the file destination in file system is incorrect
Unload the file system, then after repairing the file system by the Fsck tool, carry file system again, and
Readable writeable mode is set by file system, so that file system can continue to provide services to the user.
As a kind of optional design, if the first check value of the file destination in file system is incorrect
A reading mode is set by file system, then after repairing the file system by the Fsck tool, by the file
System is set as readable writeable mode, so that file system can continue to provide services to the user.
As a kind of optional design, if file system determines that file destination is not sent out after verifying to file destination
Raw mistake then reads file destination by file system and file destination is sent to application, applies and obtain from file system
After file, secondary verification is carried out to file, the correctness of file is further ensured that, improves the reliability of business.Also, it applies
After determining file destination mistake, the Backup Data of this document can be read from alternative document system, and using the backup to mistake
File repaired, improve file system in data reliability.
As a kind of optional design, two file system can store same file, and both of these documents system is corresponding
Data subregion can be with position in same storage equipment (such as disk), the different storages that can also be located in same node are set
It is standby upper, it can also be located in two different nodes.
As a kind of optional mode, applies and secondary verification really is being carried out to file destination, it is wrong to determine that file destination occurs
After accidentally, the data subregion for storing the file destination is deactivated, to guarantee the correctness of business, guarantees that user obtains correct file.
Second aspect, the embodiment of the present application provide a kind of device for managing file system, the device of the management file system
The method in any optional design for executing above-mentioned first aspect or first aspect.Specifically, the management file system
Device include module for executing the method in any optional design of above-mentioned first aspect or first aspect.
The third aspect, the embodiment of the present application provide a kind of device for managing file system, including:Memory, processor with
And communication interface.Memory is stored with computer instruction, and processor is communicated by communication interface with other nodes, and is passed through
The computer instruction stored in the memory is called, to execute any optional design of above-mentioned first aspect or first aspect
In method.
Fourth aspect, the embodiment of the present application provide a kind of computer readable storage medium, deposit in the readable storage medium storing program for executing
Computer instruction is contained, when described instruction is run on computers, so that computer executes above-mentioned first aspect or first aspect
Any optional design in method.
Detailed description of the invention
Fig. 1 is a kind of schematic diagram of distributed file system provided by the embodiments of the present application;
Fig. 2 is the flow diagram of the method for management file system provided by the embodiments of the present application;
Fig. 3 is the schematic diagram of file system check data in the embodiment of the present application;
Fig. 4 is another flow diagram of the method for management file system provided by the embodiments of the present application;
Fig. 5 is the schematic diagram that file system is managed in the embodiment of the present application;
Fig. 6 is the schematic diagram that the device of file system is managed in the embodiment of the present application;
Fig. 7 is another schematic diagram that the device of file system is managed in the embodiment of the present application.
Specific embodiment
In order to keep the purposes, technical schemes and advantages of the application clearer, below in conjunction with attached drawing to the application make into
One step it is described in detail.
In the prior art, it in system starting or carry file system again, needs to carry out consistency inspection to file system
It looks into, and consistency check will take a substantial amount of time, prevent user is from timely using file system.And in some network texts
In part system, the consistency of file is safeguarded by remote storage server, and still, remote storage server can become file system
Bottleneck, the access efficiency of constraint file system, once moreover, remote storage server break down, will lead to entire file
System is inaccessible.
The application provides a kind of method and device for managing file system, to solve carry text existing in the prior art
The problem of consistency check when part system causes user that cannot timely use file system.Wherein, method and apparatus are to be based on
Same inventive concept, since the principle that method and device solves the problems, such as is similar, the implementation of apparatus and method can be mutual
Referring to overlaps will not be repeated.
It is to be appreciated that it is multiple involved in the application, refer to two or more.In addition, the application's
In description, the vocabulary such as " first ", " second " are only used for distinguishing the purpose of description, be not understood to indicate or imply relatively heavy
The property wanted can not be interpreted as indication or suggestion sequence.
This application can be applied to distributed degree system, two or more nodes in the distributed system can form height
Availability (High Available, HA) cluster.In system as shown in Figure 1, node 1 includes data subregion 1~3, every number
According to the corresponding file system of subregion, respectively FS1~FS3, similarly, node 2 include data subregion 4~6, respective file system
FS4~FS6.Promising client is run on node 1 and node 2, and the same application of service, the file system in node 1 are provided
Mistake occurs for the data saved in FS2, and when causing the application on node 1 that cannot provide service, the application on node 2 can be immediately
The application connected on node 1 for client provides service, realize business do not interrupt or short interruption.In the embodiment of the present application mutually
Relationship between the different nodes of HA can be:Active and standby, full work, N+M, it is so-called active and standby to refer to based on one of node
Node (i.e. active node), remaining node are slave node;Full work refers to that all nodes are active node;N+M refers to it
In N number of node be active node, M node is slave node.
Fig. 2 is the flow diagram of the method for management file system provided by the embodiments of the present application, and this method may include
Following processing:
Step 101, not to corresponding first file system of the first data subregion carry out consistency check when, carry first
File system.
In the embodiment of the present application, in system BootLoader file system, and the carry file again after system operation
When system, the file system of carry will be needed to be considered as and meet coherence request, consistency check is not carried out to file system, directly
Carry file system.
Step 102, by the first file system read file destination when, judge file destination the first check value whether
Correctly.
First file system is the corresponding file system of any data subregion in any node.File the is read in application
When file destination in one file system, the first file system can verify file destination, for example, calculating file destination
First check value is compared, if inconsistent by the first check value with the check value prestored, it is determined that file destination occurs wrong
Accidentally.Above-mentioned first check value can be there are many implementation, corresponding a variety of verification means.For example, referring to Fig. 3, literary to first
Part system be written file data when, record this document (or data block of file) check value, such as verification and
(checksum), Hash (hash) value, cyclic redundancy check (Cyclic Redundancy Check, CRC) etc..Then, it is answering
When with reading this document from the first file system, the data check of the first file system calculation document (or data block of file)
Value, the data check value of calculating is compared with the data check value of storage, if inconsistent, shows that mistake occurs for file.
If the first check value of step 103, file destination is incorrect, the is repaired by file system check Fsck tool
One file system.
After the first file system determines that mistake occurs for file destination by calculating data check value, the first file system is determined
Data consistency on system is destroyed, and calls Fsck tool to carry out consistency reparation to the first file system, for example, Fsck tool
Journal file can be read, the file in the first file system is repaired according to the journal file of reading.Fsck is repaired
The detailed process of multiple first file system, please refers to various technological means in the prior art, is not described in detail herein.
In above-mentioned technical proposal, node does not carry out consistency check to file system before carry file system, so that
File system can timely carry, user can use file system as early as possible.During reading file by file system,
Once guaranteeing that the data of file system are consistent it was found that file error, then can call Fsck tool to repair file system
Property.As can be seen that being repaired by Fsck to file system when a possibility that mistake occurs in file in file system is lower
Number it is seldom, in the prior art before each carry file system carry out consistency check scheme compared with, the application
The scheme that embodiment provides can effectively reduce the number of Fsck inspection, reduce the time-consuming of consistency check, improve file system
Efficiency.Moreover, there may be the spare sections after the inconsistent mistake of data, in HA system in the file system after carry
Point or other active nodes can still be provided out service, and user still can continue to read file destination.
It further include after step 102 following steps referring to Fig. 4 as a kind of optional design:
If the first check value of step 104, file destination is incorrect, a reading mode is set by the first file system or is unloaded
Carry the first file system.
First check value of file destination is incorrect to show that mistake, the reliability drop of the first file system occur for file destination
Low, the first file system of unloading can guarantee the correctness of business, guarantee that user obtains correct file.
Alternatively possible implementation is:The first file system is not unloaded, but sets the first file system to only
Reading mode.The first file error being because while in the first file system, but most of file in the first file system
Usually it is still correctly, the first file system still has the ability for providing a user correct file.But due to the first file
The file that mistake occurs is had existed in system, and the mistake may be depositing for the corresponding first data subregion of the first file system
Mistake occurs for storage area, continues that new data is written into the first file system, which is likely to occur mistake, it cannot be guaranteed that newly
The reliability of the data of the first file system is written.Therefore, a reading mode is set by the first file system, both enabled a user to
Enough continue access the first file system in there is no mistake file, improve the performance of entire file system, and be avoided that
New data is written into the first file system, guarantees the reliability of data.
As a kind of optional design, after step 103 and step 104, if Fsck tool successfully repairs the first text
Part system can then continue through the service that the first file system is provided out reading and writing of files.Specifically, if in step 104
It is middle to set a reading mode for the first file system, then by the first file system after Fsck tool successfully repairs the first file system
System is set as readable writeable mode.If unloading the first file system at step 104, is successfully repaired in Fsck tool
Again the first file system of carry after one file system, and readable writeable mode is set by the first file system.Above-mentioned skill
Art scheme can repair the file system that consistency error occurs in time, and configuration file system continues outward after repairing successfully
Service is provided.
As a kind of optional design, if Fsck tool successfully repairs the first file system, the first file system can lead to
Know the application using the first file system, the first file system has been restored, and application can continue to access the first file system.
It further include following steps after step 102 with continued reference to Fig. 4 as a kind of optional design:
If the first check value of step 105, file destination is correct, file destination can be read by the first file system,
If application when successfully reading file destination to request target file sends the file destination.
Step 106 judges whether the second check value of file destination is correct by above-mentioned application, the second check value and first
Check value is different.Second check value and the first check value can be same type of check value, for example, the first check value and second
Check value be file destination (or data block of file destination) verification and, still, due to calculate two verification sums it is specific
Algorithm is different, causes the first check value different from the second check value.In addition, the first check value and the second check value may be not
The check value of same type, for example, the first check value be verification and, the second check value be cryptographic Hash.Above-mentioned apply is receiving the first text
After the file destination that part system returns, secondary verification can be carried out to file destination according to the second check value, to ensure business
Correctness.
It, can be from the Backup Data for being stored with file destination if the second check value of step 107, file destination is incorrect
Corresponding second file system of the second data subregion in obtain the data of file destination, and according to target in the second file system
The data of file restore the data of file destination in the first file system.
When the second check value is incorrect, although showing that file destination passes through the verification of the first file system, but still deposit
In mistake, using can be to the second of another data subregion (i.e. the second data subregion) for the Backup Data for being stored with file destination
The file destination is read in file system, and when file destination is correct in the second file system, according in the second file system
File destination repairs the file destination in the first file system.Above-mentioned second data subregion and the first data subregion can be with
Positioned at same storage equipment (such as disk), it can also be located in the different storage device of same node, can also distinguish
In the node different positioned at two.
It in above-mentioned technical proposal, applies after obtaining file from file system, secondary verification is carried out to file, is further protected
The correctness for demonstrate,proving file, improves the reliability of business.Also, it applies after determining file destination mistake, it can be from alternative document
System reads the Backup Data of this document, and is repaired using file of the backup to mistake, improves data in file system
Reliability.
It as a kind of optional mode, applies after the second check value for determining file destination is incorrect, then deactivating should
First data subregion guarantees that user obtains correct file to guarantee the correctness of business.
Fig. 5 is the schematic diagram that a kind of possible implementation of file system is managed in the embodiment of the present application, the OS in figure
The operating system (Operating System) of finger joint point, Fsck tool can be realized by hardware chip, can also be by soft
Part module is realized, i.e., is realized by the processor operation computer program of node.In the implementation of Fig. 5, in OS starting, no
It runs Fsck tool and consistency check is carried out to file system, but directly carry file system, using accessible carry
File system.During using file system, if it find that there are consistency errors in file system, deposited using this is deactivated
In the file system of consistency error, and Fsck tool is called to repair this document system.After repairing successfully, Fsck work
The file system for having or being repaired can notify to apply, and make application that can restore to continue the file system that access has been repaired.
Fig. 6 is the schematic diagram of the device of provided by the embodiments of the present application kind of management file system, which includes:
Carry module 201 is used for when not carrying out consistency check to corresponding first file system of the first data subregion,
First file system described in carry;
Judgment module 202, for judging the file destination when reading file destination by first file system
The first check value it is whether correct;
Repair module 203, for being examined by file system when first check value of the file destination is incorrect
It looks into Fsck tool and repairs first file system.
Optionally, which further includes:
Configuration module 204, for when the first check value of the file destination is incorrect, by first file system
It is set as a reading mode or unloading first file system.
Optionally, the configuration module 204 is also used to:Institute is repaired by the Fsck tool in the repair module 203
After stating the first file system, if first file system is arranged to a reading mode, first file system is set
It is set to readable write state;Alternatively, if first file system is unloaded, the first file system described in carry.
Optionally, which further includes:
Sending module 205, for judging that first check value of the file destination is correct in the judgment module
Later, file destination can be read by the first file system, if successfully read file destination, to the request target text
The application of part sends the file destination;
Second judgment module 206, for judging whether the second check value of the file destination is correct by the application,
Second check value is different from first check value;
Second repair module 207, for when second check value of the file destination is incorrect, from storage
State the data that the file destination is obtained in corresponding second file system of the second data subregion of the Backup Data of file destination;
According to the data of file destination described in second file system to the number of file destination described in first file system
According to being restored.
Optionally, the first data subregion is located on different servers from the second data subregion.
It is schematically that only one kind is patrolled to the division of the module of the device of management file system in the embodiment of the present application
Function division is collected, there may be another division manner in actual implementation, in addition, each function mould in each embodiment of the application
Block can integrate in a processor, be also possible to physically exist alone, and can also be integrated in two or more modules
In one module.Above-mentioned integrated module both can take the form of hardware realization, can also use the shape of software function module
Formula is realized.
Wherein, when integrated module can take the form of hardware realization, as shown in fig. 7, the device of management file system
It may include processor 301.The hardware of the corresponding entity of above-mentioned module can be processor 301.Processor 301, can be one
A central processing module (central processing unit, CPU), or be digital processing module etc..Manage file system
The device of system can also include communication interface 302, and processor 301 is communicated by communication interface 302 with other nodes.The pipe
Reason file system device further include:Memory 303, the program executed for storage processor 301.Memory 301 can be
Nonvolatile memory, such as hard disk (hard disk drive, HDD) or solid state hard disk (solid-state drive, SSD)
Deng can also be volatile memory (volatile memory), such as random access memory (random-access
Memory, RAM).Memory 303 can be used for carrying or storing the desired program generation with instruction or data structure form
Code and can by any other medium of computer access, but not limited to this.
Processor 301 is used to execute the program code of the storage of memory 303, is specifically used for executing shown in Fig. 2, Fig. 4 or Fig. 5
The method of embodiment.The embodiment for managing the device of file system may refer to the side of Fig. 2, Fig. 4 or embodiment illustrated in fig. 5
Method, details are not described herein by the application.
It is not limited in the embodiment of the present application specific between above-mentioned communication interface 302, processor 301 and memory 303
Connect medium.The embodiment of the present application in Fig. 7 to pass through bus between memory 303, processor 301 and communication interface 302
Connection, bus indicate that the connection type between other components is only to be schematically illustrated, does not regard it as in Fig. 7 with thick line
It is limited.Bus can be divided into address bus, data/address bus, control bus etc..For convenient for indicating, only with a thick line table in Fig. 7
Show, it is not intended that an only bus or a type of bus.
The embodiment of the invention also provides a kind of computer readable storage mediums, execute above-mentioned processor institute for being stored as
The computer software instructions that need to be executed, it includes the programs for execution needed for executing above-mentioned processor.
It should be understood by those skilled in the art that, embodiments herein can provide as method, system or computer program
Product.Therefore, complete hardware embodiment, complete software embodiment or reality combining software and hardware aspects can be used in the application
Apply the form of example.Moreover, it wherein includes the computer of computer usable program code that the application, which can be used in one or more,
The computer program implemented in usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) produces
The form of product.
The application be referring to according to the present processes, equipment (system) and computer program product flow chart and/or
Block diagram describes.It should be understood that each process that can be realized by computer program instructions in flowchart and/or the block diagram and/or
The combination of process and/or box in box and flowchart and/or the block diagram.It can provide these computer program instructions to arrive
General purpose computer, special purpose computer, Embedded Processor or other programmable data processing devices processor to generate one
Machine, so that being generated by the instruction that computer or the processor of other programmable data processing devices execute for realizing flowing
The device for the function of being specified in journey figure one process or multiple processes and/or block diagrams one box or multiple boxes.
These computer program instructions, which may also be stored in, is able to guide computer or other programmable data processing devices with spy
Determine in the computer-readable memory that mode works, so that it includes referring to that instruction stored in the computer readable memory, which generates,
Enable the manufacture of device, the command device realize in one box of one or more flows of the flowchart and/or block diagram or
The function of being specified in multiple boxes.
These computer program instructions also can be loaded onto a computer or other programmable data processing device, so that counting
Series of operation steps are executed on calculation machine or other programmable devices to generate computer implemented processing, thus in computer or
The instruction executed on other programmable devices is provided for realizing in one or more flows of the flowchart and/or block diagram one
The step of function of being specified in a box or multiple boxes.
Obviously, those skilled in the art can carry out various modification and variations without departing from the essence of the application to the application
Mind and range.In this way, if these modifications and variations of the application belong to the range of the claim of this application and its equivalent technologies
Within, then the application is also intended to include these modifications and variations.
Claims (12)
1. a kind of method for managing file system, which is characterized in that including:
When not carrying out consistency check to corresponding first file system of the first data subregion, the first file system described in carry
System;
When reading file destination by first file system, whether just the first check value of the file destination is judged
Really;
If first check value of the file destination is incorrect, described the is repaired by file system check Fsck tool
One file system.
2. the method according to claim 1, wherein further including:
When the first check value of the file destination is incorrect, a reading mode or unloading are set by first file system
First file system.
3. according to the method described in claim 2, it is characterized in that, repairing first file system by the Fsck tool
After system, further include:
If first file system is arranged to a reading mode, readable write state is set by first file system;
Or
If first file system is unloaded, the first file system described in carry.
4. method according to any one of claims 1 to 3, which is characterized in that in the first school for judging the file destination
Test value it is whether correct after, further include:
If first check value of the file destination is correct, the file destination is read by first file system
And the file destination is sent to the application of the request file destination;
Judge whether the second check value of the file destination is correct by the application, second check value and described first
Check value is different;
If second check value of the file destination is incorrect, from the of the Backup Data for being stored with the file destination
The data of the file destination are obtained in corresponding second file system of two data subregions;
According to the data of file destination described in second file system to file destination described in first file system
Data restored.
5. according to the method described in claim 4, it is characterized in that, the first data subregion and the second data zone bit
In on different servers.
6. a kind of device for managing file system, which is characterized in that including:
Carry module is used for when not carrying out consistency check to corresponding first file system of the first data subregion, carry institute
State the first file system;
Judgment module, for judging the first of the file destination when reading file destination by first file system
Whether check value is correct;
Repair module, for passing through file system check Fsck when first check value of the file destination is incorrect
Tool repairs first file system.
7. device according to claim 6, which is characterized in that further include:
Configuration module, for setting first file system to when the first check value of the file destination is incorrect
Reading mode or unloading first file system.
8. device according to claim 7, which is characterized in that the configuration module is also used to:It is logical in the repair module
It crosses after the Fsck tool reparation first file system, if first file system is arranged to a reading mode,
Readable write state is set by first file system;Alternatively, if first file system is unloaded, described in carry
One file system.
9. according to the described in any item devices of claim 6 to 8, which is characterized in that further include:
Sending module, after first check value for judging the file destination in the judgment module is correct, then
The file destination is read by first file system and sends the target text to the application of the request file destination
Part;
Second judgment module, for judging whether the second check value of the file destination is correct by the application, described
Two check values are different from first check value;
Second repair module, for when second check value of the file destination is incorrect, from being stored with the target
The data of the file destination are obtained in corresponding second file system of the second data subregion of the Backup Data of file;According to institute
The data for stating file destination described in the second file system carry out the data of file destination described in first file system
Restore.
10. device according to claim 9, which is characterized in that the first data subregion and the second data subregion
On different servers.
11. a kind of device for managing file system, which is characterized in that including:
Memory is stored with computer instruction;
Processor is connected with the memory, for calling the computer instruction stored in the memory, to execute such as right
It is required that the method for 1 to 5 described in any item management file system.
12. a kind of computer readable storage medium, which is characterized in that it is stored with computer instruction in the readable storage medium storing program for executing,
When described instruction is run on computers, so that computer executes such as management file system described in any one of claim 1 to 5
Method.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710375466.3A CN108932249B (en) | 2017-05-24 | 2017-05-24 | Method and device for managing file system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201710375466.3A CN108932249B (en) | 2017-05-24 | 2017-05-24 | Method and device for managing file system |
Publications (2)
Publication Number | Publication Date |
---|---|
CN108932249A true CN108932249A (en) | 2018-12-04 |
CN108932249B CN108932249B (en) | 2021-02-12 |
Family
ID=64451400
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201710375466.3A Active CN108932249B (en) | 2017-05-24 | 2017-05-24 | Method and device for managing file system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN108932249B (en) |
Cited By (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110059056A (en) * | 2019-04-18 | 2019-07-26 | 北京思特奇信息技术股份有限公司 | The distributed system read/writable detection method of multinode multifile, device, equipment |
CN110532032A (en) * | 2019-07-31 | 2019-12-03 | 华为技术有限公司 | A kind of booting file system detection method and relevant device |
CN111177085A (en) * | 2019-12-27 | 2020-05-19 | 浪潮(北京)电子信息产业有限公司 | Method, device and medium for verifying data consistency function of file system |
CN112783444A (en) * | 2021-01-18 | 2021-05-11 | 深圳市科思科技股份有限公司 | Cluster disk sharing method, system and storage medium |
CN112817911A (en) * | 2021-02-09 | 2021-05-18 | 海信视像科技股份有限公司 | File system repairing method and terminal equipment |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US11875062B1 (en) | 2022-06-23 | 2024-01-16 | Western Digital Technologies, Inc. | Proactive hardening of data storage system |
Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050038803A1 (en) * | 2002-03-22 | 2005-02-17 | Edwards John K. | System and method performing an on-line check of a file system |
CN101025770A (en) * | 2006-02-20 | 2007-08-29 | 联想(北京)有限公司 | Method for starting protected partition |
CN101038556A (en) * | 2007-04-30 | 2007-09-19 | 中国科学院软件研究所 | Trusted bootstrap method and system thereof |
CN101567805A (en) * | 2009-05-22 | 2009-10-28 | 清华大学 | Method for recovering failed parallel file system |
US7765187B2 (en) * | 2005-11-29 | 2010-07-27 | Emc Corporation | Replication of a consistency group of data storage objects from servers in a data network |
CN101883028A (en) * | 2010-06-30 | 2010-11-10 | 中兴通讯股份有限公司 | Method and device for detecting network file system server |
CN102932621A (en) * | 2011-08-08 | 2013-02-13 | 杭州海康威视数字技术股份有限公司 | Method and device for storing data |
CN103164342A (en) * | 2011-12-12 | 2013-06-19 | 苹果公司 | Mount-time reconciliation of data availability |
CN103164523A (en) * | 2013-03-19 | 2013-06-19 | 华为技术有限公司 | Inspection method, device and system of data consistency inspection |
CN106227839A (en) * | 2016-07-26 | 2016-12-14 | 浪潮电子信息产业股份有限公司 | The expansion method of a kind of lustre file system and device |
-
2017
- 2017-05-24 CN CN201710375466.3A patent/CN108932249B/en active Active
Patent Citations (10)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20050038803A1 (en) * | 2002-03-22 | 2005-02-17 | Edwards John K. | System and method performing an on-line check of a file system |
US7765187B2 (en) * | 2005-11-29 | 2010-07-27 | Emc Corporation | Replication of a consistency group of data storage objects from servers in a data network |
CN101025770A (en) * | 2006-02-20 | 2007-08-29 | 联想(北京)有限公司 | Method for starting protected partition |
CN101038556A (en) * | 2007-04-30 | 2007-09-19 | 中国科学院软件研究所 | Trusted bootstrap method and system thereof |
CN101567805A (en) * | 2009-05-22 | 2009-10-28 | 清华大学 | Method for recovering failed parallel file system |
CN101883028A (en) * | 2010-06-30 | 2010-11-10 | 中兴通讯股份有限公司 | Method and device for detecting network file system server |
CN102932621A (en) * | 2011-08-08 | 2013-02-13 | 杭州海康威视数字技术股份有限公司 | Method and device for storing data |
CN103164342A (en) * | 2011-12-12 | 2013-06-19 | 苹果公司 | Mount-time reconciliation of data availability |
CN103164523A (en) * | 2013-03-19 | 2013-06-19 | 华为技术有限公司 | Inspection method, device and system of data consistency inspection |
CN106227839A (en) * | 2016-07-26 | 2016-12-14 | 浪潮电子信息产业股份有限公司 | The expansion method of a kind of lustre file system and device |
Non-Patent Citations (1)
Title |
---|
ORACLE CORPORATION: "第20章 使用CacheFS文件***(任务)", 《***管理指南:设备和文件***(URL:HTTPS://DOCS.ORACLE.COM/CD/E19253-01/819-7062/FSCACHEFS-24/INDEX.HTML)》 * |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110059056A (en) * | 2019-04-18 | 2019-07-26 | 北京思特奇信息技术股份有限公司 | The distributed system read/writable detection method of multinode multifile, device, equipment |
CN110532032A (en) * | 2019-07-31 | 2019-12-03 | 华为技术有限公司 | A kind of booting file system detection method and relevant device |
CN111177085A (en) * | 2019-12-27 | 2020-05-19 | 浪潮(北京)电子信息产业有限公司 | Method, device and medium for verifying data consistency function of file system |
CN112783444A (en) * | 2021-01-18 | 2021-05-11 | 深圳市科思科技股份有限公司 | Cluster disk sharing method, system and storage medium |
CN112817911A (en) * | 2021-02-09 | 2021-05-18 | 海信视像科技股份有限公司 | File system repairing method and terminal equipment |
CN112817911B (en) * | 2021-02-09 | 2023-07-11 | 海信视像科技股份有限公司 | File system repairing method and terminal equipment |
Also Published As
Publication number | Publication date |
---|---|
CN108932249B (en) | 2021-02-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN108932249A (en) | A kind of method and device managing file system | |
US11757795B2 (en) | Resolving mediator unavailability | |
US11698844B2 (en) | Managing storage systems that are synchronously replicating a dataset | |
US11204701B2 (en) | Token based transactions | |
US10394634B2 (en) | Drive-based storage scrubbing | |
US10620864B1 (en) | Improving the accuracy of in-line data deduplication | |
US11099953B2 (en) | Automatic data healing using a storage controller | |
US11869583B2 (en) | Page write requirements for differing types of flash memory | |
JP2016512365A (en) | Synchronous mirroring in non-volatile memory systems | |
CN108733311B (en) | Method and apparatus for managing storage system | |
US11582046B2 (en) | Storage system communication | |
CN110178121A (en) | A kind of detection method and its terminal of database | |
CN107479823A (en) | Data verification method and device in the test of random read-write file | |
US20230004464A1 (en) | Snapshot commitment in a distributed system | |
US10719265B1 (en) | Centralized, quorum-aware handling of device reservation requests in a storage system | |
US11226746B2 (en) | Automatic data healing by I/O | |
CN116244127A (en) | Hard disk detection method, device, equipment and storage medium | |
WO2018076954A1 (en) | Data storage method, apparatus and system | |
CN114415979B (en) | Storage device processing method, computer equipment and storage device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant | ||
TR01 | Transfer of patent right |
Effective date of registration: 20220211 Address after: 550025 Huawei cloud data center, jiaoxinggong Road, Qianzhong Avenue, Gui'an New District, Guiyang City, Guizhou Province Patentee after: Huawei Cloud Computing Technologies Co.,Ltd. Address before: 518129 Bantian HUAWEI headquarters office building, Longgang District, Guangdong, Shenzhen Patentee before: HUAWEI TECHNOLOGIES Co.,Ltd. |
|
TR01 | Transfer of patent right |