Method and system for providing substantially constant-time execution of a copy operation
First Claim
1. A method comprising:
- generating a snapshot of at least a portion of a data set managed by a storage server;
performing a copy operation in the storage server to generate a copy of the data set separate from the snapshot, wherein performing the copy operation comprises defining a set of block locations containing null references, and replacing the contents of individual block locations with references to individual data segments;
during the copy operation to generate the copy of the data set separate from the snapshot, receiving from a requester a first read request directed to the copy of the data set that the copy operation is to generate; and
providing data from the snapshot to the requester by the storage server, in response to the first read request.
2 Assignments
0 Petitions
Accused Products
Abstract
A system and method for providing a substantially constant-time copy operation for file system objects managed by a network storage server begins by generating a new file based on metadata in a source file. The system then generates a snapshot of the source file or the logical volume in which the source file resides. The system then copies each of the indirect blocks of the source file to a corresponding location in the destination file. During the copy process, a modified set of file system operations can be executed on the destination metadata container. In response to a read request directed to a target block in the destination file, the system determines if target block has been copied. If the block has not been copied, the system provides a data segment from the corresponding data block in the snapshot. Write requests are processed by generating a new data block and adding a reference to the new data block to the target location in the destination metadata container. During the copy process, the system checks each block reference before copying to determine if the block reference has been modified by a write operation. If the block was modified, the system skips copying that particular block reference. The system provides additional operations to execute truncate and append operations during the copy process.
-
Citations
30 Claims
-
1. A method comprising:
-
generating a snapshot of at least a portion of a data set managed by a storage server; performing a copy operation in the storage server to generate a copy of the data set separate from the snapshot, wherein performing the copy operation comprises defining a set of block locations containing null references, and replacing the contents of individual block locations with references to individual data segments; during the copy operation to generate the copy of the data set separate from the snapshot, receiving from a requester a first read request directed to the copy of the data set that the copy operation is to generate; and providing data from the snapshot to the requester by the storage server, in response to the first read request. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. A system comprising:
-
a memory; a processor coupled to the memory to execute instructions stored in the memory; a copy component configured to execute a copy operation based on the instructions stored in the memory to copy a plurality of blocks from a source metadata container to a destination metadata container, wherein the copy operation comprises defining a set of block locations containing null references, and replacing the contents of individual block locations with references to individual data segments; and a write component configured to execute a modification operation based on the instructions stored in the memory to modify a target block of the destination metadata container during the copy operation in response to a write request to modify the target block, wherein the modification operation comprises generating a new data segment based on the write request; and
replacing an individual null reference at the block location with a reference to the new data segment,wherein the copy component is configured to skip copying an individual block of the plurality of blocks that corresponds to the target block of the destination metadata container in response to the write request to modify the target block. - View Dependent Claims (12, 13, 14, 15, 16)
-
-
17. A method comprising:
-
performing a copy operation in a storage server to generate a copy of a data set managed by the storage server;
wherein performing the copy operation comprises defining a set of block locations containing null references, and replacing the contents of individual block locations with references to individual data segments; andduring the copy operation, modifying a portion of the copy of the data set based on a write request to modify the portion of the copy of the data set;
wherein modifying the portion of the copy of the data set comprises generating a new data segment based on the write request; and
replacing an individual null reference at the block location with a reference to the new data segment;wherein copying the data set includes; for a portion of the data set, determining whether a corresponding location in the copy of the data set was modified by the write request to modify the portion of the copy of the data set; and based on the determination, selectively skipping the copying of the portion of the data set in response to the write request to modify the portion of the copy of the data set. - View Dependent Claims (18, 19, 20, 21, 22)
-
-
23. A system comprising:
-
a memory; a processor coupled to the memory to execute instructions stored in the memory; a snapshot generator configured to execute a snapshot operation based on the instructions stored in the memory to generate a snapshot of a file system object having a source inode; a copy component configured to execute a copy operation based on the instructions stored in the memory to copy a plurality of data block references separate from the snapshot from the source inode to a destination inode;
wherein the copy operation comprises defining a set of block locations containing null references, and replacing the contents of individual block locations with references to individual data segments; anda read component configured to execute a read operation based on the instructions stored in the memory to respond to a read request directed to the plurality of data block references in the destination inode during the copy by providing a data segment from the snapshot corresponding to a target read location of the read request in the destination inode. - View Dependent Claims (24, 25, 26, 27, 28, 29, 30)
-
Specification