Patent ID: 8903877

Claim:
A file server comprising: data storage storing a file system; and a data processor coupled to the data storage for access to files in the file system, the files being constructed of an inode for each of the files, indirect blocks, and allocation units of file system data blocks, each of the allocation units having one of the file system data blocks or a plurality of the file system data blocks having contiguous file system block numbers; non-transitory computer readable storage medium coupled to the data processor and storing computer instructions including a file system manager program for managing the file system in the data storage; wherein each file in the file system has a respective allocation unit size attribute specifying an allocation unit size of each and every allocation unit in said each file, and the files in the file system have allocation units of different allocation unit sizes, wherein a set of contiguous file system blocks are allocated as an allocation unit for each file in the file system based on the allocation unit size for said each file, wherein an indirect block of each file includes a set of allocation unit pointer fields, each allocation unit pointer field pointing to an allocation unit of said each file; wherein the computer instructions, when executed by the data processor, perform a read access to a specified offset in a specified file in the file system by the steps of: (a) reading attributes of the specified file including the allocation unit size of the specified file, the allocation unit size of the specified file being at least two file system data blocks; (b) using the allocation unit size of the specified file and the specified offset of the specified file in a block mapping procedure to find an allocation unit pointer field in the inode of the specified file or in an indirect block of the specified file, the allocation unit pointer field being mapped to the specified offset in the specified file, the allocation unit pointer field is determined by dividing the specified offset of the specified file by the allocation unit size of the specified file; and (c) reading an allocation unit pointer from the allocation unit pointer field found by the block mapping procedure, and using the allocation unit pointer to perform a read access to an allocation unit of the data storage in order to perform the read access to the specified offset in the specified file, wherein a file system block for performing the read access is determined from the allocation unit pointer by using a result of dividing the specified offset of the specified file by the allocation unit size of the specified file.