# US 11,030,155 B2 · Key value file system

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

- Number: US 11,030,155 B2
- Document ID: US11030155B2
- Status: Granted
- Kind: B2
- Application number: 15/645,916
- Filed: 2017-07-10
- Published: 2017-11-02
- Granted: 2021-06-08
- Earliest claimed: 2017-04-26
- Assignees: Samsung Electronics Co., Ltd.
- Applicants: Samsung Electronics Co., Ltd.
- Inventors: Kumar Kanteti
- Web page: https://patentgrep.com/patent/US11030155B2

## CPC

- G06F 3/061: {Improving I/O performance}
- G06F 16/1727: {Details of free space management performed by the file system (saving storage space on storage systems G06F3/0608; management of blocks in storage devices G06F3/064)}
- G06F 3/0659: {Command handling arrangements, e.g. command buffers, queues, command scheduling}
- G06F 3/067: {Distributed or networked storage systems, e.g. storage area networks [SAN], network attached storage [NAS]}
- G06F 16/13: File access structures, e.g. distributed indices (arrangements of input from, or output to, record carriers G06F3/06)
- G06F 16/148: {File search processing}
- G06F 16/1724: {Details of de-fragmentation performed by the file system (saving storage space on storage systems G06F3/0608; management of blocks in storage devices G06F3/064)}
- G06F 16/185: Hierarchical storage management [HSM] systems, e.g. file migration or policies thereof (details of archiving G06F16/11)
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

A file system includes: an application programming interface (API) configured to provide a file system access to an application running on a host computer; a key value file system configured to represent a file or a directory as an inode including one or more key-value pairs; a virtual file system configured to direct a file system call received from the application to the key value file system; and a key value API configured to provide the file system access to data stored in a data storage device. Each key-value pair contained in the inode includes a name of the file or the directory as a key and an identifier of a container that is associated with the file or the directory as a value. The data of the file is stored in the data storage device as being divided into one or more data blocks of a fixed size, and each of the one or more data blocks associated with the data of the file is accessible within the key value file system using the one or more key-value pairs.

## Claims

### Claim 1

A file system comprising:
an application programming interface (API) configured to provide a file system access to an application running on a host computer;
a key value file system configured to represent a file or a directory as an inode including one or more key-value pairs;
a virtual file system configured to direct a file system call received from the application to the key value file system; and
a key value API configured to provide the file system access to data stored in a data storage device,
wherein each key-value pair contained in the inode includes a name of the file or the directory as a key and an identifier of a container that is associated with the file or the directory as a value,
wherein the data of the file is stored in the data storage device as being divided into one or more data blocks of a fixed size, and each of the one or more data blocks associated with the data of the file is accessible within the key value file system using the one or more key-value pairs,
wherein the data storage device stores the inode as a container inode or an inline inode depending on a predetermined number of entries in the inode, and
wherein the container inode includes one or more key-value pairs corresponding to each of the entries, and the inline inode includes a single key-value pair, a value of the single key-value pair includes a list of attributes corresponding to the entries.

### Claim 2 (depends on 1)

The file system of claim 1, wherein the API is portable operating system interface for Unix (POSIX) API, and an operating system of the file system is Linux.

### Claim 3 (depends on 1)

The file system of claim 1, wherein attributes of the inode are stored in a key-value pair of the one or more key-value pairs.

### Claim 4 (depends on 1)

The file system of claim 1, wherein the directory is represented by either a container directory or an inline directory depending on a number of key-value pair entries contained in the container of the directory.

### Claim 5 (depends on 4)

The file system of claim 4, wherein the container of the inline directory includes a single key-value pair, and wherein the value of the single key-value pair includes attributes of the inline directory and one or more key-value pairs corresponding to one or more subdirectories of the inline directory or one or more files stored in the inline directory.

### Claim 6 (depends on 4)

The file system of claim 4, the inline directory is converted to the container directory when the number of entries exceeds a predetermined size, and the container directory is converted to the inline directory when the number of entries is reduced below the predetermined size.

### Claim 7 (depends on 1)

The file system of claim 1, wherein the file is represented by either a container file or an inline file depending on a number of key-value pair entries contained in the container of the file.

### Claim 8 (depends on 7)

The file system of claim 7, wherein the container of the container file includes one or more key-value pairs corresponding to the one or more data blocks of the data for the container file.

### Claim 9 (depends on 7)

The file system of claim 7, wherein the container of the inline file includes one or more key-value pairs, and at least one key-value pair of the one or more key-value pairs includes a name of the inline file and data associated with the inline file, and wherein the data of the at least one key-value pair includes one or more key-value pairs corresponding to data blocks storing data of the inline file.

### Claim 10 (depends on 7)

The file system of claim 7, the inline file is converted to the container file when the number of entries in the container of the inline file exceeds a predetermined size, and the container file is converted to the inline file when the number of entries is reduced below the predetermined size.

### Claim 11 (depends on 1)

The file system of claim 1, wherein the file is stored in a plurality of data storage devices, and the inode includes one or more key-value tuples including an identifier of the data storage device, an identifier of the container, and the key.

### Claim 12 (depends on 1)

The file system of claim 1, wherein the file is truncatable or deletable in a single I/O operation within the key value file system without traversing layers of metadata corresponding to one or more directories within which the file is stored.

### Claim 13

A method comprising:
storing a file or a directory in a data storage device as an inode including one or more key-value pairs in a key value file system;
receiving a file system access request from an application running on a host computer;
directing the file system access request to a file system call to the data storage device; and
providing the file system access to data stored in the data storage device,
wherein each key-value pair contained in the inode includes a name of the file or the directory as a key and an identifier of a container that is associated with the file or the directory as a value,
wherein the data of the file is stored in the data storage device as being divided into one or more data blocks of a fixed size, and each of the one or more data blocks associated with the data of the file is accessible within the key value file system using the one or more key-value pairs,
wherein the data storage device stores the inode as a container inode or an inline inode depending on a predetermined number of entries in the inode, and
wherein the container inode includes one or more key-value pairs corresponding to each of the entries, and the inline inode includes a single key-value pair, a value of the single key-value pair includes a list of attributes corresponding to the entries.

### Claim 14 (depends on 13)

The method of claim 13, wherein the file system access request from the application is received via POSIX API, and an operating system of the key value file system is Linux.

### Claim 15 (depends on 13)

The method of claim 13, wherein attributes of the inode is stored in a key-value pair of the one or more key-value pairs.

### Claim 16 (depends on 13)

The method of claim 13, wherein the directory is represented by either a container directory or an inline directory depending on a number of key-value pair entries contained in the container of the directory.

### Claim 17 (depends on 16)

The method of claim 16, wherein the container of the inline directory includes a single key-value pair, and wherein the value of the single key-value pair includes attributes of the inline directory and one or more key-value pairs corresponding to one or more subdirectories of the inline directory or one or more files stored in the inline directory.

### Claim 18 (depends on 16)

The method of claim 16, the inline directory is converted to the container directory when the number of entries exceeds a predetermined size, and the container directory is converted to the inline directory when the number of entries is reduced below the predetermined size.

### Claim 19 (depends on 13)

The method of claim 13, wherein the file is represented by either a container file or an inline file depending on a number of key-value pair entries contained in the container of the file.

### Claim 20 (depends on 19)

The method of claim 19, wherein the container of the container file includes one or more key-value pairs corresponding to the one or more data blocks of the data for the container file.

### Claim 21 (depends on 19)

The method of claim 19, wherein the container of the inline file includes one or more key-value pairs, and at least one key-value pair of the one or more key-value pairs includes a name of the inline file and data associated with the inline file, and wherein the data of the at least one key-value pair includes one or more key-value pairs corresponding to data blocks storing data of the inline file.

### Claim 22 (depends on 19)

The method of claim 19, the inline file is converted to the container file when the number of entries in the container of the inline file exceeds a predetermined size, and the container file is converted to the inline file when the number of entries is reduced below the predetermined size.

### Claim 23 (depends on 13)

The method of claim 13, wherein the file is stored in a plurality of data storage devices, and the inode includes one or more key-value tuples including an identifier of the data storage device, an identifier of the container, and the key.

### Claim 24 (depends on 13)

The method of claim 13, further comprising: truncating or deleting the file in a single I/O operation within the key value file system without traversing layers of metadata corresponding to one or more directories within which the file is stored.
