Using extents of indirect blocks for file mapping of large files

US9542401B1 · US · B1

Patent metadata
FieldValue
Publication numberUS-9542401-B1
Application numberUS-201213436533-A
CountryUS
Kind codeB1
Filing dateMar 30, 2012
Priority dateMar 30, 2012
Publication dateJan 10, 2017
Grant dateJan 10, 2017

How to read this patent

A practical reading order for non-experts. Skip the full description unless you need deep technical detail.

  1. Title

    What the patent document calls the invention.

  2. Abstract

    A short plain-language summary of the technical disclosure.

  3. Assignees and inventors

    Who owns or filed the patent and who is credited as inventor.

  4. Key dates

    Filing, priority, publication, and grant dates set the timeline.

  5. First independent claim

    The legal scope of protection — read this for what is actually claimed.

  6. CPC / IPC classifications

    Technology tags used to group this patent with similar filings.

  7. Citations and related patents

    Prior art links and similar publications in this corpus.

Abstract

Official abstract text for this publication.

Large files in a file system are mapped by extents of contiguous indirect blocks in order to reduce the time for read or write access to the large files while allowing allocation of data blocks one at a time. The inode of a file includes an indication of whether file mapping metadata of the file includes either an extent of contiguous indirect blocks or a tree of blocks. In a preferred mapping scheme, an inode contains an array of block pointer entries, and each entry includes a flag indicating whether the block pointer is pointing to either an extent of indirect blocks or a tree of blocks. For sharing of data blocks between files, the block pointer fields of the indirect blocks each contain an ownership flag indicating whether the pointed-to block is shared or not.

First claim

Opening claim text (preview).

What is claimed is: 1. A method of operating a file server, the file server having data storage storing a file system, a data processor coupled to the data storage for access to files in the file system, and non-transitory computer readable storage medium coupled to the data processor and storing computer instructions, each of the files having an inode containing file attributes including an indication of whether file mapping metadata of said each of the files includes either an extent of contiguous indirect blocks or a tree of blocks, so that some of the files in the file system are mapped by one or more extents of contiguous indirect blocks, and some of the files in the file system are mapped by one or more trees of blocks, and the computer instructions, when executed by the data processor, perform a write operation to write data to a specified offset in a logical extent of a specified file in the file system by the steps of: (a) reading the inode of the specified file to obtain an indication of whether the file is mapped at the specified offset by either an extent of contiguous indirect blocks or a tree of blocks, and (b) using the indication of whether the file is mapped at the specified offset by either an extent of contiguous indirect blocks or a tree of blocks to obtain, from the file mapping metadata, a pointer to a data block for containing data at the specified offset of the specified file, and (c) using the pointer to write data to the data block for containing data at the specified offset in the logical extent of the specified file. 2. The method as claimed in claim 1 , wherein the indication of whether the file is mapped at the specified offset by either an extent of contiguous indirect blocks or a tree of blocks is a flag indicting whether the file is mapped either by one or more extents of contiguous indirect blocks or in accordance with a UNIX-based file mapping method. 3. The method as claimed in claim 1 , wherein the indication of whether the file is mapped at the specified offset by either an extent of contiguous indirect blocks or a tree of blocks is a flag in a block pointer field of the inode, and the flag indicates whether a block pointer in the block pointer field is pointing to either an extent of contiguous indirect blocks or to a tree of blocks. 4. The method as claimed in claim 1 , wherein the indication of whether the file is mapped at the specified offset by either an extent of contiguous indirect blocks or a tree of blocks indicates that the file is mapped at the specified offset by an extent of contiguous indirect blocks, and the contiguous indirect blocks include pointer fields each containing a block pointer and an associated ownership flag, and wherein step (b) further includes reading the ownership flag associated with the pointer to a data block for containing data at the specified offset of the specified file in order to verify that the specified file is an exclusive owner of the data block for containing data at the specified offset of the specified file. 5. The method as claimed in claim 1 , wherein the method further includes the computer instructions, when executed by the data processor, selecting a file mapping method for a new file by comparing a specified size for the new file to a threshold size, and selecting extent of contiguous indirect blocks for file mapping of the new file when the specified size is at least the threshold size. 6. The method as claimed in claim 5 , wherein the trees of blocks are trees of indirect blocks in accordance with a UNIX-based file mapping method, and the threshold size is the minimum size of a file using the UNIX-based file mapping method and having a triple indirect block. 7. The method as claimed in claim 5 , wherein the new file has an inode including a certain number of block pointers, and wherein the method further includes the computer instructions, when executed by the data processor, selecting an indirect block extent size for the new file by dividing the specified file size by the product of the certain number of block pointers and a number of data block pointers in each indirect block in the extent of contiguous indirect blocks for file mapping of the new file. 8. A method of operating a file server, the file server having data storage storing a file system, a data processor coupled to the data storage for access to files in the file system, and non-transitory computer readable storage medium coupled to the data processor and storing computer instructions, some of the files in the file system having file mapping metadata including an extent of contiguous indirect blocks, and some of the files in the file system having file mapping metadata including a tree of blocks, and the computer instructions, when executed by the data processor, perform a write operation to write data to a specified offset in a logical extent of a production file in the file system while maintaining a snapshot copy of the production file by the steps of: (a) accessing an indirect block in an extent of contiguous indirect blocks to read an ownership flag for the specified offset, and (b) in response to the ownership flag indicating that a data block for the specified offset is shared between the production file and the snapshot copy of the production file, writing data to a new data block for the production file, and changing the ownership flag to indicate that the data block for the specified offset is not shared between the production file and the snapshot copy of the production file, and extending a tree of blocks for file mapping of the data block that is no longer shared between the production file and the snapshot copy; wherein the extended tree of blocks includes some block pointers pointing to indirect blocks in the extent of contiguous indirect blocks, and other bock pointers pointing to indirect blocks in the extended tree of blocks, and each block pointer is in a respective block pointer field containing a respective flag indicating whether the block pointer in the block pointer field is pointing to either an indirect block in the extent of contiguous indirect blocks or a child block in the extended tree of blocks, and the flag is used to select either a first method for accessing a pointed-to indirect block in the extent of contiguous indirect blocks or a second method for accessing a pointed-to child block in the extended tree of blocks. 9. The method as claimed in claim 8 , wherein the extent of contiguous indirect blocks is pointed to by a pointer in an inode of the production file, and the tree of blocks is pointed to by a pointer in an inode of the snapshot copy of the production file. 10. The method as claimed in claim 9 , wherein the pointer in the inode of the production file has an associated flag in the inode of the production file, and the associated flag in the inode of the production file indicates that the pointer in the inode of the production file is pointing to an extent of contiguous indirect blocks, and wherein the pointer in the inode of the snapshot copy has an associated flag in the inode of the snapshot copy, and the associated flag in the inode of the snapshot copy indicates that the pointer in the inode of the snapshot copy is pointing to a tree of blocks. 11. A file server comprising: data storage containing a file system; a data processor coupled to the data storage for access to files in the file system; and non-transitory computer readable storage medium coupled to the data processor and storing computer instructions, and each of the files having an inode containing file attributes including an indication of whether file mapping metadata of said each of the files includes either an extent of contiguous indire

Assignees

Inventors

Classifications

  • G06F16/128Primary

    Details of file system snapshots on the file-level, e.g. snapshot creation, administration, deletion (error detection or correction of the data by redundancy in operations or in hardware G06F11/14, G06F11/16) · CPC title

  • Physics · mapped topic

Patent family

Related publications grouped by family.

External sources

Frequently asked questions

Answers are generated from the same data shown on this page.

What does patent US9542401B1 cover?
Large files in a file system are mapped by extents of contiguous indirect blocks in order to reduce the time for read or write access to the large files while allowing allocation of data blocks one at a time. The inode of a file includes an indication of whether file mapping metadata of the file includes either an extent of contiguous indirect blocks or a tree of blocks. In a preferred mapping …
Who is the assignee on this patent?
Veeraswamy Sairam, Bixby Peter C, Madany Peter W, and 1 more
What technology area does this patent fall under?
Primary CPC classification G06F16/128. Mapped technology areas include Physics.
When was this patent published?
Publication date Tue Jan 10 2017 00:00:00 GMT+0000 (Coordinated Universal Time) (B1). Legal status and post-grant events are not shown on this page.
What related patents are in patentsdb?
We list 8 related publications on this page (citations in our corpus or others sharing the same primary CPC).