CN108646987A - A kind of management method of file volume, device, storage medium and terminal - Google Patents

A kind of management method of file volume, device, storage medium and terminal Download PDF

Info

Publication number
CN108646987A
CN108646987A CN201810489298.5A CN201810489298A CN108646987A CN 108646987 A CN108646987 A CN 108646987A CN 201810489298 A CN201810489298 A CN 201810489298A CN 108646987 A CN108646987 A CN 108646987A
Authority
CN
China
Prior art keywords
file
volume
stored
time
expired time
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
CN201810489298.5A
Other languages
Chinese (zh)
Other versions
CN108646987B (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.)
Beijing 58 Information Technology Co Ltd
Original Assignee
Beijing 58 Information Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing 58 Information Technology Co Ltd filed Critical Beijing 58 Information Technology Co Ltd
Priority to CN201810489298.5A priority Critical patent/CN108646987B/en
Publication of CN108646987A publication Critical patent/CN108646987A/en
Application granted granted Critical
Publication of CN108646987B publication Critical patent/CN108646987B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0602Interfaces specially adapted for storage systems specifically adapted to achieve a particular effect
    • G06F3/0604Improving or facilitating administration, e.g. storage management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0638Organizing or formatting or addressing of data
    • G06F3/064Management of blocks
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/06Digital input from, or digital output to, record carriers, e.g. RAID, emulated record carriers or networked record carriers
    • G06F3/0601Interfaces specially adapted for storage systems
    • G06F3/0628Interfaces specially adapted for storage systems making use of a particular technique
    • G06F3/0646Horizontal data movement in storage systems, i.e. moving data in between storage devices or systems
    • G06F3/0652Erasing, e.g. deleting, data cleaning, moving of data to a wastebasket

Abstract

The invention discloses a kind of management method of file volume, device, storage medium and terminal, this method to include:The type of multiple file volumes is set, and determines the corresponding expired time of file volume of each type, wherein the expired time of files in different types volume is different;When storage file, file to be stored is stored into the file volume of corresponding types according to the expired time of file to be stored;According to the expired time of file volume, file volume is deleted.The present invention is provided with the type of multiple file volumes, and according to the different expired time of file to be stored, it is stored into the file volume of corresponding types, when needing to delete file, it only needs according to the expired time of corresponding types file volume, so that it may which, to carry out the whole deletion of this document volume, the expired time that all storage files need not be traversed in file volume such as is shifted, deleted at the operations again, the read-write number for greatly reducing disk improves the usage experience of efficiency and user that management is deleted.

Description

A kind of management method of file volume, device, storage medium and terminal
Technical field
The present invention relates to field of data storage, more particularly to a kind of management method of file volume, device, storage medium and Terminal.
Background technology
Object storage i.e. file storage.General file system is not friendly enough to the storage mode of mass file, because This usual object storage service can all store Piece file mergence file volume.To reduce the quantity of documents on disk, reduce The problems such as disk fragments generate.However store Piece file mergence to file volume, there are problems that the deletion of scratch file.One file Volume may be made of hundreds and thousands of a files, and the expired time of these files is not consistent, it is possible some be it is never expired, Some are expired for a long time.
Scratch file way to manage in the prior art is as follows:Using periodically or deletion program is manually booted, successively time Entire file volume is gone through, the expired time of wherein each file is taken out, not out of date file is moved to a new text Among part volume, after waiting for that entire file volume traversal is completed, all not out of date files have been moved among new file volume, then Delete old file volume.But this mode needs to be traversed for entire file volume, causes a large amount of read-write operation, is only deposited in file volume In small part scratch file, it is still necessary to traverse entire file volume, management is deleted less efficient, and influence user uses body It tests.
Invention content
The present invention provides a kind of management method of file volume, device, storage medium and terminal, to solve the prior art Following problem:The prior art needs to be traversed for entire file volume, causes a large amount of read-write operation, and manage the efficiency mistake for deleting file It is low, influence the usage experience of user.
In order to solve the above technical problems, on the one hand, the present invention provides a kind of management method of file volume, including:Setting is more The type of a file volume, and determine the corresponding expired time of file volume of each type, wherein files in different types is rolled up expired Time is different;When storage file, the file to be stored is stored to corresponding types according to the expired time of file to be stored In file volume;According to the expired time of file volume, the file volume is deleted.
Further, the type of the multiple file volumes of setting, and determine the corresponding expired time of file volume of each type, Including:Multiple periods are set;According to the multiple period, setting and each period one in the multiple period are a pair of The multiple file volume types answered;According to the time upper limit of each period in the multiple period, each time is determined The expired time of the corresponding file volume type of section.
Further, the expired time according to file to be stored stores the file to be stored to the text of corresponding types In part volume, including:Determine the period of the expired time ownership of the file to be stored;According to the expired of the file to be stored The period of time ownership, the file to be stored is stored into the file volume of the period corresponding types.
Further, the expired time according to file volume deletes the file volume, including:Determine the last of file volume Time difference between modification time and current time;In the case where the time difference being more than the expired time of the file volume, Delete the file volume.
On the other hand, the present invention also provides a kind of managing devices of file volume, which is characterized in that including:Setup module is used In the type that multiple file volumes are arranged, and determine the corresponding expired time of file volume of each type, wherein files in different types The expired time of volume is different;Memory module will be described to be stored according to the expired time of file to be stored when being used for storage file File is stored into the file volume of corresponding types;Removing module deletes the file for the expired time according to file volume Volume.
Further, the setup module, is specifically used for:Multiple periods are set;According to the multiple period, setting with Multiple file volume types correspondingly of each period in the multiple period;According to it is each in the multiple period when Between section time upper limit, determine the expired time of corresponding file volume type of each period.
Further, the memory module, is specifically used for:Determine the time of the expired time ownership of the file to be stored Section;According to the period that the expired time of the file to be stored belongs to, the file to be stored was stored to the period In the file volume of corresponding types.
Further, the removing module, is specifically used for:It determines between the last modification time of file volume and current time Time difference;In the case where the time difference being more than the expired time of the file volume, the file volume is deleted.
On the other hand, the present invention also provides a kind of storage medium, it is stored with computer program, which is characterized in that computer The step of management method of above-mentioned file volume is realized when program is executed by processor.
On the other hand, the present invention also provides a kind of terminals, include at least memory, processor, meter is stored on memory The step of calculation machine program, processor realizes the management method of above-mentioned file volume in the computer program on executing memory.
The present invention is provided with the type of multiple file volumes, and according to the different expired time of file to be stored, is stored Into the file volume of corresponding types, when needing to delete file, it is only necessary to according to the expired time of corresponding types file volume, so that it may To carry out the whole deletion of this document volume, the expired time that all storage files need not be traversed in file volume is turned again The operations such as shifting, deletion, greatly reduce the read-write number of disk, improve the usage experience of efficiency and user that management is deleted.
Description of the drawings
Fig. 1 is the management method flow chart of file volume in first embodiment of the invention;
Fig. 2 is the management method flow chart of file volume in second embodiment of the invention;
Fig. 3 is the management method flow chart of file volume in third embodiment of the invention;
Fig. 4 is the management method flow chart of file volume in fourth embodiment of the invention;
Fig. 5 is the managing device structural schematic diagram of file volume in fifth embodiment of the invention.
Specific implementation mode
In order to solve the problems, such as the as follows of the prior art:The prior art needs to be traversed for entire file volume, causes largely to read and write Operation, and the efficiency for managing deletion file is too low, influences the usage experience of user, the present invention provides a kind of management of file volume Method, apparatus, storage medium and terminal, below in conjunction with attached drawing and embodiment, the present invention will be described in further detail.It answers Work as understanding, the specific embodiments described herein are merely illustrative of the present invention, does not limit the present invention.
The first embodiment of the present invention provides a kind of management method of file volume, is applied to object storage system, stream Journey figure is as shown in Figure 1, specifically include step S101 to S103:
S101 is arranged the type of multiple file volumes, and determines the corresponding expired time of file volume of each type, wherein The expired time of files in different types volume is different.
In object storage system, multiple file volumes are set first, and different types is respectively set for multiple file volumes, Different types of file volume is used to store the file to be stored of different expired times, and determines it according to the type of each file volume The expired time of corresponding expired time, different types of file volume is different.
S102 when storage file, stores file to be stored to corresponding types according to the expired time of file to be stored In file volume.
Due to file volume according to type be provided with it is multiple, then, should be according to file to be stored when carrying out file storage Expired time is stored into the file volume of corresponding types.Specifically, the file to be stored with identical expired time can quilt It stores to same file in rolling up, to ensure when being subsequently managed or deleting to file volume, the All Files in file volume It is expired state.
S103 deletes file volume according to the expired time of file volume.
Object storage system is when managing file volume, the different expired times that can be rolled up according to files in different types, to text Part volume carries out delete operation.When the state of file volume meets deletion condition, it was demonstrated that the All Files stored in this document volume are equal Expired time is reached, it is therefore not necessary to carry out traversing operation to each file volume to screen the file for needing to delete, it is only necessary to will be right Expired file volume is answered integrally to delete.
The present embodiment is provided with the type of multiple file volumes, and according to the different expired time of file to be stored, is deposited It puts into the file volume of corresponding types, when needing to delete file, it is only necessary to according to the expired time of corresponding types file volume, just The whole deletion of this document volume can be carried out, the expired time that all storage files need not be traversed in file volume is turned again The operations such as shifting, deletion, greatly reduce the read-write number of disk, improve the usage experience of efficiency and user that management is deleted.
The second embodiment of the present invention provides a kind of management method of file volume, is applied to object storage system, stream Journey figure is as shown in Fig. 2, specifically include step S201 to S205:
Multiple periods are arranged in S201.
S202, according to multiple periods, setting and each period in multiple periods multiple file volumes correspondingly Type.
The expired time of file to be stored is usually to differ for several days to tens days, it is also possible to there are the longer time limit or permanently be had The file of effect.Therefore, in order to which the file to different expired times is stored respectively, when the file volume of multiple types is arranged, Multiple periods can be set first, should be between above-mentioned multiple periods continuously but from each other without the multiple of time intersection Period.Corresponding file volume type is then arranged according to the period, each period, there are one corresponding file volumes The file volume of type, the type falls the file to be stored within the period for storing expired time.
S203 determines corresponding file volume of each period according to the time upper limit of each period in multiple periods The expired time of type.
In order to be managed deletion to file volume, after the file volume that multiple types are set, each type file need to be determined Corresponding expired time is rolled up, to facilitate the expired time subsequently rolled up according to this document to be managed this document volume.Due to each File volume type is corresponding with the period that one sets, and the expired time of the file preserved does not exceed the period Time upper limit therefore should be using the upper limit of each period as the expired time of corresponding types file volume.For example, setting first It sets four periods, respectively 0 to 7 day, 7 to 15,15 to 30 days, 30 to 90 days and 90 days or more, is then correspondingly arranged five The file volume of a type, first kind file volume are used to store the file that expired time was less than or equal to 7 more than 0 day, the first kind The expired time of type file volume is 7;Second Type file volume is used to store the text that expired time was less than or equal to 15 more than 7 days The expired time of part, Second Type file volume is 15;Third type file volume was less than for storing expired time more than 15 days The expired time of file equal to 30 days, third type file volume is 30;4th type file is rolled up for storing expired time It was less than or equal to file on the 90th more than 30 days, the expired time of the 4th type file volume is 90;5th type file volume is used for The file that expired time is more than 90 is stored, the 5th type file volume is not provided with expired time.It will be appreciated that in setting text During the type of part volume, it should include that a time upper limit is rolled up for just infinite file volume, such as the 5th type file always, use In the All Files that storage expired time is more than 90 the type file volume is also just not provided with since it does not have time upper limit Expired time.
It will be appreciated that the division methods of above-mentioned period and file volume type are not limited to the above timing node, in reality Border using when can be flexibly set according to the expired time and quantity of file to be stored.
S204 when storage file, stores file to be stored to corresponding types according to the expired time of file to be stored In file volume.
Due to file volume according to type be provided with it is multiple, then, should be according to file to be stored when carrying out file storage Expired time is stored into the file volume of corresponding types.Specifically, the file to be stored with identical expired time can quilt It stores to same file in rolling up, to ensure when being subsequently managed or deleting to file volume, the All Files in file volume It is expired state.
S205 deletes file volume according to the expired time of file volume.
Object storage system is when managing file volume, the different expired times that can be rolled up according to files in different types, to text Part volume carries out delete operation.When the state of file volume meets deletion condition, it was demonstrated that the All Files stored in this document volume are equal Expired time is reached, it is therefore not necessary to carry out traversing operation to each file volume to screen the file for needing to delete, it is only necessary to will be right Expired file volume is answered integrally to delete.
The present embodiment is provided with the type of multiple file volumes, and according to the different expired time of file to be stored, is deposited It puts into the file volume of corresponding types, when needing to delete file, it is only necessary to according to the expired time of corresponding types file volume, just The whole deletion of this document volume can be carried out, the expired time that all storage files need not be traversed in file volume is turned again The operations such as shifting, deletion, greatly reduce the read-write number of disk, improve the usage experience of efficiency and user that management is deleted.
The third embodiment of the present invention provides a kind of management method of file volume, is applied to object storage system, stream Journey figure is as shown in figure 3, specifically include step S301 to S306:
Multiple periods are arranged in S301.
S302, according to multiple periods, setting and each period in multiple periods multiple file volumes correspondingly Type.
The expired time of file to be stored is usually to differ for several days to tens days, it is also possible to there are the longer time limit or permanently be had The file of effect.Therefore, in order to which the file to different expired times is stored respectively, when the file volume of multiple types is arranged, Multiple periods can be set first, should be between above-mentioned multiple periods continuously but from each other without the multiple of time intersection Period.Corresponding file volume type is then arranged according to the period, each period, there are one corresponding file volumes The file volume of type, the type falls the file to be stored within the period for storing expired time.
S303 determines corresponding file volume of each period according to the time upper limit of each period in multiple periods The expired time of type.
In order to be managed deletion to file volume, after the file volume that multiple types are set, each type file need to be determined Corresponding expired time is rolled up, to facilitate the expired time subsequently rolled up according to this document to be managed this document volume.Due to each File volume type is corresponding with the period that one sets, and the expired time of the file preserved does not exceed the period Time upper limit therefore should be using the upper limit of each period as the expired time of corresponding types file volume.
S304 determines the period of the expired time ownership of file to be stored.
S305 stores file to be stored to the period pair according to the period that the expired time of file to be stored belongs to In the file volume for answering type.
When carrying out file storage, the expired time of file to be stored is obtained first, and according to the expired of file to be stored Time determines the period that file to be stored should belong to, then stores file to be stored in conjunction with the pre-set period Into the file volume of the period corresponding types.Such as, the expired time of file to be stored A is 20 days, the time that should belong to Section is 15 to 30, i.e., should be stored in third type file volume.
S306 deletes file volume according to the expired time of file volume.
Object storage system is when managing file volume, the different expired times that can be rolled up according to files in different types, to text Part volume carries out delete operation.When the state of file volume meets deletion condition, it was demonstrated that the All Files stored in this document volume are equal Expired time is reached, it is therefore not necessary to carry out traversing operation to each file volume to screen the file for needing to delete, it is only necessary to will be right Expired file volume is answered integrally to delete.
File to be stored is carried out classification storage by the present embodiment according to expired time, when expired time is belonged to same Between file in section store into the file volume of the same type, ensure when the expired time of file volume reaches, it is internal to protect The All Files deposited are expired state, and then same deletion management may be implemented, and reduce the read-write number of disk, are improved The usage experience for the efficiency and user that management is deleted.
The fourth embodiment of the present invention provides a kind of management method of file volume, is applied to object storage system, stream Journey figure is as shown in figure 4, specifically include step S401 to S404:
S401 is arranged the type of multiple file volumes, and determines the corresponding expired time of file volume of each type, wherein The expired time of files in different types volume is different.
In object storage system, multiple file volumes are set first, and different types is respectively set for multiple file volumes, Different types of file volume is used to store the file to be stored of different expired times, and determines it according to the type of each file volume The expired time of corresponding expired time, different types of file volume is different.
S402 when storage file, stores file to be stored to corresponding types according to the expired time of file to be stored In file volume.
Due to file volume according to type be provided with it is multiple, then, should be according to file to be stored when carrying out file storage Expired time is stored into the file volume of corresponding types.Specifically, the file to be stored with identical expired time can quilt It stores to same file in rolling up, to ensure when being subsequently managed or deleting to file volume, the All Files in file volume It is expired state.
S403 determines the time difference between the last modification time of file volume and current time.
S404 deletes file volume in the case where the time difference being more than the expired time of file volume.
In the present embodiment, continuous storage file during object storage system is rolled up to a certain type file, therefore when its modification Between constantly change, when needing to carry out delete operation, need to first determine whether this document volume last modification time and current time it Between time difference, and judge the time difference whether be more than file volume expired time, the time difference be more than file volume it is expired In the case of time, it was demonstrated that the file of the last one write-in is expired in this document volume, then being deposited into before this document This document volume in alternative document, equally be in expired, can delete at this time this document volume, together with this document roll up in have been subjected to The file of phase is deleted together.For example, current time is on April 18th, 2018, the last modification time of first kind file volume is On April 10th, 2018, then the time difference between the last modification time and current time of first kind file volume is 8 days, The expired time of first kind file volume has been more than it 7 days, the All Files in first kind file volume must be at this time Phase state deletes first kind file volume.
Optionally, for the file volume that expired time is not arranged, such as the 5th type file is rolled up, and the management plan of acquiescence can be used Slightly, that is, the All Files in the 5th type file volume are traversed, and judge whether each file is expired, for having expired file, It can transfer them in another file volume, and after traversing and shifting completion, delete this document volume.Although being directed to the 5th class Type file volume needs to carry out traversing operation, but due to there is the stored file volume to other four types of quite a few file In, the file that expired time is more than 90 is only saved in the 5th type file volume, the quantity of documents of traversal is reduced, and the 5th class The expired time of storage file is all long in type file volume, excessively need not frequently be deleted, therefore, will not be into line frequency Numerous read-write operation, and then influence efficiency.
It will be appreciated that after the file volume for deleting a certain type, to ensure that subsequently belonging to the type file volume protects The file deposited can be preserved normally, it should after the file volume for deleting original type, the file volume an of the type is reset, And the expired time of the file volume of newly-installed the type is identical as original file volume.
The present embodiment carries out the deletion of file volume by the last modification time of file volume and the expired time of file volume, and And with the deletion of file volume, while file all in this document volume is deleted, the file in file volume need not be carried out The operations such as traversal, transfer, reduce the read-write number of disk, improve the usage experience of efficiency and user that management is deleted.
The fifth embodiment of the present invention provides a kind of managing device of file volume, is arranged in object storage system, the dress The structural representation set is as shown in figure 5, include:
Setup module 10, the type for multiple file volumes to be arranged, and determine that the file volume of each type is corresponding expired Time, wherein the expired time of files in different types volume is different;Memory module 20 is coupled with setup module 10, for storing text When part, file to be stored is stored into the file volume of corresponding types according to the expired time of file to be stored;Removing module 30, It is coupled with memory module 20, for the expired time according to file volume, deletes file volume.
In object storage system, multiple file volumes are arranged by setup module 10 first, and set respectively for multiple file volumes Different types is set, different types of file volume is used to store the file to be stored of different expired times, and according to each file The type of volume determines that its corresponding expired time, the expired time of different types of file volume are different.
Specifically, since the expired time of file to be stored is usually to differ for several days to tens days, it is also possible to which there are longer Time limit or permanent effective file, therefore, multiple periods can be arranged when multiple file volumes are arranged in setup module 10 first, It is should be between above-mentioned multiple periods continuously but from each other without multiple periods of time intersection;Subsequent setup module 10 Corresponding file volume type is set according to the period, each period, there are one corresponding file volume type, the type File volume fall the file to be stored within the period for storing expired time;In order to be managed deletion to file volume, Setup module 10 need to determine that each type file rolls up corresponding expired time, with convenient after the file volume that multiple types are arranged Subsequently this document volume is managed according to the expired time of this document volume.Since the type of each file volume is arranged with one The good period corresponds to, and the expired time of the file preserved does not exceed the time upper limit of the period, therefore, should will be every Expired time of the upper limit of a period as corresponding types file volume was not provided with the period of not time upper limit Time phase.
Due to file volume according to type be provided with it is multiple, then when carrying out file storage, memory module 20 is according to be stored The expired time of file is stored into the file volume of corresponding types.Specifically, memory module 20 obtains text to be stored first The expired time of part, and according to the expired time of file to be stored, in conjunction with the pre-set period, determine that file to be stored is answered The period of the ownership then stores file to be stored into the file volume of the period corresponding types, has identical expired The file to be stored of time can be stored in same file volume, to ensure subsequently be managed file volume or deleting When, the All Files in file volume are expired state.
Removing module 30 is when managing file volume, the different expired times that can be rolled up according to files in different types, to file Volume carries out delete operation.When the state of file volume meets deletion condition, it was demonstrated that the All Files stored in this document volume arrive Up to expired time, it is therefore not necessary to carry out traversing operation to each file volume to screen the file for needing to delete, it is only necessary to will correspond to Expired file volume carries out whole deletion.Specifically, continuous storage file during memory module 20 is rolled up to a certain type file, Therefore its modification time constantly changes, and when needing to carry out delete operation, removing module 30 need to first determine whether the end of this document volume Time difference between secondary modification time and current time, and judge whether the time difference is more than the expired time of file volume, In the case that time difference is more than the expired time of file volume, it was demonstrated that the file of the last one write-in is expired in this document volume, The alternative document being so deposited into before this document in this document volume, has equally been in expired, removing module 30 can at this time This document volume is deleted, is deleted together together with file expired in this document volume.
Optionally, for the file volume that expired time is not arranged, the management strategy of acquiescence can be used, that is, traverse this document volume In All Files, and judge whether each file expired, for having expired file, another file volume can be transferred them to In, and after traversing and shifting completion, delete another file volume.Although for the file volume needs that expired time is not arranged Traversing operation is carried out, but due to there is quite a few file in stored to other kinds of file volume, the number of files of traversal Amount is reduced, and the expired time that storage file in the file volume of expired time is not arranged is all long, need not be excessively frequent It is deleted, therefore, frequent read-write operation will not be carried out, and then influence efficiency.
It will be appreciated that after the file volume for deleting a certain type, to ensure that subsequently belonging to the type file volume protects The file deposited can be preserved normally, it should after the file volume for deleting original type, the file volume an of the type is reset, And the expired time of the file volume of newly-installed the type is identical as original file volume.
The present embodiment is provided with the type of multiple file volumes, and according to the different expired time of file to be stored, is deposited It puts into the file volume of corresponding types, when needing to delete file, it is only necessary to according to the expired time of corresponding types file volume, just The whole deletion of this document volume can be carried out, the expired time that all storage files need not be traversed in file volume is turned again The operations such as shifting, deletion, greatly reduce the read-write number of disk, improve the usage experience of efficiency and user that management is deleted.
Sixth embodiment of the invention provides a kind of storage medium, is stored with computer program, and computer program is handled Following steps S11 to S13 is realized when device executes:
S11 is arranged the type of multiple file volumes, and determines the corresponding expired time of file volume of each type, wherein no The expired time of same type file volume is different;
S12 when storage file, stores file to be stored to the text of corresponding types according to the expired time of file to be stored In part volume;
S13 deletes file volume according to the expired time of file volume.
In the present embodiment, storage medium may be mounted in object storage system.Due in the first embodiment The management method of file volume is described in detail, therefore, is repeated no more in the present embodiment.
Optionally, in the present embodiment, above-mentioned storage medium can include but is not limited to:USB flash disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc or The various media that can store program code such as CD.Optionally, in the present embodiment, processor has been deposited according in storage medium The program code of storage executes the method and step of above-described embodiment record.Optionally, the specific example in the present embodiment can refer to Example described in above-described embodiment and optional embodiment, details are not described herein for the present embodiment.Obviously, the technology of this field Personnel should be understood that each module of the above invention or each step can be realized with general computing device, they can be with It is concentrated on a single computing device, or is distributed on network constituted by multiple computing devices, optionally, they can be used Computing device executable program code is realized, is held by computing device it is thus possible to be stored in storage device Row, and in some cases, can with the steps shown or described are performed in an order that is different from the one herein, or by they point Be not fabricated to each integrated circuit modules, or by them multiple modules or step be fabricated to single integrated circuit module It realizes.In this way, the present invention is not limited to any specific hardware and softwares to combine.
The seventh embodiment of the present invention provides a kind of terminal, includes at least memory, processor, is stored on memory Computer program, processor realize following steps S21 to S23 in the computer program on executing memory:
S21 is arranged the type of multiple file volumes, and determines the corresponding expired time of file volume of each type, wherein no The expired time of same type file volume is different;
S22 when storage file, stores file to be stored to the text of corresponding types according to the expired time of file to be stored In part volume;
S23 deletes file volume according to the expired time of file volume.
In the present embodiment, terminal can be object storage system.Due in the first embodiment to file volume Management method is described in detail, and therefore, repeats no more in the present embodiment.
Although being example purpose, the preferred embodiment of the present invention is had been disclosed for, those skilled in the art will recognize Various improvement, increase and substitution are also possible, and therefore, the scope of the present invention should be not limited to the above embodiments.

Claims (10)

1. a kind of management method of file volume, which is characterized in that including:
The type of multiple file volumes is set, and determines the corresponding expired time of file volume of each type, wherein different type text The expired time of part volume is different;
When storage file, the file to be stored is stored to the file volume of corresponding types according to the expired time of file to be stored In;
According to the expired time of file volume, the file volume is deleted.
2. management method as described in claim 1, which is characterized in that the type of the multiple file volumes of setting, and determine every The corresponding expired time of file volume of a type, including:
Multiple periods are set;
According to the multiple period, setting and each period in the multiple period multiple file volume classes correspondingly Type;
According to the time upper limit of each period in the multiple period, corresponding file volume class of each period is determined The expired time of type.
3. management method as claimed in claim 2, which is characterized in that the expired time according to file to be stored will be described File to be stored is stored into the file volume of corresponding types, including:
Determine the period of the expired time ownership of the file to be stored;
According to the period that the expired time of the file to be stored belongs to, the file to be stored was stored to the period In the file volume of corresponding types.
4. management method as claimed any one in claims 1 to 3, which is characterized in that it is described according to file volume it is expired when Between, the file volume is deleted, including:
Determine the time difference between the last modification time of file volume and current time;
In the case where the time difference being more than the expired time of the file volume, the file volume is deleted.
5. a kind of managing device of file volume, which is characterized in that including:
Setup module, the type for multiple file volumes to be arranged, and determine the corresponding expired time of file volume of each type, In, the expired time of files in different types volume is different;
Memory module stores the file to be stored to right according to the expired time of file to be stored when being used for storage file In the file volume for answering type;
Removing module deletes the file volume for the expired time according to file volume.
6. managing device as claimed in claim 5, which is characterized in that the setup module is specifically used for:
Multiple periods are set;
According to the multiple period, setting and each period in the multiple period multiple file volume classes correspondingly Type;
According to the time upper limit of each period in the multiple period, corresponding file volume class of each period is determined The expired time of type.
7. managing device as claimed in claim 6, which is characterized in that the memory module is specifically used for:
Determine the period of the expired time ownership of the file to be stored;
According to the period that the expired time of the file to be stored belongs to, the file to be stored was stored to the period In the file volume of corresponding types.
8. the managing device as described in any one of claim 5 to 7, which is characterized in that the removing module is specifically used for:
Determine the time difference between the last modification time of file volume and current time;
In the case where the time difference being more than the expired time of the file volume, the file volume is deleted.
9. a kind of storage medium, is stored with computer program, which is characterized in that real when the computer program is executed by processor Described in existing any one of claims 1 to 4 the step of the management method of file volume.
10. a kind of terminal includes at least memory, processor, is stored with computer program on the memory, feature exists In the processor realizes file described in any one of claims 1 to 4 in the computer program on executing the memory The step of management method of volume.
CN201810489298.5A 2018-05-21 2018-05-21 File volume management method and device, storage medium and terminal Active CN108646987B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810489298.5A CN108646987B (en) 2018-05-21 2018-05-21 File volume management method and device, storage medium and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810489298.5A CN108646987B (en) 2018-05-21 2018-05-21 File volume management method and device, storage medium and terminal

Publications (2)

Publication Number Publication Date
CN108646987A true CN108646987A (en) 2018-10-12
CN108646987B CN108646987B (en) 2022-05-31

Family

ID=63757179

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810489298.5A Active CN108646987B (en) 2018-05-21 2018-05-21 File volume management method and device, storage medium and terminal

Country Status (1)

Country Link
CN (1) CN108646987B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110069457A (en) * 2019-04-24 2019-07-30 苏州浪潮智能科技有限公司 One kind is based on scratch file delet method and system in distributed file storage system
CN112214503A (en) * 2020-10-10 2021-01-12 深圳壹账通智能科技有限公司 Data processing method and device, electronic equipment and storage medium
WO2023123802A1 (en) * 2021-12-30 2023-07-06 上海川源信息科技有限公司 Implementation method for file life cycle management of object storage

Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060026220A1 (en) * 2003-02-26 2006-02-02 Permabit, Inc. History preservation in a computer storage system
US20120191736A1 (en) * 2011-01-20 2012-07-26 Fuji Xerox Co., Ltd. File management apparatus, file management method, and computer readable medium storing program
US20130132447A1 (en) * 2011-11-22 2013-05-23 Canon Kabushiki Kaisha Document management apparatus improved in efficiency of deletion of files, method of controlling the same, and storage medium
US20130290248A1 (en) * 2012-04-25 2013-10-31 Hitachi, Ltd. File storage system and file cloning method
CN105893152A (en) * 2016-03-31 2016-08-24 广东欧珀移动通信有限公司 Memory management method and device and mobile terminal
CN106250386A (en) * 2016-07-08 2016-12-21 乐视控股(北京)有限公司 The method and apparatus deleting object in object storage
CN107016099A (en) * 2017-04-10 2017-08-04 国家电网公司 The folder space monitoring maintenance system and method for class Unix system server
CN107451248A (en) * 2017-07-28 2017-12-08 福建中金在线信息科技有限公司 A kind of date storage method, device and electronic equipment
CN107766463A (en) * 2017-09-28 2018-03-06 北京北信源软件股份有限公司 A kind of storage processing method and device of the middleware system of multi-service driving
CN107832470A (en) * 2017-11-29 2018-03-23 郑州云海信息技术有限公司 A kind of object storage method and device based on storage system

Patent Citations (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20060026220A1 (en) * 2003-02-26 2006-02-02 Permabit, Inc. History preservation in a computer storage system
US20120191736A1 (en) * 2011-01-20 2012-07-26 Fuji Xerox Co., Ltd. File management apparatus, file management method, and computer readable medium storing program
US20130132447A1 (en) * 2011-11-22 2013-05-23 Canon Kabushiki Kaisha Document management apparatus improved in efficiency of deletion of files, method of controlling the same, and storage medium
US20130290248A1 (en) * 2012-04-25 2013-10-31 Hitachi, Ltd. File storage system and file cloning method
CN105893152A (en) * 2016-03-31 2016-08-24 广东欧珀移动通信有限公司 Memory management method and device and mobile terminal
CN106250386A (en) * 2016-07-08 2016-12-21 乐视控股(北京)有限公司 The method and apparatus deleting object in object storage
CN107016099A (en) * 2017-04-10 2017-08-04 国家电网公司 The folder space monitoring maintenance system and method for class Unix system server
CN107451248A (en) * 2017-07-28 2017-12-08 福建中金在线信息科技有限公司 A kind of date storage method, device and electronic equipment
CN107766463A (en) * 2017-09-28 2018-03-06 北京北信源软件股份有限公司 A kind of storage processing method and device of the middleware system of multi-service driving
CN107832470A (en) * 2017-11-29 2018-03-23 郑州云海信息技术有限公司 A kind of object storage method and device based on storage system

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110069457A (en) * 2019-04-24 2019-07-30 苏州浪潮智能科技有限公司 One kind is based on scratch file delet method and system in distributed file storage system
CN112214503A (en) * 2020-10-10 2021-01-12 深圳壹账通智能科技有限公司 Data processing method and device, electronic equipment and storage medium
WO2023123802A1 (en) * 2021-12-30 2023-07-06 上海川源信息科技有限公司 Implementation method for file life cycle management of object storage

Also Published As

Publication number Publication date
CN108646987B (en) 2022-05-31

Similar Documents

Publication Publication Date Title
CN102177505B (en) Method for optimizing cleaning of maps in flashcopy cascades containing incremental maps
CN103136243B (en) File system duplicate removal method based on cloud storage and device
CN109428913B (en) Storage capacity expansion method and device
CN101542447B (en) Write once recording device
CN109240607B (en) File reading method and device
CN103092687B (en) A kind of application program management apparatus and method
CN108646987A (en) A kind of management method of file volume, device, storage medium and terminal
CN104778222A (en) Media library establishing and updating method on basis of USB (Universal Serial Bus) storage equipment
CN102750317A (en) Method and device for data persistence processing and data base system
CN106933836A (en) A kind of date storage method and system based on point table
CN103473298A (en) Data archiving method and device and storage system
CN107608860A (en) A kind of method, apparatus, the equipment of error log classification storage
CN109391647A (en) Storage resource recovery method, apparatus and system
CN110147203A (en) A kind of file management method, device, electronic equipment and storage medium
CN110209341B (en) Data writing method and device and storage equipment
CN109408416B (en) Address mapping table entry page management method and device
CN103677660B (en) Information processing apparatus and area release control method
CN106570005A (en) Database cleaning method and device
CN105528302B (en) A kind of method and system of the dynamic hyperdisk of logic-based volume
CN105045542B (en) A kind of method and device for realizing snapshot management
CN102143440A (en) Method and device for processing short message service
CN108205559A (en) A kind of data managing method and its equipment
CN106873906A (en) Method and apparatus for managing metamessage
CN112596949B (en) High-efficiency SSD (solid State disk) deleted data recovery method and system
CN114237489B (en) Method and device for writing logic resources into SMR disk, electronic equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant