# US 2018/0322142 A1 · Metadata server and method for distributing metadata in units of directories using the same

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2018/0322142 A1
- Document ID: US20180322142A1
- Status: Published application
- Kind: A1
- Application number: 15/941,962
- Filed: 2018-03-30
- Published: 2018-11-08
- Earliest claimed: 2017-05-02
- Assignees: Electronics and Telecommunications Research Institute
- Applicants: Electronics and Telecommunications Research Institute
- Inventors: Sang-Min LEE; Young-Kyun KIM; Hong-Yeon KIM
- Web page: https://patentgrep.com/patent/US20180322142A1

## CPC

- G06F 16/183: {Provision of network file services by network file servers, e.g. by using NFS, CIFS (network file access protocols H04L67/1097)}
- G06F 16/148: {File search processing}
- G06F 16/162: {Delete operations (erasing in storage systems G06F3/0652)}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

Disclosed herein are a metadata server and a method for distributing metadata in units of directories using the metadata server. The method includes receiving a request for at least one of creation, deletion and retrieval from a user file system; acquiring an inode corresponding to an identifier of a parent inode, which is included in the request; searching the parent inode for a dentry corresponding to the request when the request is a request to create a directory; selecting a secondary metadata server in which a new directory is to be created in order to distribute metadata in units of directories; requesting the selected secondary metadata server to create an inode; receiving an identifier of the created inode from the secondary metadata server; and adding a new dentry to the parent inode using the identifier of the inode.

## Claims

### Claim 1

A method for distributing metadata in units of directories, which is performed by a metadata server, comprising:
receiving a request for at least one of creation, deletion, and retrieval from a user file system;
acquiring an inode corresponding to an identifier of a parent inode, which is included in the request;
when the request is a request to create a directory, searching the parent inode for a dentry (directory entry) corresponding to the request;
selecting a secondary metadata server to which a new directory is to be assigned in order to distribute metadata in units of directories;
requesting the selected secondary metadata server to create an inode therein;
receiving an identifier of the created inode from the secondary metadata server; and
adding a new dentry to the parent inode using the identifier of the inode.

### Claim 2 (depends on 1)

The method of claim 1, further comprising:
when the request is not a request to create a directory, acquiring an address of the secondary metadata server and the identifier of the inode from dentry information corresponding to the request.

### Claim 3 (depends on 2)

The method of claim 2, further comprising:
when the request is a request to delete a directory, requesting the secondary metadata server to delete the inode; and
deleting corresponding dentry information from the parent inode.

### Claim 4 (depends on 2)

The method of claim 2, further comprising:
when the request is a request to search for a directory, requesting information about the inode from the secondary metadata server and receiving the information about the inode from the secondary metadata server.

### Claim 5 (depends on 1)

The method of claim 1, further comprising:
when the request is a request for at least one of creation, deletion, and retrieval of a file, searching the parent inode for a dentry corresponding to the request.

### Claim 6 (depends on 5)

The method of claim 5, further comprising:
when the request is a request to create a file, searching the parent inode for the dentry corresponding to the request;
when the dentry is not found, creating a new inode; and
adding a new dentry to the parent inode using an identifier of the new inode.

### Claim 7 (depends on 5)

The method of claim 5, further comprising:
when the request is a request to delete a file and when the dentry is found, acquiring an inode corresponding to the dentry;
deleting the inode corresponding to the request; and
deleting the corresponding dentry from the parent inode.

### Claim 8 (depends on 5)

The method of claim 5, further comprising:
when the request is a request to search for a file and when the dentry is found, acquiring an inode corresponding to the dentry; and
acquiring information about the inode corresponding to the dentry.

### Claim 9 (depends on 1)

The method of claim 1, further comprising:
after acquiring the inode, determining whether the parent inode is present; and
when it is determined that the parent inode is not present, sending a failure message to the user file system.

### Claim 10 (depends on 1)

The method of claim 1, further comprising:
when the dentry is found, sending a failure message to the user file system.

### Claim 11 (depends on 1)

The method of claim 1, wherein the request is in regard to a file or a directory, and includes at least one of a command, the identifier of the parent inode, and a file name.

### Claim 12 (depends on 1)

The method of claim 1, wherein at least one of the metadata server and the secondary metadata server searches for a block corresponding to a user request using a block structure including a block index field, a lock field, a dirty field, a dirty start time field, and a block data field.

### Claim 13 (depends on 12)

The method of claim 12, further comprising:
grouping all blocks to be flushed into multiple groups and gradually flushing the blocks.

### Claim 14 (depends on 13)

The method of claim 13, wherein flushing the blocks is configured to perform flushing after grouping the blocks based on a maximum number of blocks to be included in each group or based on a distance between blocks.

### Claim 15 (depends on 13)

The method of claim 13, wherein flushing the blocks is configured to repeatedly perform:
extracting the dirty blocks one by one from a dirty head to which the dirty blocks are connected,
removing the extracted block from the dirty head and adding the removed block to a write head, and
waiting for a preset time until the blocks included in the write head are flushed.

### Claim 16

A metadata server, comprising:
a request reception unit for receiving a request for at least one of creation, deletion, and retrieval from a user file system;
an inode acquisition unit for acquiring an inode corresponding to an identifier of a parent inode, which is included in the request;
a request analysis unit for determining whether the request is in regard to a file or a directory;
a metadata distribution unit for searching for a dentry corresponding to the request, creating a new inode or searching for or deleting an inode corresponding to the dentry when the request is in regard to a file, and processing the request using a secondary metadata server to which metadata are distributed in units of directories when the request is in regard to a directory; and
a directory management unit for adding a new dentry to the parent inode or deleting the inode corresponding to the dentry from the parent inode based on a result of processing the request.

### Claim 17 (depends on 16)

The metadata server of claim 16, wherein the metadata distribution unit is configured to add the new dentry to the parent inode corresponding to the request or search for or delete the inode corresponding to the request when the request is a request for any one of creation, deletion, and retrieval of a file.

### Claim 18 (depends on 16)

The metadata server of claim 16, wherein the metadata distribution unit is configured to create an inode in the secondary metadata server or retrieve or delete an inode from the secondary metadata server so as to respond to the request when the request is a request for any one of creation, deletion, and retrieval of a directory.

### Claim 19

A metadata server, comprising:
a block search unit for searching for a block corresponding to a user request using a block structure including a block index field, a lock field, a dirty field, a dirty start time field, and a block data field;
a grouping unit for grouping all blocks to be flushed based on at least one of a maximum number of blocks to be included in each group and a distance between blocks; and
a flushing unit for gradually flushing the grouped blocks.

### Claim 20 (depends on 19)

The metadata server of claim 19, wherein the flushing unit repeatedly performs extracting the dirty blocks one by one from a dirty head to which the dirty blocks are connected, removing the extracted block from the dirty head, adding the removed block to a write head, and waiting for a preset time until the blocks included in the write head are flushed.
