Write-back storage cache based on fast persistent memory
First Claim
Patent Images
1. A method, comprising steps of:
- a storage device receiving from a storage device client a data block write request to write a data block to said storage device;
wherein said storage device comprises one or more primary storage devices and one or more flash cache devices comprising non-volatile memory;
selecting a victim cache copy stored in said one or more flash cache devices to which to replace with said data block;
wherein-persistent cache metadata stored in said one or more flash cache devices;
maps a cache block address of said victim to a primary block address of the data block of which said victim is a cache copy;
contains a dirty flag that specifies that said victim is clean;
associates with said victim a block check value;
overwriting said victim in said flash cache device with contents of said data block;
encountering a storage device failure before updating said persistent cache metadata to reflect said overwriting of said victim; and
said storage device performing recovery, wherein performing recovery includes;
generating a block check value based on content of the data block stored in place of said victim,making a comparison between (1) the block check value generated based on content of the data block stored in place of said victim and (2) the block check value associated with said victim by said persistent cache metadata, andbased on the comparison, detecting that the persistent cache metadata contains a false dirty flag that specifies that the data block stored in place of said victim is clean.
1 Assignment
0 Petitions
Accused Products
Abstract
A storage device uses non-volatile memory devices for caching. The storage device operates in a mode referred to herein as write-back mode. In write-back mode, a storage device responds to a request to write data by persistently writing the data to a cache in a non-volatile memory device and acknowledges to the requestor that the data is written persistently in the storage device. The acknowledgement is sent without necessarily having written the data that was requested to be written to primary storage. Instead, the data is written to primary storage later.
-
Citations
4 Claims
-
1. A method, comprising steps of:
-
a storage device receiving from a storage device client a data block write request to write a data block to said storage device; wherein said storage device comprises one or more primary storage devices and one or more flash cache devices comprising non-volatile memory; selecting a victim cache copy stored in said one or more flash cache devices to which to replace with said data block; wherein-persistent cache metadata stored in said one or more flash cache devices; maps a cache block address of said victim to a primary block address of the data block of which said victim is a cache copy; contains a dirty flag that specifies that said victim is clean; associates with said victim a block check value; overwriting said victim in said flash cache device with contents of said data block; encountering a storage device failure before updating said persistent cache metadata to reflect said overwriting of said victim; and said storage device performing recovery, wherein performing recovery includes; generating a block check value based on content of the data block stored in place of said victim, making a comparison between (1) the block check value generated based on content of the data block stored in place of said victim and (2) the block check value associated with said victim by said persistent cache metadata, and based on the comparison, detecting that the persistent cache metadata contains a false dirty flag that specifies that the data block stored in place of said victim is clean. - View Dependent Claims (2)
-
-
3. One or more non-transitory storage media storing sequences of instructions, wherein said sequences of instructions, when executed by one or more processors, cause:
-
a storage device receiving from a storage device client a data block write request to write a data block to said storage device; wherein said storage device comprises one or more primary storage devices and one or more flash cache devices comprising non-volatile memory; selecting a victim cache copy stored in said one or more flash cache devices to which to replace with said data block; wherein-persistent cache metadata stored in said one or more flash cache devices; maps a cache block address of said victim to a primary block address of the data block of which said victim is a cache copy; contains a dirty flag that specifies that said victim is clean; associates with said victim a block check value; overwriting said victim in said flash cache device with contents of said data block; encountering a storage device failure before updating said persistent cache metadata to reflect said overwriting of said victim; and said storage device performing recovery, wherein performing recovery includes; generating a block check value based on content of the data block stored in place of said victim, making a comparison between (1) the block check value generated based on content of the data block stored in place of said victim and (2) the block check value associated with said victim by said persistent cache metadata, and based on the comparison, detecting that the persistent cache metadata contains a false dirty flag that specifies that the data block stored in place of said victim is clean. - View Dependent Claims (4)
-
Specification