The invention discloses a distributed file system metadata information reading method, including: the path information to be read metadata No. inode; according to the path information in the database to find the corresponding inode information; according to the inode information, reads the metadata to be read; among them, the path information is stored in advance the inode path metadata corresponding to be read. Thus, the invention through the path information of pre recorded metadata No. inode, in the need to read metadata, according to the path information in the cache system to find the parent directory and ancestor directory inode, and read the corresponding metadata, which significantly improves the distributed file system metadata information read speed. The invention also discloses a metadata information reading system of a distributed file system, which has the same technical effect as the method described above.
【技术实现步骤摘要】
一种分布式文件系统元数据信息读取方法及系统
本专利技术涉及元数据读取
,特别涉及一种分布式文件系统元数据信息读取方法及系统。
技术介绍
分布式文件系统元数据信息存储了文件的所有属性信息以及数据存储位置,这些元数据信息都存储到inode,即索引节点中,每个文件都有唯一的inode存储元数据信息,inode会有唯一的inode号作为inode的标识。众所周知,分布式文件系统有元数据服务、数据服务和客户端三大组成部分。对于分布式文件系统的文件IO操作,首先要获取文件元数据信息,然后再去操作数据。元数据信息存储了文件的所有属性信息以及数据存储位置,这些元数据信息都存储到inode中,每个文件都有唯一的inode存储元数据信息。当然,目录作为一种具有目录信息的特殊文件,也是如此。inode会有唯一的inode号作为inode的标识。文件系统中一个文件元数据信息读取,一般有两种方式:一种是依据inode存储位置获取inode信息;第二种是通过父目录元数据信息去读取子文件元数据信息。前者主要用于本地文件系统,后者主要用于分布式文件系统。而后者最大的弊端是无法直接依据文件inode号直接获取元数据信息。这就导致文件系统无法充分使用inode号去优化元数据机制,从而导致元数据信息读取速度较低。综上所述,如何提高分布式文件系统元数据信息读取速度是本领域技术人员目前需要解决的技术问题。
技术实现思路
有鉴于此,本专利技术的目的在于提供一种分布式文件系统元数据信息读取方法及系统,可以显著提高分布式文件系统元数据信息读取速度。其具体方案如下:一种分布式文件系统元数据信息读取方法, ...
【技术保护点】
一种分布式文件系统元数据信息读取方法,其特征在于,包括:获取待读取元数据的inode号的路径信息;根据所述路径信息,在数据库中查找相应的inode信息;根据所述inode信息,读取所述待读取元数据;其中,所述路径信息为预先存储的所述待读取元数据相应的inode路径。
【技术特征摘要】
1.一种分布式文件系统元数据信息读取方法,其特征在于,包括:获取待读取元数据的inode号的路径信息;根据所述路径信息,在数据库中查找相应的inode信息;根据所述inode信息,读取所述待读取元数据;其中,所述路径信息为预先存储的所述待读取元数据相应的inode路径。2.根据权利要求1所述的分布式文件系统元数据信息读取方法,其特征在于,所述inode号均存储在所述数据库中。3.根据权利要求2所述的分布式文件系统元数据信息读取方法,其特征在于,所述数据库为键值存储数据库。4.根据权利要求3所述的分布式文件系统元数据信息读取方法,其特征在于,获取待读取元数据的inode号的路径信息包括:在所述键值存储数据库中,根据key=待读取元数据的inode号的值,得到所述路径信息。5.根据权利要求4所述的分布式文件系统元数据信息读取方法,其特征在...
【专利技术属性】
技术研发人员:张延良,
申请(专利权)人:郑州云海信息技术有限公司,
类型:发明
国别省市:河南,41
还没有人留言评论。发表了对其他浏览者有用的留言会获得科技券。