Method and system supporting per-file and per-block replication
First Claim
Patent Images
1. A method for writing data to a storage pool, comprising:
- receiving a first write operation to write a first data block to the storage pool, wherein the storage pool is organized in a hierarchical tree structure comprising data blocks and indirect blocks located hierarchically above the data blocks;
determining a first replication type for the first data block using a first replication policy associated with the first data block;
determining a first number of physical blocks required to write the first data block to the storage pool using a size of the first data block and the first replication type;
writing the first data block, in accordance with the first replication policy, to the storage pool by filling in the first number of physical blocks,wherein the first replication type for the first data block is stored in a block pointer of a first indirect block referencing the first data block in the hierarchical tree structure;
receiving a second write operation to write the first indirect block;
determining a second replication type for the first indirect block using the first replication policy associated with the indirect block;
determining a second number of physical blocks required to write the first indirect block using a size of the first indirect block and the second replication type;
writing the first indirect block, in accordance with the first replication policy by filling in the second number of physical blocks in the storage pool,wherein the second replication type and the size for the first indirect block is stored in a block pointer of a second indirect block referencing the first indirect block.
2 Assignments
0 Petitions
Accused Products
Abstract
A method for writing data to a storage pool, involving receiving a first write operation to write a first block to the storage pool, determining a first replication type for the first block using a first replication policy associated with the first block, determining a first number of physical blocks required to write the first block to the storage pool using a size of the first block and the first replication type, and writing the first block, in accordance with the first replication policy, to the storage pool by filling in the first number of physical blocks.
-
Citations
19 Claims
-
1. A method for writing data to a storage pool, comprising:
-
receiving a first write operation to write a first data block to the storage pool, wherein the storage pool is organized in a hierarchical tree structure comprising data blocks and indirect blocks located hierarchically above the data blocks; determining a first replication type for the first data block using a first replication policy associated with the first data block; determining a first number of physical blocks required to write the first data block to the storage pool using a size of the first data block and the first replication type; writing the first data block, in accordance with the first replication policy, to the storage pool by filling in the first number of physical blocks, wherein the first replication type for the first data block is stored in a block pointer of a first indirect block referencing the first data block in the hierarchical tree structure; receiving a second write operation to write the first indirect block; determining a second replication type for the first indirect block using the first replication policy associated with the indirect block; determining a second number of physical blocks required to write the first indirect block using a size of the first indirect block and the second replication type; writing the first indirect block, in accordance with the first replication policy by filling in the second number of physical blocks in the storage pool, wherein the second replication type and the size for the first indirect block is stored in a block pointer of a second indirect block referencing the first indirect block. - View Dependent Claims (2, 3, 4, 5, 18)
-
-
6. A system for writing data, comprising:
-
a storage pool comprising; a plurality of child blocks, wherein each of the plurality of child blocks comprises one selected from the group consisting of a data block and an indirect block, wherein each of the indirect blocks reference at least one of the plurality of child blocks and is hierarchically above the at least one of the plurality of child blocks referenced by each indirect block; a parent block referencing at least one child block that is hierarchically above the at least one child block; and a file system configured to; write a first block to the storage pool, wherein the first block is one of the plurality of child blocks, wherein the file system writes the first block to the storage pool using the following method steps; determining a first replication type for the first block using a first replication policy associated with the first block, determining a first number of physical blocks required to write the first block to the storage pool using a size of the first block and the first replication type, writing the first block, in accordance with the first replication policy, to the storage pool by filling in the first number of physical blocks, wherein the first replication type for the first data block is stored in a block pointer of a first indirect block referencing the first block; and write the first indirect block to the storage pool by; determining a second replication type for the first indirect block using the first replication policy associated with the first indirect block, determining a second number of physical blocks required to write the first indirect block using a size of the first indirect block and the second replication type, writing the first indirect block, in accordance with the first replication policy by filling in the second number of physical blocks in the storage pool, wherein the second replication type and the size for the first indirect block is stored in a block pointer of a second indirect block referencing the first indirect block. - View Dependent Claims (7, 8, 9, 10, 11, 19)
-
-
12. A computer readable medium comprising computer readable program code embodied therein for causing a computer system to:
-
determine a first replication type for the first block using a first replication policy associated with the first block, wherein the first block is a data block; determine a first number of physical blocks required to write the first block to the storage pool using a size of the first block and the first replication type; write the first block, in accordance with the first replication policy, to the storage pool by filling in the first number of physical blocks, wherein the storage pool is organized in a hierarchical tree structure comprising data blocks and indirect blocks located hierarchically above the data blocks, and wherein the first replication type for the first data block is stored in a block pointer of a first indirect block referencing the first data block in the hierarchical tree structure; determining a second replication type for the first indirect block using the first replication policy associated with the first indirect block; determining a second number of physical blocks required to write the first indirect block using a size of the first indirect block and the second replication type; and writing the first indirect block, in accordance with the first replication policy by filling in the second number of physical blocks in the storage pool, wherein the second replication type and the size of the first indirect block is stored in a block pointer of a second indirect block referencing the first indirect block. - View Dependent Claims (13, 14, 15, 16, 17)
-
Specification