# US 10,503,695 B2 · Method and apparatus for file system

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

- Number: US 10,503,695 B2
- Document ID: US10503695B2
- Status: Granted
- Kind: B2
- Application number: 14/495,404
- Filed: 2014-09-24
- Published: 2015-04-02
- Granted: 2019-12-10
- Earliest claimed: 2013-09-27
- Assignees: EMC IP Holding Company LLC
- Applicants: EMC Corporation
- Inventors: Jia Zhai; Yingchao Zhou; Wengang Wang; Jun Guo; Sen Zhang
- Web page: https://patentgrep.com/patent/US10503695B2

## CPC

- 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/0608: {Saving storage space on storage systems}
- G06F 3/0665: {at area level, e.g. provisioning of virtual or logical volumes}
- G06F 3/0683: {Plurality of storage devices}
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)

## Abstract

The present disclosure relates to a method and apparatus for a file system, the file system comprising at least a first logical storage area and a second logical storage area, a logical block of the first logical storage area and that of the second logical storage area being different in size, and in response to a request for creating a file, selecting a logical storage area for storing the file from the at least first logical storage area and second logical storage area; and storing the file in the selected logical storage area. According to the above various embodiments of the present invention, a direct and effective way may be used to support variable-length block size in a file system, without increasing metadata and positioning overheads.

## Claims

### Claim 1

A method for a file system, wherein the file system comprises at least a first logical storage area and a second logical storage area, a logical block of the first logical storage area being different in size from that of a logical block of the second logical storage area, the method comprising:
in response to a request for creating a file, selecting, by a policy engine, a logical storage area for storing the file from the at least first logical storage area and second logical storage area, wherein selection of a logical block size of the selected logical storage area is controlled by configuring the policy engine, wherein variable-length block size is supported in the file system through use of the configurable policy engine;
storing the logical block size of the selected logical storage area in an inode associated with the file, the inode recording the logical block size for the entire file, including all logical blocks of the file; and
storing the file in the selected logical storage area.

### Claim 2 (depends on 1)

The method according to claim 1, wherein a storage area for storing the file is selected from the at least first logical storage area and second logical storage area based on a pre-defined parameter.

### Claim 3 (depends on 2)

The method according to claim 2, wherein the pre-defined parameter is a file type and/or a file size.

### Claim 4 (depends on 3)

The method according to claim 3, wherein the file types comprise at least one or more of video files, audio files, image files, content files, information files, data files and text files.

### Claim 5 (depends on 1)

The method according to claim 1, wherein storing the file in the selected logical storage area further comprises:
selecting a location for storing the file in the selected logical storage area;
allocating a physical storage block with a corresponding size from a physical storage pool; and
writing the file contents into the physical storage block.

### Claim 6 (depends on 5)

The method according to claim 5, wherein the file system further comprises a mapping table for recording a relationship between the logical storage area and the physical storage block.

### Claim 7 (depends on 5)

The method as claimed in claim 5, wherein storing the file in the selected logical storage area further comprises:
updating a block map table based on the relationship between the logical storage area and the physical storage block.

### Claim 8 (depends on 5)

The method as claimed in claim 5, wherein storing the file in the selected logical storage area further comprises:
updating a block map table based on the relationship between the logical storage area and the physical storage block.

### Claim 9

A system, comprising:
a data storage system; and
computer-executable program logic encoded in memory of one or more computers enabled to implement a file system comprising at least a first logical storage area and a second logical storage area, wherein a logical block of the first logical storage area being different in size from a logical block of the second logical storage area, wherein the computer-executable program logic is configured for the execution of:
in response to a request for creating a file, selecting, by a policy engine, a logical storage area for storing the file from the at least first logical storage area and second logical storage area, wherein selection of a logical block size of the selected logical storage area is controlled by configuring the policy engine, wherein variable-length block size is supported in the file system through use of the configurable policy engine;
storing the logical block size of the selected logical storage area in an inode associated with the file, the inode recording the logical block size for the entire file, including all logical blocks of the file; and
storing the file in the selected logical storage area.

### Claim 10 (depends on 9)

The system according to claim 9, wherein the computer-executable program logic is configured for the execution of:
selecting a storage area for storing the file from the at least first logical storage area and second logical storage area based on a pre-defined parameter, and wherein the predefined parameter is a file type and/or a file size, and wherein the file type comprise at least one or more of video files, audio files, image files, content files, information files, data files and text files.

### Claim 11 (depends on 9)

The system according to claim 9, wherein the computer-executable program logic is configured for the execution of:
selecting a location for storing the file in the selected logical storage area;
allocating a physical storage block with a corresponding size from a physical storage pool; and
writing the file contents into the physical storage block.

### Claim 12 (depends on 11)

The system according to claim 11, wherein the file system further comprises a mapping table for recording a relationship between the logical storage area and the physical storage block.

### Claim 13 (depends on 12)

The system according to claim 12, wherein storing the file in the selected logical storage area further comprises:
updating a block map table based on the correspondence relationship between the logical storage area and the physical storage block.

### Claim 14

A computer program product for implementing a file system on a data storage system, wherein the file system comprises at least a first logical storage area and a second logical storage area, a logical block of the first logical storage area being different in size from that of a logical block of the second logical storage area, the computer program product comprising:
a non-transitory computer readable medium encoded with computer-executable code, the code configured to enable the execution of:
in response to a request for creating a file, selecting, by a policy engine, a logical storage area for storing the file from the at least first logical storage area and second logical storage area, wherein selection of a logical block size of the selected logical storage area is controlled by configuring the policy engine, wherein variable-length block size is supported in the file system through use of the configurable policy engine;
storing the logical block size of the selected logical storage area in an inode associated with the file, the inode recording the logical block size for the entire file, including all logical blocks of the file; and
storing the file in the selected logical storage area.

### Claim 15 (depends on 14)

The computer program product of claim 14, wherein the code is further configured to enable the execution of:
selecting a storage area for storing the file from the at least first logical storage area and second logical storage area based on a pre-defined parameter.

### Claim 16 (depends on 15)

The computer program product of claim 15, wherein the pre-defined parameter is a file type and/or a file size.

### Claim 17 (depends on 16)

The computer program product of claim 16, wherein the file types comprise at least one or more of video files, audio files, image files, content files, information files, data files and text files.

### Claim 18 (depends on 14)

The computer program product of claim 14, wherein storing the file in the selected logical storage area further comprises:
selecting a location for storing the file in the selected logical storage area;
allocating a physical storage block with a corresponding size from a physical storage pool; and
writing the file contents into the physical storage block.

### Claim 19 (depends on 18)

The computer program product of claim 18, wherein the file system further comprises a mapping table for recording a relationship between the logical storage area and the physical storage block.
