Hash-based snapshots
First Claim
1. A system configured to provide hash-based snapshot services for a virtual storage, the system comprising a processor and memory coupled with the processor, wherein the memory is configured to provide the processor with instructions formaintaining, by a hash-based snapshot module executing on the system, a file system of the virtual storage, wherein the file system is associated with a plurality of data blocks, the virtual storage is supported by a hash-storage having a hash base-file and a hash-database, the hash-database is configured for storing the plurality of data blocks, and the hash base-file includes hash codes generated by applying a hash function to the plurality of data blocks;
- accessing, by the hash-based snapshot module, the file system using hash codes contained in the hash base-file to identify corresponding data blocks stored in the hash-database;
creating, by the hash-based snapshot module, a first snapshot for the file system, wherein the first snapshot is associated with a first hash snapshot file copied based on the hash base-file wherein the first hash snapshot file contains a first plurality of hash entities each of which is associated with a corresponding one of the plurality of data blocks;
accessing, by the hash-based snapshot module, the first snapshot using hash codes contained in the first hash snapshot file to identify corresponding data blocks stored in the hash-database;
in response to a read request to retrieve a first data block from the first snapshot locating a first hash entity from the first plurality of hash entities based on the first data block'"'"'s address and locating the first data block in the hash-database based on a first hash code and a first collision count retrieved from the first hash entity; and
in response to an update request to write a second data block to the first snapshot, locating a second hash entity from the first plurality of hash entities based on the second data block'"'"'s address, generating a second hash code for the second hash entity by applying the hash function to the second data block'"'"'s data, generating a second collision count for the second hash entity based on a number of data blocks stored in the hash-database having corresponding hash codes that are identical to the second hash code and storing the second data block along with the second hash code and the second collision count in the hash-database.
2 Assignments
0 Petitions
Accused Products
Abstract
Methods and systems configured to provide hash-based snapshot services for a virtual storage are provided. The system includes a processor and memory coupled with the processor. The memory is configured to provide the processor with instructions for maintaining, by a hash-based snapshot module executing on the system, a file system of the virtual storage. The file system is associated with a plurality of data blocks. The virtual storage is supported by a hash-storage having a hash base-file and a hash-database. The hash-database is configured for storing the plurality of data blocks. And the hash base-file includes hash codes generated by applying a hash function to the plurality of data blocks. The memory is further configured to provide the processor with instructions for accessing, by the hash-based snapshot module, the file system using hash codes contained in the hash base-file to identify data blocks stored in the hash-database; creating, by the hash-based snapshot module, a first snapshot for the file system, wherein the first snapshot is associated with a first hash snapshot file copied based on the hash base-file; and accessing, by the hash-based snapshot module, the first snapshot using hash codes contained in the first hash snapshot file to identify data blocks stored in the hash-database.
-
Citations
15 Claims
-
1. A system configured to provide hash-based snapshot services for a virtual storage, the system comprising a processor and memory coupled with the processor, wherein the memory is configured to provide the processor with instructions for
maintaining, by a hash-based snapshot module executing on the system, a file system of the virtual storage, wherein the file system is associated with a plurality of data blocks, the virtual storage is supported by a hash-storage having a hash base-file and a hash-database, the hash-database is configured for storing the plurality of data blocks, and the hash base-file includes hash codes generated by applying a hash function to the plurality of data blocks; -
accessing, by the hash-based snapshot module, the file system using hash codes contained in the hash base-file to identify corresponding data blocks stored in the hash-database; creating, by the hash-based snapshot module, a first snapshot for the file system, wherein the first snapshot is associated with a first hash snapshot file copied based on the hash base-file wherein the first hash snapshot file contains a first plurality of hash entities each of which is associated with a corresponding one of the plurality of data blocks; accessing, by the hash-based snapshot module, the first snapshot using hash codes contained in the first hash snapshot file to identify corresponding data blocks stored in the hash-database; in response to a read request to retrieve a first data block from the first snapshot locating a first hash entity from the first plurality of hash entities based on the first data block'"'"'s address and locating the first data block in the hash-database based on a first hash code and a first collision count retrieved from the first hash entity; and in response to an update request to write a second data block to the first snapshot, locating a second hash entity from the first plurality of hash entities based on the second data block'"'"'s address, generating a second hash code for the second hash entity by applying the hash function to the second data block'"'"'s data, generating a second collision count for the second hash entity based on a number of data blocks stored in the hash-database having corresponding hash codes that are identical to the second hash code and storing the second data block along with the second hash code and the second collision count in the hash-database. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8)
-
-
9. A system configured to provide hash-based snapshot services for a virtual storage, the system comprising a processor and memory coupled with the processor, and the system further comprising:
-
a hash-based snapshot module coupled with the processor and the memory, wherein the hash-based snapshot module is configured to maintain a file system located in the virtual storage, and the file system is associated with a plurality of data blocks; and a hash-storage coupled with the hash-based snapshot module and configured for storing a hash base-file and a hash-database, wherein the hash-database is configured for storing the plurality of data blocks, and the hash base-file includes hash codes generated by applying a hash function to the plurality of data blocks, wherein the hash-based snapshot module is further configured to access the file system using hash codes contained in the hash base-file to identify corresponding data blocks stored in the hash-database, create a snapshot for the file system by copying the hash base-file to a hash snapshot file wherein the hash snapshot file is configured with a plurality of hash entities each of which is associated with a corresponding one of the plurality of data blocks, store the hash snapshot file to the hash-storage wherein the hash-storage is configured with a plurality of hash data blocks and access the snapshot using hash codes contained in the hash snapshot file to identify corresponding data blocks stored in the hash-database, wherein, in response to a read request to retrieve a first data block from the snapshot, the hash-based snapshot module is further configured to locate a first hash entity from the plurality of hash entities based on the first data block'"'"'s address, locate a first hash data block from the plurality of hash data blocks based on a first hash code and a first collision count stored in the first hash entity, wherein the first hash code is generated by applying the hash function to the first data block'"'"'s data, and retrieve the first data block from the first hash data block. - View Dependent Claims (10, 11, 12)
-
-
13. A non-transitory computer-readable storage medium, containing a set of instructions which, when executed by a processor, cause the processor to perform a method for providing hash-based snapshot services for a virtual storage, the method comprising:
-
maintaining, by a hash-based snapshot module executing on the system, a file system located in the virtual storage, wherein the file system is associated with a plurality of data blocks, the virtual storage is supported by a hash-storage having a hash base-file and a hash-database, the hash-database is configured for storing the plurality of data blocks, and the hash base-file is configured for accessing the stored plurality of data blocks in the hash-database based on hash codes generated by applying a hash function to the plurality of data blocks; creating, by the hash-based snapshot module, a first snapshot for the file system by copying the hash base-file to a first hash snapshot file and storing the first hash snapshot file to the hash-storage; accessing, by the hash-based snapshot module, the first snapshot via the first hash snapshot file; creating a second snapshot based on the first snapshot by copying the first hash snapshot file to a second hash snapshot file and storing the second hash snapshot file to the hash-storage; and accessing the second snapshot via the second hash snapshot file. - View Dependent Claims (14, 15)
-
Specification