CN106202350A - A kind of distributed file system simplifies the method and system of configuration automatically - Google Patents

A kind of distributed file system simplifies the method and system of configuration automatically Download PDF

Info

Publication number
CN106202350A
CN106202350A CN201610525147.1A CN201610525147A CN106202350A CN 106202350 A CN106202350 A CN 106202350A CN 201610525147 A CN201610525147 A CN 201610525147A CN 106202350 A CN106202350 A CN 106202350A
Authority
CN
China
Prior art keywords
space
catalogue
space size
file system
size
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201610525147.1A
Other languages
Chinese (zh)
Inventor
张延良
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Inspur Beijing Electronic Information Industry Co Ltd
Original Assignee
Inspur Beijing Electronic Information Industry 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 Inspur Beijing Electronic Information Industry Co Ltd filed Critical Inspur Beijing Electronic Information Industry Co Ltd
Priority to CN201610525147.1A priority Critical patent/CN106202350A/en
Publication of CN106202350A publication Critical patent/CN106202350A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/11File system administration, e.g. details of archiving or snapshots
    • G06F16/122File system administration, e.g. details of archiving or snapshots using management policies
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/18File system types
    • G06F16/182Distributed file systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

This application discloses a kind of distributed file system and automatically simplify the method and system of configuration, the method includes: be first catalogue distribution the first use space;Store the gross space size of described first catalogue, use space size and remaining space size;When using write data in space to described first, update the space size of use and the remaining space size of described first catalogue;It is second catalogue distribution the second use space, wherein, determines the gross space size of described second catalogue according to the remaining space size of described first catalogue.The above-mentioned distributed file system that the application provides simplifies the method and system of configuration automatically, distributed file system can be simplified automatically configuration, directory capacity is carried out distribution and the management of intelligent and high-efficiency, provides jumbo virtual memory space by less physical capacity for file system.

Description

一种分布式文件系统自动精简配置的方法及系统Method and system for automatic thin provisioning of distributed file system

技术领域technical field

本发明属于分布式文件系统高级功能特性技术领域,特别是涉及一种分布式文件系统自动精简配置的方法及系统。The invention belongs to the technical field of advanced functional characteristics of a distributed file system, and in particular relates to a method and system for automatic thin provisioning of a distributed file system.

背景技术Background technique

在分布式文件系统应用中,已经实现了底层存储池层次的自动精简配置功能。客户一般采用文件系统客户端挂载或NAS标准协议方式访问文件系统,这样,客户首先接触的是文件系统挂载目录或共享目录,然后在这些目录下进行IO操作。在实际应用中,是将不同的目录分配给不同用户,以充分、高效的使用文件系统,然而,当用户在访问自己的授权目录时,查看到的系统空间为整个文件系统的总空间和可用空间,并不能显示被分配到的授权目录的总空间和可用空间。考虑到实际情况,客户的有些部门对文件系统的使用量较小却分了很多空间,有些部门需要分配更大的空间却被分配了较小的空间,这就需要统筹安排每个部门可使用量。In distributed file system applications, the automatic thin provisioning function at the bottom storage pool level has been realized. Customers generally use the file system client mount or NAS standard protocol to access the file system. In this way, the customer first contacts the file system mounted directory or shared directory, and then performs IO operations in these directories. In practical applications, different directories are allocated to different users to fully and efficiently use the file system. However, when users access their own authorized directories, the system space viewed is the total space and available space of the entire file system. Space, does not display the total space and available space of the authorized directory to which it is allocated. Considering the actual situation, some departments of the customer use a small amount of file system but allocate a lot of space, and some departments need to allocate a larger space but are allocated a smaller space, which requires an overall arrangement for each department to use quantity.

发明内容Contents of the invention

为解决上述问题,本发明提供了一种分布式文件系统自动精简配置的方法及系统,能够对分布式文件系统进行自动精简配置,对目录容量进行智能高效的分配和管理,用较小的物理容量为文件系统提供大容量的虚拟存储空间。In order to solve the above problems, the present invention provides a method and system for automatic thin provisioning of a distributed file system, which can perform automatic thin provisioning on a distributed file system, intelligently and efficiently allocate and manage directory capacity, and use a smaller physical Capacity provides large-capacity virtual storage space for the file system.

本发明提供的一种分布式文件系统自动精简配置的方法,包括:A method for automatic thin provisioning of a distributed file system provided by the present invention includes:

为第一目录分配第一使用空间;Allocating the first usage space for the first directory;

存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小;storing the total space size, the used space size and the remaining space size of the first directory;

当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小;When writing data into the first used space, updating the used space size and the remaining space size of the first directory;

为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小。Allocating a second used space for the second directory, wherein the total space of the second directory is determined according to the remaining space of the first directory.

优选的,在上述分布式文件系统自动精简配置的方法中,在为第一目录分配第一使用空间之后,还包括:显示所述第一目录的总空间大小、已使用空间大小和剩余空间大小;在为第二目录分配第二使用空间之后,还包括:显示所述第二目录的总空间大小、已使用空间大小和剩余空间大小。Preferably, in the above method for automatic thin provisioning of a distributed file system, after allocating the first used space for the first directory, it further includes: displaying the total space size, the used space size and the remaining space size of the first directory ; After allocating the second used space for the second directory, the method further includes: displaying the total space size, the used space size and the remaining space size of the second directory.

优选的,在上述分布式文件系统自动精简配置的方法中,在为第二目录分配第二使用空间之后还包括:存储所述第二目录的总空间大小、已使用空间大小和剩余空间大小,其中,所述第二目录的总空间大小和所述第一目录的总空间大小之和大于所述分布式文件系统的总空间大小。Preferably, in the method for automatic thin provisioning of the distributed file system, after allocating the second used space for the second directory, it further includes: storing the total space size, the used space size and the remaining space size of the second directory, Wherein, the sum of the total space size of the second directory and the total space size of the first directory is greater than the total space size of the distributed file system.

优选的,在上述分布式文件系统自动精简配置的方法中,当所述第一目录或第二目录的已使用空间大小等于对应的总空间大小时,扩充所述第一目录或所述第二目录的总空间大小。Preferably, in the method for automatic thin provisioning of the distributed file system, when the used space size of the first directory or the second directory is equal to the corresponding total space size, the first directory or the second directory is expanded The total space size of the directory.

优选的,在上述分布式文件系统自动精简配置的方法中,当所述第一目录的已使用空间大小和所述第二目录的已使用空间大小之和等于所述文件系统的总空间大小时,扩充所述分布式文件系统的容量。Preferably, in the method for automatic thin provisioning of the distributed file system, when the sum of the used space size of the first directory and the used space size of the second directory is equal to the total space size of the file system , expanding the capacity of the distributed file system.

本发明提供的一种分布式文件系统自动精简配置的系统,包括:A distributed file system automatic thin provisioning system provided by the present invention includes:

第一分配单元,用于为第一目录分配第一使用空间;a first allocation unit, configured to allocate a first used space for the first directory;

第一存储单元,用于存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小;The first storage unit is used to store the total space size, the used space size and the remaining space size of the first directory;

更新单元,用于当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小;An update unit, configured to update the used space and remaining space of the first directory when writing data into the first used space;

第二分配单元,用于为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小。The second allocating unit is configured to allocate a second used space for the second directory, wherein the total space of the second directory is determined according to the remaining space of the first directory.

优选的,在上述分布式文件系统自动精简配置的系统中,还包括:Preferably, in the system for automatic thin provisioning of the above-mentioned distributed file system, it also includes:

第一显示单元,用于显示所述第一目录的总空间大小、已使用空间大小和剩余空间大小;a first display unit, configured to display the total space size, the used space size and the remaining space size of the first directory;

第二显示单元,用于显示所述第二目录的总空间大小、已使用空间大小和剩余空间大小。The second display unit is used to display the total space size, the used space size and the remaining space size of the second directory.

优选的,在上述分布式文件系统自动精简配置的系统中,还包括:Preferably, in the system for automatic thin provisioning of the above-mentioned distributed file system, it also includes:

第二存储单元,用于存储所述第二目录的总空间大小、已使用空间大小和剩余空间大小,其中,所述第二目录的总空间大小和所述第一目录的总空间大小之和大于所述分布式文件系统的总空间大小。The second storage unit is used to store the total space size, the used space size and the remaining space size of the second directory, wherein the sum of the total space size of the second directory and the total space size of the first directory Greater than the total space size of the distributed file system.

优选的,在上述分布式文件系统自动精简配置的系统中,还包括:Preferably, in the system for automatic thin provisioning of the above-mentioned distributed file system, it also includes:

第一扩充单元,用于当所述第一目录或第二目录的已使用空间大小等于对应的总空间大小时,扩充所述第一目录或所述第二目录的总空间大小。The first expansion unit is configured to expand the total space of the first directory or the second directory when the used space of the first directory or the second directory is equal to the corresponding total space.

优选的,在上述分布式文件系统自动精简配置的系统中,还包括:Preferably, in the system for automatic thin provisioning of the above-mentioned distributed file system, it also includes:

第二扩充单元,用于当所述第一目录的已使用空间大小和所述第二目录的已使用空间大小之和等于所述文件系统的总空间大小时,扩充所述分布式文件系统的容量。The second expansion unit is configured to expand the distributed file system when the sum of the used space size of the first directory and the used space size of the second directory is equal to the total space size of the file system capacity.

通过上述描述可知,本发明提供分布式文件系统自动精简配置的方法及系统,由于先为第一目录分配第一使用空间,然后存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小,当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小,然后为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小,因此能够对分布式文件系统进行自动精简配置,对目录容量进行智能高效的分配和管理,用较小的物理容量为文件系统提供大容量的虚拟存储空间。It can be seen from the above description that the present invention provides a method and system for automatic thin provisioning of a distributed file system. Since the first used space is first allocated for the first directory, and then the total space size, used space size and remaining space of the first directory are stored Space size, when writing data into the first used space, update the used space size and the remaining space size of the first directory, and then allocate a second used space for the second directory, wherein, according to the first directory The remaining space size of a directory determines the total space size of the second directory, so the distributed file system can be automatically thinned, the directory capacity can be allocated and managed intelligently and efficiently, and the file system can be provided with a smaller physical capacity. Large-capacity virtual storage space.

附图说明Description of drawings

为了更清楚地说明本发明实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据提供的附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings that need to be used in the description of the embodiments or the prior art. Obviously, the accompanying drawings in the following description are only It is an embodiment of the present invention, and those skilled in the art can also obtain other drawings according to the provided drawings without creative work.

图1为本申请实施例提供的第一种分布式文件系统自动精简配置的方法的示意图;FIG. 1 is a schematic diagram of a first distributed file system thin provisioning method provided in an embodiment of the present application;

图2为本申请实施例提供的第一种分布式文件系统自动精简配置的系统的示意图。FIG. 2 is a schematic diagram of a first distributed file system thin provisioning system provided by an embodiment of the present application.

具体实施方式detailed description

分布式文件系统可分为元数据、数据和客户端三大模块,一般数据服务会设计自动精简配额来满足不同文件系统应用需求,但是现有技术只是为底层数据层次自动精简配额,比如数据服务器下的磁盘空间管理,针对的只是数据,并不涉及文件系统层次。在只有一个分布式文件系统中应用中,需要设计文件系统级别自动精简配额来满足用户对目录配额空间需求。本发明的核心思想在于提供一种分布式文件系统自动精简配置的方法及系统,能够对分布式文件系统进行自动精简配置,对目录容量进行智能高效的分配和管理,用较小的物理容量为文件系统提供大容量的虚拟存储空间。The distributed file system can be divided into three modules: metadata, data, and client. Generally, data services will design automatic quota reduction to meet the application requirements of different file systems. However, existing technologies only automatically reduce quotas for the underlying data level, such as data server The disk space management below is only for data and does not involve the file system level. In applications with only one distributed file system, it is necessary to design file system-level automatic thinning quotas to meet users' requirements for directory quota space. The core idea of the present invention is to provide a method and system for automatic thin provisioning of a distributed file system, which can perform automatic thin provisioning on a distributed file system, intelligently and efficiently allocate and manage directory capacity, and use a smaller physical capacity for The file system provides large-capacity virtual storage space.

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are only some, not all, embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.

本申请实施例提供的第一种分布式文件系统自动精简配置的方法如图1所示,图1为本申请实施例提供的第一种分布式文件系统自动精简配置的方法的示意图。该方法包括如下步骤:The first thin-provisioning method for a distributed file system provided by the embodiment of the present application is shown in FIG. 1 , and FIG. 1 is a schematic diagram of the first thin-provisioning method for a distributed file system provided by the embodiment of the present application. The method comprises the steps of:

S1:为第一目录分配第一使用空间;S1: allocate the first used space for the first directory;

需要说明的是,需要事先设计分布式文件系统目录大小结构,用于存储文件系统下的所有目录的大小,以及目录预分配空间结构,用于显示目录使用空间和显示信息,该结构使用上述目录大小结构,同时会增加使用上限等信息。有了以上两个设计结构后,就可以先对一个目录分配使用空间。It should be noted that the directory size structure of the distributed file system needs to be designed in advance, which is used to store the size of all directories under the file system, and the directory pre-allocated space structure is used to display the space used by the directory and display information. This structure uses the above directory Size structure, and information such as the upper limit of usage will be added at the same time. With the above two design structures, you can allocate and use space for a directory first.

S2:存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小;S2: storing the total space size, the used space size and the remaining space size of the first directory;

在这种情况下,用户通过挂载目录或共享目录方式访问该客户端,可以查看总空间大小、已使用空间大小和剩余空间大小。In this case, users can view the total space, used space, and remaining space by accessing the client through a mounted directory or a shared directory.

S3:当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小;S3: When writing data into the first used space, update the used space size and the remaining space size of the first directory;

在该步骤中,用户在向第一使用空间写入数据后,会不断更新自精简的第一目录的已使用空间大小和剩余空间大小,用于控制使用空间限制,实际应用是不能超出其分配空间的。In this step, after the user writes data to the first used space, the user will continuously update the used space and remaining space of the self-simplified first directory to control the limit of the used space, and the actual application cannot exceed its allocation spatial.

S4:为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小。S4: Allocate a second used space for the second directory, wherein the total space of the second directory is determined according to the remaining space of the first directory.

在这种情况下,就能够智能使用存储空间,例如,文件系统的空间大小为10T,先为第一目录分了5TB,利用现有的方法则第二目录最多分5TB,实际上,利用本申请实施例提供的方法之后,由于第一目录所用的空间大小还不到1TB,这样就可给第二目录设置9TB的空间大小。In this case, the storage space can be used intelligently. For example, if the file system has a space size of 10T, 5TB is allocated to the first directory first. Using the existing method, the second directory can be allocated up to 5TB. In fact, using this After applying the method provided in the embodiment, since the space used by the first directory is less than 1TB, the space size of 9TB can be set for the second directory.

可见上述分布式文件系统自动精简配置的方法用较小的物理容量为文件系统提供超大容量的虚拟存储空间,并且随着业务数据量不断增长,可以及时扩展目录空间。It can be seen that the above-mentioned thin provisioning method of distributed file system provides a large virtual storage space for the file system with a small physical capacity, and can expand the directory space in time as the amount of business data continues to grow.

通过上述描述可知,本申请实施例提供的第一种分布式文件系统自动精简配置的方法,由于先为第一目录分配第一使用空间,然后存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小,当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小,然后为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小,因此能够对分布式文件系统进行自动精简配置,对目录容量进行智能高效的分配和管理,用较小的物理容量为文件系统提供大容量的虚拟存储空间。It can be seen from the above description that the first distributed file system thin provisioning method provided by the embodiment of the present application first allocates the first used space for the first directory, and then stores the total space size of the first directory, the used space size and remaining space size, when writing data into the first used space, update the used space size and remaining space size of the first directory, and then allocate a second used space for the second directory, wherein, The total space of the second directory is determined according to the remaining space of the first directory, so that the distributed file system can be automatically thinned, and the capacity of the directory can be intelligently and efficiently allocated and managed, with a smaller physical capacity Provide large capacity virtual storage space for the file system.

本申请实施例提供的第二种分布式文件系统自动精简配置的方法,是在上述第一种分布式文件系统自动精简配置的方法的基础上,还包括如下技术特征:The second distributed file system thin provisioning method provided in the embodiment of the present application is based on the above-mentioned first distributed file system thin provisioning method, and further includes the following technical features:

在为第一目录分配第一使用空间之后,还包括:显示所述第一目录的总空间大小、已使用空间大小和剩余空间大小;在为第二目录分配第二使用空间之后,还包括:显示所述第二目录的总空间大小、已使用空间大小和剩余空间大小。After allocating the first used space for the first directory, it also includes: displaying the total space size, the used space size and the remaining space size of the first directory; after allocating the second used space for the second directory, it also includes: Display the total space, used space and remaining space of the second directory.

在这种优选方式中,用户通过挂载目录或共享目录方式访问客户端,就可以查看总空间大小、已使用空间大小和剩余空间大小。这里所述的空间大小均是针对为用户分配的空间,这样更具有实际意义。In this preferred mode, the user can view the total space, the used space and the remaining space by accessing the client through a mounted directory or a shared directory. The size of the space mentioned here is for the space allocated to the user, which is more practical.

本申请实施例提供的第三种分布式文件系统自动精简配置的方法,是在上述第二种分布式文件系统自动精简配置的方法的基础上,还包括如下技术特征:The third distributed file system thin provisioning method provided in the embodiment of the present application is based on the above-mentioned second distributed file system thin provisioning method, and further includes the following technical features:

在为第二目录分配第二使用空间之后还包括:存储所述第二目录的总空间大小、已使用空间大小和剩余空间大小,其中,所述第二目录的总空间大小和所述第一目录的总空间大小之和大于所述分布式文件系统的总空间大小。After allocating the second used space for the second directory, it also includes: storing the total space size, the used space size and the remaining space size of the second directory, wherein the total space size of the second directory and the first The sum of the total space sizes of the directories is greater than the total space size of the distributed file system.

在这种情况下,所有目录的预分配空间是可以大于文件系统总空间的,实现空间的充分利用,也不会影响任何一个目录的正常工作,在不超出文件系统容量的情况下,这种自精简功能能够发挥空间智能管理的作用。In this case, the pre-allocated space of all directories can be larger than the total space of the file system to achieve full utilization of the space without affecting the normal work of any directory. Without exceeding the capacity of the file system, this The self-thinning function can play the role of intelligent management of space.

本申请实施例提供的第四种分布式文件系统自动精简配置的方法,是在上述第三种分布式文件系统自动精简配置的方法的基础上,还包括如下技术特征:The fourth distributed file system thin provisioning method provided in the embodiment of the present application is based on the above-mentioned third distributed file system thin provisioning method, and further includes the following technical features:

当所述第一目录或第二目录的已使用空间大小等于对应的总空间大小时,扩充所述第一目录或所述第二目录的总空间大小。When the used space size of the first directory or the second directory is equal to the corresponding total space size, expand the total space size of the first directory or the second directory.

具体的,如果某个自精简目录需要扩容,则修改分配空间为对应的需求值,这样能够满足其对空间的需求,使其发挥应有的功能。Specifically, if a certain self-reduced directory needs to be expanded, the allocated space is modified to the corresponding demand value, so that its demand for space can be met and its proper functions can be performed.

本申请实施例提供的第五种分布式文件系统自动精简配置的方法,是在上述第一种至第四种分布式文件系统自动精简配置的方法中任一种的基础上,还包括如下技术特征:The fifth distributed file system thin provisioning method provided in the embodiment of the present application is based on any one of the above-mentioned first to fourth distributed file system thin provisioning methods, and further includes the following technologies feature:

当所述第一目录的已使用空间大小和所述第二目录的已使用空间大小之和等于所述文件系统的总空间大小时,扩充所述分布式文件系统的容量。When the sum of the used space size of the first directory and the used space size of the second directory is equal to the total space size of the file system, expand the capacity of the distributed file system.

也就是说,当实际写入数据量大于文件系统容量时,就对文件系统进行扩容,以满足各个客户端的需求。That is to say, when the amount of actually written data is greater than the capacity of the file system, the file system is expanded to meet the needs of each client.

本申请实施例提供的第一种分布式文件系统自动精简配置的系统如图2所示,图2为本申请实施例提供的第一种分布式文件系统自动精简配置的系统的示意图。该系统包括:The first distributed file system thin provisioning system provided in the embodiment of the present application is shown in FIG. 2 , which is a schematic diagram of the first distributed file system thin provisioning system provided in the embodiment of the present application. The system includes:

第一分配单元1,用于为第一目录分配第一使用空间,需要事先设计分布式文件系统目录大小结构,用于存储文件系统下的所有目录的大小,以及目录预分配空间结构,用于显示目录使用空间和显示信息,该结构使用上述目录大小结构,同时会增加使用上限等信息。有了以上两个设计结构后,就可以先对一个目录分配使用空间;The first allocation unit 1 is used to allocate the first used space for the first directory. It is necessary to design the directory size structure of the distributed file system in advance, which is used to store the size of all directories under the file system, and the directory pre-allocated space structure for Display the space used by the directory and display information. This structure uses the above directory size structure, and at the same time, information such as the upper limit of usage will be added. With the above two design structures, you can first allocate and use space for a directory;

第一存储单元2,用于存储所述第一目录的总空间大小、已使用空间大小和剩余空间大小,用户通过挂载目录或共享目录方式访问该客户端,可以查看总空间大小、已使用空间大小和剩余空间大小;The first storage unit 2 is used to store the total space size, the used space size and the remaining space size of the first directory, and the user can view the total space size, the used space size and the used space size by accessing the client by mounting the directory or sharing the directory. The size of the space and the size of the remaining space;

更新单元3,用于当向所述第一使用空间中写入数据时,更新所述第一目录的已使用空间大小和剩余空间大小,用户在向第一使用空间写入数据后,会不断更新自精简的第一目录的已使用空间大小和剩余空间大小,用于控制使用空间限制,实际应用是不能超出其分配空间的;The update unit 3 is used to update the used space size and the remaining space size of the first directory when writing data into the first used space. After the user writes data to the first used space, he will continue to The used space size and remaining space size of the updated self-simplified first directory are used to control the space usage limit, and the actual application cannot exceed its allocated space;

第二分配单元4,用于为第二目录分配第二使用空间,其中,根据所述第一目录的剩余空间大小确定所述第二目录的总空间大小,在这种情况下,就能够智能使用存储空间,例如,文件系统的空间大小为10T,先为第一目录分了5TB,利用现有的方法则第二目录最多分5TB,实际上,利用本申请实施例提供的方法之后,由于第一目录所用的空间大小还不到1TB,这样就可给第二目录设置9TB的空间大小。The second allocating unit 4 is used to allocate the second used space for the second directory, wherein the total space size of the second directory is determined according to the remaining space size of the first directory, in this case, it can intelligently Using storage space, for example, the space size of the file system is 10T. First, 5TB is allocated for the first directory. Using the existing method, the second directory can be divided into 5TB at most. In fact, after using the method provided by the embodiment of this application, due to The space used by the first directory is less than 1TB, so the space size of the second directory can be set to 9TB.

通过上述描述可知,本申请实施例提供的第一种分布式文件系统自动精简配置的系统,能够对分布式文件系统进行自动精简配置,对目录容量进行智能高效的分配和管理,用较小的物理容量为文件系统提供大容量的虚拟存储空间。From the above description, it can be seen that the first distributed file system automatic thin provisioning system provided by the embodiment of the present application can perform automatic thin provisioning on a distributed file system, intelligently and efficiently allocate and manage directory capacity, and use a small Physical capacity provides a large capacity of virtual storage space for the file system.

本申请实施例提供的第二种分布式文件系统自动精简配置的系统,是在上述第一种分布式文件系统自动精简配置的系统的基础上,还包括如下技术特征:The second distributed file system thin provisioning system provided in the embodiment of the present application is based on the above-mentioned first distributed file system thin provisioning system, and further includes the following technical features:

还包括:Also includes:

第一显示单元,用于显示所述第一目录的总空间大小、已使用空间大小和剩余空间大小;a first display unit, configured to display the total space size, the used space size and the remaining space size of the first directory;

第二显示单元,用于显示所述第二目录的总空间大小、已使用空间大小和剩余空间大小。The second display unit is used to display the total space size, the used space size and the remaining space size of the second directory.

用户通过挂载目录或共享目录方式访问客户端,就可以查看总空间大小、已使用空间大小和剩余空间大小。这里所述的空间大小均是针对为用户分配的空间,这样更具有实际意义。Users can view the total space, used space and remaining space by accessing the client by mounting a directory or sharing a directory. The size of the space mentioned here is for the space allocated to the user, which is more practical.

本申请实施例提供的第三种分布式文件系统自动精简配置的系统,是在上述第二种分布式文件系统自动精简配置的系统的基础上,还包括如下技术特征:The third distributed file system thin provisioning system provided in the embodiment of the present application is based on the above-mentioned second distributed file system thin provisioning system, and further includes the following technical features:

还包括:Also includes:

第二存储单元,用于存储所述第二目录的总空间大小、已使用空间大小和剩余空间大小,其中,所述第二目录的总空间大小和所述第一目录的总空间大小之和大于所述分布式文件系统的总空间大小。The second storage unit is used to store the total space size, the used space size and the remaining space size of the second directory, wherein the sum of the total space size of the second directory and the total space size of the first directory Greater than the total space size of the distributed file system.

在这种情况下,所有目录的预分配空间是可以大于文件系统总空间的,实现空间的充分利用,也不会影响任何一个目录的正常工作,在不超出文件系统容量的情况下,这种自精简功能能够发挥空间智能管理的作用。In this case, the pre-allocated space of all directories can be larger than the total space of the file system to achieve full utilization of the space without affecting the normal work of any directory. Without exceeding the capacity of the file system, this The self-thinning function can play the role of intelligent management of space.

本申请实施例提供的第四种分布式文件系统自动精简配置的系统,是在上述第三种分布式文件系统自动精简配置的系统的基础上,还包括如下技术特征:The fourth distributed file system thin provisioning system provided in the embodiment of the present application is based on the third distributed file system thin provisioning system described above, and further includes the following technical features:

还包括:Also includes:

第一扩充单元,用于当所述第一目录或第二目录的已使用空间大小等于对应的总空间大小时,扩充所述第一目录或所述第二目录的总空间大小。The first expansion unit is configured to expand the total space of the first directory or the second directory when the used space of the first directory or the second directory is equal to the corresponding total space.

具体的,如果某个自精简目录需要扩容,则修改分配空间为对应的需求值,这样能够满足其对空间的需求,使其发挥应有的功能。Specifically, if a certain self-reduced directory needs to be expanded, the allocated space is modified to the corresponding demand value, so that its demand for space can be met and its proper functions can be performed.

本申请实施例提供的第五种分布式文件系统自动精简配置的系统,是在上述第一种至第四种分布式文件系统自动精简配置的系统中任一种的基础上,还包括如下技术特征:The fifth distributed file system thin provisioning system provided in the embodiment of the present application is based on any one of the above-mentioned first to fourth distributed file system thin provisioning systems, and further includes the following technologies feature:

还包括:Also includes:

第二扩充单元,用于当所述第一目录的已使用空间大小和所述第二目录的已使用空间大小之和等于所述文件系统的总空间大小时,扩充所述分布式文件系统的容量。The second expansion unit is configured to expand the distributed file system when the sum of the used space size of the first directory and the used space size of the second directory is equal to the total space size of the file system capacity.

也就是说,当实际写入数据量大于文件系统容量时,就对文件系统进行扩容,以满足各个客户端的需求。That is to say, when the amount of actually written data is greater than the capacity of the file system, the file system is expanded to meet the needs of each client.

对所公开的实施例的上述说明,使本领域专业技术人员能够实现或使用本发明。对这些实施例的多种修改对本领域的专业技术人员来说将是显而易见的,本文中所定义的一般原理可以在不脱离本发明的精神或范围的情况下,在其它实施例中实现。因此,本发明将不会被限制于本文所示的这些实施例,而是要符合与本文所公开的原理和新颖特点相一致的最宽的范围。The above description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the present invention will not be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. the method that a distributed file system simplifies configuration automatically, it is characterised in that including:
It it is first catalogue distribution the first use space;
Store the gross space size of described first catalogue, use space size and remaining space size;
When using write data in space to described first, update the space size of use and the residue sky of described first catalogue Between size;
It is second catalogue distribution the second use space, wherein, determines described the according to the remaining space size of described first catalogue The gross space size of two catalogues.
Distributed file system the most according to claim 1 simplifies the method for configuration automatically, it is characterised in that for first Catalogue distribution first use space after, also include: show described first catalogue gross space size, use space size and Remaining space size;After for second catalogue distribution the second use space, also include: show the gross space of described second catalogue Size, use space size and remaining space size.
Distributed file system the most according to claim 2 simplifies the method for configuration automatically, it is characterised in that for second Catalogue distribution second use space after also include: store described second catalogue gross space size, use space size and Remaining space size, wherein, the gross space size of described second catalogue and the gross space size sum of described first catalogue are more than The gross space size of described distributed file system.
Distributed file system the most according to claim 3 simplifies the method for configuration automatically, it is characterised in that when described One catalogue or when using the gross space size that space size is equal to correspondence of the second catalogue, expand described first catalogue or described The gross space size of the second catalogue.
5. the method automatically simplifying configuration according to the distributed file system described in any one of claim 1-4, it is characterised in that When the space size sum of use using space size and described second catalogue of described first catalogue is equal to described file During the gross space size of system, expand the capacity of described distributed file system.
6. a distributed file system simplifies the system of configuration automatically, it is characterised in that including:
First allocation unit, being used for is first catalogue distribution the first use space;
First memory element, for storing the gross space size of described first catalogue, using space size and remaining space big Little;
Updating block, for when using write data in space to described first, the use updating described first catalogue is empty Between size and remaining space size;
Second allocation unit, is used for being second catalogue distribution the second use space, wherein, the residue according to described first catalogue is empty Between size determine the gross space size of described second catalogue.
Distributed file system the most according to claim 6 simplifies the system of configuration automatically, it is characterised in that also include:
First display unit, for showing the gross space size of described first catalogue, using space size and remaining space big Little;
Second display unit, for showing the gross space size of described second catalogue, using space size and remaining space big Little.
Distributed file system the most according to claim 7 simplifies the system of configuration automatically, it is characterised in that also include:
Second memory element, for storing the gross space size of described second catalogue, using space size and remaining space big Little, wherein, the gross space size of described second catalogue and the gross space size sum of described first catalogue are more than described distributed The gross space size of file system.
Distributed file system the most according to claim 8 simplifies the system of configuration automatically, it is characterised in that also include:
First expansion unit, for being equal to the gross space of correspondence when the space size that uses of described first catalogue or the second catalogue During size, expand described first catalogue or the gross space size of described second catalogue.
10. automatically simplify the system of configuration according to the distributed file system described in any one of claim 6-9, its feature exists In, also include:
Second expansion unit, for when the space of use using space size and described second catalogue of described first catalogue When size sum is equal to the gross space size of described file system, expand the capacity of described distributed file system.
CN201610525147.1A 2016-07-05 2016-07-05 A kind of distributed file system simplifies the method and system of configuration automatically Pending CN106202350A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610525147.1A CN106202350A (en) 2016-07-05 2016-07-05 A kind of distributed file system simplifies the method and system of configuration automatically

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610525147.1A CN106202350A (en) 2016-07-05 2016-07-05 A kind of distributed file system simplifies the method and system of configuration automatically

Publications (1)

Publication Number Publication Date
CN106202350A true CN106202350A (en) 2016-12-07

Family

ID=57466300

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610525147.1A Pending CN106202350A (en) 2016-07-05 2016-07-05 A kind of distributed file system simplifies the method and system of configuration automatically

Country Status (1)

Country Link
CN (1) CN106202350A (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106899676A (en) * 2017-02-28 2017-06-27 郑州云海信息技术有限公司 A kind of multi-client writes catalogue quota allotment approach
CN108073723A (en) * 2018-01-03 2018-05-25 郑州云海信息技术有限公司 A kind of file in distributed type assemblies storage is from compressing method and equipment
CN111459880A (en) * 2020-03-27 2020-07-28 苏州浪潮智能科技有限公司 Method and system for modifying total space of self-simplified pre-allocation space compatible system
CN113420000A (en) * 2021-05-13 2021-09-21 新华三信息安全技术有限公司 Storage management method, device, equipment and machine-readable storage medium

Citations (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004053846A2 (en) * 2002-12-10 2004-06-24 John Alan Hensley Emulated read-write disk drive using a protected medium
US20040193621A1 (en) * 2003-03-27 2004-09-30 Microsoft Corporation System and method utilizing virtual folders
CN1776648A (en) * 2005-12-16 2006-05-24 北京中星微电子有限公司 Method and device for getting residual space for FAT file system
CN101162469A (en) * 2007-11-09 2008-04-16 清华大学 Fine grit document and catalogs version management method based on snapshot
CN101567003A (en) * 2009-05-27 2009-10-28 清华大学 Method for managing and allocating resource in parallel file system
CN101646044A (en) * 2008-08-05 2010-02-10 深圳市同洲电子股份有限公司 PVR set-top box and method and system for virtual partition management of time-shifting files of PVR set-top box
US20100082715A1 (en) * 2008-09-30 2010-04-01 Karl Dohm Reduced-Resource Block Thin Provisioning
CN102129476A (en) * 2011-04-22 2011-07-20 上海网达软件有限公司 Application of virtual file system by utilizing ZIP compression format
CN102546780A (en) * 2011-12-28 2012-07-04 山东大学 Operation method for file distributed storage based on thin client
CN102567215A (en) * 2010-11-24 2012-07-11 微软公司 Thin Provisioned Space Allocation
CN102693164A (en) * 2012-05-03 2012-09-26 中国石油集团川庆钻探工程有限公司地球物理勘探公司 Equipment and method for preventing buffer overflow
CN102968279A (en) * 2012-11-13 2013-03-13 浪潮电子信息产业股份有限公司 Thin provisioning method for storage system
CN103140827A (en) * 2010-09-29 2013-06-05 国际商业机器公司 Managing ownership of redundant data in storage system
CN103365926A (en) * 2012-03-30 2013-10-23 伊姆西公司 Method and device for storing snapshot in file system
CN103544254A (en) * 2013-10-15 2014-01-29 华为技术有限公司 Method and device for managing data
CN103714013A (en) * 2013-12-31 2014-04-09 华为技术有限公司 Method and device for allocating storage space of file system
CN104182439A (en) * 2014-02-26 2014-12-03 无锡天脉聚源传媒科技有限公司 File automatic-cleaning method and device
CN104205780A (en) * 2014-01-23 2014-12-10 华为技术有限公司 A method and device for storing data
CN104408053A (en) * 2014-10-29 2015-03-11 上海斐讯数据通信技术有限公司 Mobile-terminal storage-card extending method
CN104820575A (en) * 2015-04-27 2015-08-05 西北工业大学 Method for realizing thin provisioning of storage system
CN105159968A (en) * 2015-08-25 2015-12-16 浪潮(北京)电子信息产业有限公司 Directory management method for file system and client
US9329792B2 (en) * 2014-01-14 2016-05-03 International Business Machines Corporation Storage thin provisioning and space reclamation

Patent Citations (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2004053846A2 (en) * 2002-12-10 2004-06-24 John Alan Hensley Emulated read-write disk drive using a protected medium
US20040193621A1 (en) * 2003-03-27 2004-09-30 Microsoft Corporation System and method utilizing virtual folders
CN1776648A (en) * 2005-12-16 2006-05-24 北京中星微电子有限公司 Method and device for getting residual space for FAT file system
CN101162469A (en) * 2007-11-09 2008-04-16 清华大学 Fine grit document and catalogs version management method based on snapshot
CN101646044A (en) * 2008-08-05 2010-02-10 深圳市同洲电子股份有限公司 PVR set-top box and method and system for virtual partition management of time-shifting files of PVR set-top box
US20100082715A1 (en) * 2008-09-30 2010-04-01 Karl Dohm Reduced-Resource Block Thin Provisioning
CN101567003A (en) * 2009-05-27 2009-10-28 清华大学 Method for managing and allocating resource in parallel file system
CN103140827A (en) * 2010-09-29 2013-06-05 国际商业机器公司 Managing ownership of redundant data in storage system
CN102567215A (en) * 2010-11-24 2012-07-11 微软公司 Thin Provisioned Space Allocation
CN102129476A (en) * 2011-04-22 2011-07-20 上海网达软件有限公司 Application of virtual file system by utilizing ZIP compression format
CN102546780A (en) * 2011-12-28 2012-07-04 山东大学 Operation method for file distributed storage based on thin client
CN103365926A (en) * 2012-03-30 2013-10-23 伊姆西公司 Method and device for storing snapshot in file system
CN102693164A (en) * 2012-05-03 2012-09-26 中国石油集团川庆钻探工程有限公司地球物理勘探公司 Equipment and method for preventing buffer overflow
CN102968279A (en) * 2012-11-13 2013-03-13 浪潮电子信息产业股份有限公司 Thin provisioning method for storage system
CN103544254A (en) * 2013-10-15 2014-01-29 华为技术有限公司 Method and device for managing data
CN103714013A (en) * 2013-12-31 2014-04-09 华为技术有限公司 Method and device for allocating storage space of file system
US9329792B2 (en) * 2014-01-14 2016-05-03 International Business Machines Corporation Storage thin provisioning and space reclamation
CN104205780A (en) * 2014-01-23 2014-12-10 华为技术有限公司 A method and device for storing data
CN104182439A (en) * 2014-02-26 2014-12-03 无锡天脉聚源传媒科技有限公司 File automatic-cleaning method and device
CN104408053A (en) * 2014-10-29 2015-03-11 上海斐讯数据通信技术有限公司 Mobile-terminal storage-card extending method
CN104820575A (en) * 2015-04-27 2015-08-05 西北工业大学 Method for realizing thin provisioning of storage system
CN105159968A (en) * 2015-08-25 2015-12-16 浪潮(北京)电子信息产业有限公司 Directory management method for file system and client

Non-Patent Citations (7)

* Cited by examiner, † Cited by third party
Title
HUNG-CHANG DU: ""On the File Design Problem for Partial Match Retrieval"", 《IEEE TRANSACTIONS ON SOFTWARE ENGINEERING》 *
WEI-CHIH HUANG ET AL.: ""Resource Provisioning with QoS in Cloud Storage"", 《2014 IEEE INTERNATIONAL CONGRESS ON BIG DATA》 *
任勇 等: ""新型虚拟文件存储系统的设计 "", 《计算机研究与发展》 *
王恩东 等: ""一种提升自动精简配置效能的方法研究"", 《计算机工程》 *
程炜烨: ""一种分布式文件系统的设计和实现"", 《微处理机》 *
谭子军 等: ""分布式存储系统中用户磁盘空间分配策略"", 《计算机工程》 *
谭子军: ""分布式加密存储系统的文件数据分布与磁盘配额管理技术研究"", 《中国优秀硕士学位论文全文数据库》 *

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106899676A (en) * 2017-02-28 2017-06-27 郑州云海信息技术有限公司 A kind of multi-client writes catalogue quota allotment approach
CN108073723A (en) * 2018-01-03 2018-05-25 郑州云海信息技术有限公司 A kind of file in distributed type assemblies storage is from compressing method and equipment
CN111459880A (en) * 2020-03-27 2020-07-28 苏州浪潮智能科技有限公司 Method and system for modifying total space of self-simplified pre-allocation space compatible system
CN111459880B (en) * 2020-03-27 2023-01-06 苏州浪潮智能科技有限公司 A method and system for modifying the total space of a self-thinning pre-allocated space compatible system
CN113420000A (en) * 2021-05-13 2021-09-21 新华三信息安全技术有限公司 Storage management method, device, equipment and machine-readable storage medium

Similar Documents

Publication Publication Date Title
CN110663019B (en) File system for Shingled Magnetic Recording (SMR)
CN105378687B (en) Access the method and relevant device of file
JP5932043B2 (en) Volatile memory representation of non-volatile storage set
US10339123B2 (en) Data management for tenants
US9134908B2 (en) Logical volume space sharing
CN102255962B (en) Distributive storage method, device and system
CN106899676A (en) A kind of multi-client writes catalogue quota allotment approach
US20090210464A1 (en) Storage management system and method thereof
CN101986649B (en) Shared data center used in telecommunication industry billing system
JP2015507281A (en) Allocating resources in a virtual machine pool
CN104820575A (en) Method for realizing thin provisioning of storage system
CN106202350A (en) A kind of distributed file system simplifies the method and system of configuration automatically
EP3103039B1 (en) System and method for an efficient database storage model based on sparse files
CN101799797A (en) Dynamic allocation method of user disk quota in distributed storage system
CN103218305B (en) The distribution method of memory space
JPH10333949A (en) Data storage control system
WO2024078211A1 (en) Backup method for service cluster instance, recovery method for service cluster instance, and related device
US9588707B2 (en) Object storage power consumption optimization
CN109445943A (en) The EMS memory management process of I/O stack, system and relevant apparatus in kernel state system
CN103823641B (en) The virtual volume system of a kind of on-line rapid estimation and its implementation
CN105389216A (en) Clipboard data caching method and apparatus and electronic device
US10735504B2 (en) System and method for distributed workbook storage
CN107577431A (en) A kind of storage pool construction method and device
WO2017214369A1 (en) Systems and methods for implementing dynamic file systems
CN100454844C (en) Method of increment synchronization for multipoint restoring software environment of computer room

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication

Application publication date: 20161207

RJ01 Rejection of invention patent application after publication