Generally caching of block device data at a relatively lower latency device provides phenomenal performance for both read and write input/output (“I/O”) operations. As a read cache device, the data is stored in the cache device until it is replaced with the new data. Until then, the data is read from the cache device for subsequent read I/O operations directed to the same data block. As a write cache, the new data is written to the cache device, and the write I/O operation is informed completed. Later based on policy, the dirty data stored in the cache device is actually persisted to the underlying stable medium. In write-back mode, until the data is persisted to the underlying stable medium, the data in the cache device cannot be guaranteed to be available in future, for example, if the cache device is volatile across power cycle.
Using a solid state device (“SSD”) as the cache device helps solve the above problem. For example, using an SSD cache device helps to protect the data during power interruption. Since the SSD is a stable medium, the data availability across power cycle is always guaranteed. When compared to a hard disk drive, SSD devices have phenomenal read and write performance. However, various characteristics of the SSD devices may reduce the I/O performance over time.
The systems, devices and methods described herein use a plurality of SSDs as a caching medium for a data storage system. In particular, the systems, devices and methods use the SSDs in both a write-through cache mode and a write-back cache mode, for example, by splitting the SSDs into a plurality of cache regions and controlling each of the cache regions according to a different cache modes. Cache regions can include at least a portion of each of the SSDs. Additionally, the sizes of the cache regions are dynamically controlled based on the I/O load on the data storage system.
For example, one cache region of the SSDs controlled according to a write-through mode can be used a read cache. The data in this cache region can be striped across the SSDs. Another cache region of the SSDs controlled according to a write-back mode can be used a write cache. The data in this cache region can be mirrored across the SSDs. By mirroring the data in the cache region of the SSDs controlled according to the write-back mode, the data, which may not have been flushed or persisted to the data storage system, is protected in the event of failure of one of the SSDs.
An example computer-implemented method for using a plurality of SSDs as a caching medium in a data storage system can include splitting the SSDs into a plurality of cache regions, maintaining a first cache region of the SSDs as a write-through cache and maintaining a second cache region of the SSDs as a write-back cache. Additionally, data stored in the first cache region can be striped across the SSDs, and data stored in the second cache region can be mirrored across the SSDs. The computer-implemented method can also include dynamically adjusting a size of at least one of the first and second cache regions of the SSDs based on an input/output (“I/O”) load of the data storage system.
For example, to dynamically adjust a size of at least one of the first and second cache regions of the SSDs, the computer-implemented method can include expanding a size of the second cache region as the I/O load of the data storage system increases. Alternatively or additionally, the computer-implemented method can include reducing a size of the second cache region as the I/O load of the data storage system decreases.
Optionally, the computer-implemented method can include detecting failure of at least one of the SSDs, and upon detecting the failure, persisting one or more blocks of data stored in the second cache region of an operational SSD to the data storage system. The computer-implemented method can also include maintaining the second cache region of the operational SSD as a write-through cache.
Additionally, upon restoring or replacing the failed SSD, the computer-implemented method can optionally further include restoring the second cache region of the operational SSD to operation as a write-back cache.
Optionally, the computer-implemented method can include tracking valid data stored in the first cache region of the SSDs without maintaining a valid bitmap. For example, the computer-implemented method can include, for each read I/O operation that is not previously stored in the first cache region of the SSDs and that requests a data chunk with a size less than an SSD block size from the data storage system, reading a data block from the data storage system including the data chunk, where the data block has a size equal to the SSD block size. The computer-implemented method can then include storing the data block in the first cache region of the SSDs.
Optionally, the computer-implemented method can include tracking dirty data stored in the second cache region of the SSDs with a dirty bitmap for each SSD block of the second cache region of the SSDs, where each bit in the dirty bitmap corresponds to an SSD page size. For example, the computer-implemented method can include, for each write I/O operation directed to a data chunk with a size less than the SSD page size in the data storage system, reading a data block with a size equal to the SSD page size from the data storage system, where the data block includes the data chunk. The computer-implemented method can then include modifying the data block according to the write I/O operation and storing the modified data block in the second cache region of the SSDs.
Optionally, the computer-implemented method can include receiving a TRIM command from the data storage system in response to invalidation of one or more cache lines of the SSDs and wiping the invalidated cache lines from the first cache region of the SSDs. Alternatively or additionally, the computer-implemented method can include receiving a TRIM command from the data storage system in response to flushing one or more cache lines of the SSDs and wiping the flushed cache lines from the second cache region of the SSDs.
Optionally, the first cache region of the SSDs can be maintained as a RAID 0 array. Alternatively or additionally, the second cache region of the SSDs can be maintained as a RAID 1 array.
It should be understood that the above-described subject matter may also be implemented as a computer-controlled apparatus, a computer process, a computing system, or an article of manufacture, such as a computer-readable storage medium.
Other systems, methods, features and/or advantages will be or may become apparent to one with skill in the art upon examination of the following drawings and detailed description. It is intended that all such additional systems, methods, features and/or advantages be included within this description and be protected by the accompanying claims.
The components in the drawings are not necessarily to scale relative to each other. Like reference numerals designate corresponding parts throughout the several views.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art. Methods and materials similar or equivalent to those described herein can be used in the practice or testing of the present disclosure. As used in the specification, and in the appended claims, the singular forms “a,” “an,” “the” include plural referents unless the context clearly dictates otherwise. The term “comprising” and variations thereof as used herein is used synonymously with the term “including” and variations thereof and are open, non-limiting terms. While implementations will be described for using a plurality of SSDs as a caching medium for a data storage system, it will become evident to those skilled in the art that the implementations are not limited thereto.
Turning now to
According to implementations, the nodes within a cluster may be housed in a one rack space unit storing up to four hard disk drives. For instance, the node 2A is a one rack space computing system that includes four hard disk drives 4A-4D (collectively, disks 4). Alternatively, each node may be housed in a three rack space unit storing up to fifteen hard disk drives. For instance, the node 2E includes hard disk drives 4A-4L. Other types of enclosures may also be utilized that occupy more or fewer rack units and that store fewer or more hard disk drives. In this regard, it should be appreciated that the type of storage enclosure and number of hard disk drives utilized is not generally significant to the implementation of the embodiments described herein. Any type of storage enclosure and virtually any number of hard disk devices or other types of mass storage devices may be utilized.
As shown in
Data may be striped across the nodes of each storage cluster. For instance, the cluster 5A may stripe data across the storage nodes 2A, 2B, 2C and 2D. The cluster 5B may similarly stripe data across the storage nodes 2E, 2F and 2G. Striping data across nodes generally ensures that different I/O operations are fielded by different nodes, thereby utilizing all of the nodes simultaneously, and that the same I/O operation is not split between multiple nodes. Striping the data in this manner provides a boost to random I/O performance without decreasing sequential I/O performance.
According to embodiments, each storage server computer 2A-2G includes one or more network ports operatively connected to a network switch 6 using appropriate network cabling. It should be appreciated that, according to embodiments of the invention, Ethernet or Gigabit Ethernet may be utilized. However, it should also be appreciated that other types of suitable physical connections may be utilized to form a network of which each storage server computer 2A-2G is a part. Through the use of the network ports and other appropriate network cabling and equipment, each node within a cluster is communicatively connected to the other nodes within the cluster. Many different types and number of connections may be made between the nodes of each cluster. Furthermore, each of the storage server computers 2A-2G need not be connected to the same switch 6. The storage server computers 2A-2G can be interconnected by any type of network or communication links, such as a LAN, a WAN, a MAN, a fiber ring, a fiber star, wireless, optical, satellite, or any other network technology, topology, protocol, or combination thereof.
Each cluster 5A-5B is also connected to a network switch 6. The network switch 6 is connected to one or more client computers 8A-8N (also referred to herein as “initiators”). It should be appreciated that other types of networking topologies may be utilized to interconnect the clients and the clusters 5A-5B. It should also be appreciated that the initiators 8A-8N may be connected to the same local area network (LAN) as the clusters 5A-5B or may be connected to the clusters 5A-5B via a distributed wide area network, such as the Internet. An appropriate protocol, such as the Internet Small Computer Systems Interface (“iSCSI”) or Fiber Channel protocol may be utilized to enable the initiators 8A-8N to communicate with and utilize the various functions of the storage clusters 5A-5B over a wide area network such as the Internet. An appropriate protocol, such as iSCSI, Fiber Channel, or Serial Attached SCSI (“SAS”), is also used to enable the members of the storage cluster to communicate with each other. These two protocols need not be similar.
Examples of the disks 4 may include hard drives, spinning disks, stationary media, non-volatile memories, or optically scanned media; each, or in combination, employing magnetic, capacitive, optical, semiconductor, electrical, quantum, dynamic, static, or any other data storage technology. The disks 4 may use IDE, ATA, SATA, PATA, SCSI, USB, PCI, Firewire, or any other bus, link, connection, protocol, network, controller, or combination thereof for I/O transfers.
Referring now to
The motherboard 12 may also utilize a system board chipset 22 implementing one or more of the devices described herein. One or more hardware slots 24A-24B may also be provided for expandability, including the addition of a hardware RAID controller to the storage server computer 2. It should also be appreciate that, although not illustrated in
As described briefly above, the motherboard 12 utilizes a system bus to interconnect the various hardware components. The system bus utilized by the storage server computer 2 provides a two-way communication path for all components connected to it. The component that initiates a communication is referred to as a “master” component and the component to which the initial communication is sent is referred to as a “slave” component. A master component therefore issues an initial command to or requests information from a slave component. Each slave component is addressed, and thus communicatively accessible to the master component, using a particular slave address. Both master components and slave components are operable to transmit and receive communications over the system bus. Buses and the associated functionality of master-slave communications are well-known to those skilled in the art, and therefore not discussed in further detail herein.
As discussed briefly above, the system memory in the storage server computer 2 may include including a RAM 20 and a ROM 18. The ROM 18 may store a basic input/output system (“BIOS”) or Extensible Firmware Interface (“EFI”) compatible firmware that includes program code containing the basic routines that help to transfer information between elements within the storage server computer 2. As also described briefly above, the Ethernet controller 16 may be capable of connecting the local storage server computer 2 to the initiators 8A-8N via a network. Connections which may be made by the network adapter may include LAN or WAN connections. LAN and WAN networking environments are commonplace in offices, enterprise-wide computer networks, intranets, and the Internet. The CPUs 14A-14B utilized by the storage server computer 2 are standard central processing units that perform the arithmetic and logical operations necessary for the operation of the storage server computer 2. CPUs are well-known in the art, and therefore not described in further detail herein. A graphics adapter may or may not be utilized within the storage server computer 2 that enables the display of video data (i.e., text and/or graphics) on a display unit.
As shown in
The mass storage devices and their associated computer-readable media, provide non-volatile storage for the storage server computer 2. Although the description of computer-readable media contained herein refers to a mass storage device, such as a hard disk or CD-ROM drive, it should be appreciated by those skilled in the art that computer-readable media can be any available media that can be accessed by the local storage server. By way of example, and not limitation, computer-readable media may comprise computer storage media and communication media. Computer storage media includes volatile and non-volatile, removable and non-removable media implemented in any method or technology for storage of information such as computer-readable instructions, data structures, program modules or other data. Computer storage media includes, but is not limited to, RAM, ROM, EPROM, EEPROM, flash memory or other solid state memory technology, CD-ROM, DVD, or other optical storage, magnetic cassettes, magnetic tape, magnetic disk storage or other magnetic storage devices, or any other medium which can be used to store the desired information and which can be accessed by the computer.
Referring now to
The RAID layer 302 abstracts the organization of the RAID array 320A and presents a logical block-level interface to higher layers in the storage stack 300. For example, the RAID layer 302 can implement RAID level 5, where data is striped across the plurality of disks (e.g., disks 4A-4D) in the RAID array 320A. In a four disk array, a RAID stripe includes data block D1 stored on disk 1 (e.g., “4A”), data block D2 stored on disk 2 (e.g., “4B”), data block D3 stored on disk 3 (e.g., “4C”) and parity block PA stored on disk 4 (e.g., “4D”), for example. The parity block PA can be computed using XOR logic of data block D1, data block D2 and data block D3 (e.g., PA=D1⊕D2⊕D3). Additionally, the parity blocks in a RAID 5 array are distributed or staggered across the plurality of disks. Although RAID level 5 is discussed above, it should be understood that the RAID layer 302 can implement other RAID levels, such as RAID level 0, 1, 2, 3, 4 or 6.
The DVM layer 306 uses the block-level interface provided by the RAID layer 302 to manage the available storage capacity of the RAID array 320A and service I/O operations initiated by the initiators 8A-8N. The DVM layer 306 can implement a variety of storage management functions, such as volume virtualization, thin provisioning, snapshots, locking, data replication, etc. The DVM layer 306 can be implemented on the storage node 2 in software, hardware or a combination thereof. Volume virtualization provides the facility to create and manage multiple, logical volumes on the RAID array 320A, as well as expand a logical volume across multiple storage nodes within a storage cluster. Thin provisioning provides for the allocation of physical capacity of the RAID array 320A to logical volumes on an as-needed basis. For example, the available physical storage capacity of the RAID array 320A can be divided into a number of unique, equally-sized areas referred to as territories. Optionally, the size of a territory can be one terabyte (TB), a reduced size of 8 megabytes (MB) or any other territory size. Alternatively or additionally, the available physical storage capacity of the RAID array 320A can optionally be further subdivided into units referred to herein as provisions. The provisions can be unique, equally sized areas of the available physical capacity. For example, provisions may be 1 MB in size, a reduced size of 512 kilobytes (KB) or any other provision size. Optionally, a provision can be further subdivided into chunks. For example, the chunk size can be selected as 64 KB, a reduced size of 8 KB or any other chunk size. Snapshots provide functionality for creating and utilizing point-in-time snapshots of the contents of logical storage volumes. The locking functionality allows for synchronizing I/O operations within the storage node 2 or across nodes within the storage cluster. Data replication provides functionality for replication of data within the storage node 2 or across nodes within the storage cluster 2.
The cache layer 304 intercepts read and/or write I/O operations flowing between the RAID layer 302 and the DVM layer 306. The cache layer 304 is configured to read data from and/or write data to an SSD cache medium 330. Additionally, the cache layer 304 can be configured to perform the operations for using a plurality of SSDs as a caching medium for a data storage system (e.g., a data storage system including mass storage devices 320), which are discussed in detail below. The cache layer 304 can be implemented on the storage node 2 in software, hardware or a combination thereof. It should be understood that caching pairs the lower-latency SSD cache medium 330 with the mass storage devices 320. For example, when the SSD cache medium 330 is controlled according to a write-through cache mode, a new write I/O operation (e.g., directed to a data block) is performed synchronously in both the mass storage devices 320 and the SSD cache medium 330. The host (e.g., initiators 8A-8N of
Referring now to
The first cache region 335A can be maintained in the write-through cache mode, such that the first cache region 335A maintains read data blocks, for example. It should be understood that a cache layer (e.g., cache layer 304 of
The second cache region 335B can be maintained in the write-back cache mode, such that the second cache region 335B maintains dirty data blocks (e.g., data blocks not yet flushed to the mass storage devices), for example. It should be understood that a cache layer (e.g., cache layer 304 of
In addition, a size of at least one of the first cache region 335A and the second cache region 335B can be dynamically adjusted based data flow, such as the I/O load of the data storage system. It should be understood that the I/O load of the data storage system (e.g., storage system 100 of
In another aspect, it is possible to detect failure of at least one of the SSDs. It should be understood that a cache layer (e.g., cache layer 304 of
In yet another aspect, techniques for optimizing cache management are provided. A cache line is a fixed-size block of cache. Optionally, the fixed size of the cache line can be set to the size of an SSD block, for example, 64 KB. This disclosure contemplates that the cache line can have a size more or less than 64 KB, which is provided as an example. Accordingly, an SSD, which can have a capacity of 200 GB, can support a large number of cache lines (e.g., up to 3,276,800 cache lines with 64 KB block size or up to 26,214,400 cache lines with 8 KB block size). It should be understood that the capacity of the SSD can be more or less than 200 GB, which is provided only as an example. Cache line management can therefore require a large amount of in-core memory. It should be understood that each cache line can be managed using a bitmap such as a valid bitmap (e.g., for tracking or indicating which portions of the data in the cache are valid for data reading operations), a dirty bitmap (e.g. for tracking or indicating which portions of the data in the cache need to be flushed to the underlying stable medium and are valid for data reading operations) or other type of bitmap. Each bit in the bitmap can correspond to a different sector or portion of a cache line. For example, when each bit in a valid bitmap corresponds to a sector of a 64 KB cache line, a 16 byte valid bitmap is required.
As discussed above, because an SSD can support a large number of cache lines, it is desirable to provide a cache management mechanism that tracks portions of the cache line that are valid for data reading operations while reducing the in-core memory footprint required for cache management. It should be understood that this cache management mechanism can be used for tracking the cache lines in the first cache region 335A (e.g., the write-through cache) of the SSD cache medium 330 of
Alternatively or additionally, a dirty bitmap can be maintained, where each bit corresponds to the size of an SSD page, e.g., 4 KB. This disclosure contemplates that the size of an SSD page can be more or less than 4 KB, which is provided only as an example. In other words, each bit in a dirty bitmap can correspond to 4 KB of the cache line. For a 64 KB cache line, the dirty bitmap would only be 16 bits. As discussed above, the dirty bitmap can be used for tracking or indicating which portions of the data in the dirty bitmap need to be flushed to the underlying stable medium and are valid for data reading operations. It should be understood that this cache management mechanism can be used for tracking the cache lines in the second cache region 335B (e.g., the write-back cache) of the SSD cache medium 330 of
In another aspect, techniques for performing SSD TRIM commands efficiently are described. In order to extend the lifetime of an SSD, it is desirable to distribute approximately the same number of write operations to every SSD block or cell. To achieve this, wear leveling can be performed inside the SSD. Performing a wear leveling algorithm inside the SSD can ensure that every block is written to approximately an equal number of times as compared to all other SSD blocks, which distributes the write operations approximately equally. In addition, unlike a hard disk drive, overwrites of a logical block in an SSD use new physical locations in the SSD instead of the same physical locations. To erase abandoned SSD pages (e.g., logical blocks in the SSD that have been overwritten), valid pages in the SSD are moved to a new location and then the abandoned pages are erased to accommodate new writes. This process is known in the art as garbage collection. It should be understood that both wear leveling and garbage collection increase the number of times data is written in the SSD, which is known in the art as write amplification, e.g.,
When using an SSD, it is desirable that the SSD is informed about stale or unused data maintained by the host (e.g., initiators 8A-8N of
Referring now to
Referring now to
Referring now to
Referring now to
Although the subject matter has been described in language specific to structural features and/or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.
This application claims the benefit of U.S. Provisional Patent Application No. 62/157,522, filed on May 6, 2015, entitled “SYSTEMS, DEVICES AND METHODS USING SOLID STATE DEVICES AS A CACHING MEDIUM WITH ADAPTIVE STRIPING AND MIRRORING REGIONS,” the disclosure of which is expressly incorporated herein by reference in its entirety.
Number | Name | Date | Kind |
---|---|---|---|
4989131 | Stone | Jan 1991 | A |
5499337 | Gordon | Mar 1996 | A |
5680579 | Young et al. | Oct 1997 | A |
5732240 | Caccavale | Mar 1998 | A |
5799324 | McNutt et al. | Aug 1998 | A |
5802561 | Fava | Sep 1998 | A |
5892937 | Caccavale | Apr 1999 | A |
6175900 | Forin et al. | Jan 2001 | B1 |
6490578 | Burkhard | Dec 2002 | B1 |
6523102 | Dye et al. | Feb 2003 | B1 |
6553511 | DeKoning et al. | Apr 2003 | B1 |
6606629 | DeKoning et al. | Aug 2003 | B1 |
6651153 | Orfali | Nov 2003 | B1 |
7177850 | Argenton et al. | Feb 2007 | B2 |
7257684 | Sinha et al. | Aug 2007 | B1 |
8219724 | Caruso et al. | Jul 2012 | B1 |
8572736 | Lin | Oct 2013 | B2 |
8631472 | Martin et al. | Jan 2014 | B1 |
8775741 | de la Iglesia | Jul 2014 | B1 |
9256272 | Hasegawa et al. | Feb 2016 | B2 |
9501420 | Susarla et al. | Nov 2016 | B2 |
9632932 | Sutardja et al. | Apr 2017 | B1 |
9798754 | Shilane et al. | Oct 2017 | B1 |
20020091965 | Moshayedi | Jul 2002 | A1 |
20040148471 | Wallin et al. | Jul 2004 | A1 |
20040260883 | Wallin et al. | Dec 2004 | A1 |
20050278486 | Trika | Dec 2005 | A1 |
20070006013 | Moshayedi et al. | Jan 2007 | A1 |
20070260811 | Merry et al. | Nov 2007 | A1 |
20090204853 | Diggs et al. | Aug 2009 | A1 |
20090210620 | Jibbe | Aug 2009 | A1 |
20090228646 | Edwards et al. | Sep 2009 | A1 |
20100070703 | Sarkar | Mar 2010 | A1 |
20100082879 | McKean et al. | Apr 2010 | A1 |
20100088459 | Arya et al. | Apr 2010 | A1 |
20100100664 | Shimozono | Apr 2010 | A1 |
20100122200 | Merry et al. | May 2010 | A1 |
20100235670 | Keller et al. | Sep 2010 | A1 |
20100250842 | Deshpande et al. | Sep 2010 | A1 |
20100299547 | Saika | Nov 2010 | A1 |
20110029686 | Sethi et al. | Feb 2011 | A1 |
20110087833 | Jones | Apr 2011 | A1 |
20110173378 | Filor et al. | Jul 2011 | A1 |
20110238922 | Hooker et al. | Sep 2011 | A1 |
20120072698 | Unesaki et al. | Mar 2012 | A1 |
20120185647 | Dawkins | Jul 2012 | A1 |
20120221774 | Atkisson et al. | Aug 2012 | A1 |
20130038961 | Song | Feb 2013 | A1 |
20130122856 | Kalmbach et al. | May 2013 | A1 |
20130145223 | Okada et al. | Jun 2013 | A1 |
20130185511 | Sassone | Jul 2013 | A1 |
20130285835 | Kim et al. | Oct 2013 | A1 |
20130318603 | Merza | Nov 2013 | A1 |
20140050002 | Sun | Feb 2014 | A1 |
20140052942 | Satou | Feb 2014 | A1 |
20140089558 | Baderdinni | Mar 2014 | A1 |
20140095547 | Guo et al. | Apr 2014 | A1 |
20140129758 | Okada | May 2014 | A1 |
20140143505 | Sim | May 2014 | A1 |
20140201442 | Rajasekaran et al. | Jul 2014 | A1 |
20140325166 | Iyigun et al. | Oct 2014 | A1 |
20150026403 | Ish et al. | Jan 2015 | A1 |
20150095567 | Noda | Apr 2015 | A1 |
20150206558 | Ni et al. | Jul 2015 | A1 |
20150278127 | Takakura | Oct 2015 | A1 |
20150370715 | Samanta | Dec 2015 | A1 |
20160004459 | Oohira | Jan 2016 | A1 |
20160011782 | Kurotsuchi et al. | Jan 2016 | A1 |
20160170639 | Velayudhan et al. | Jun 2016 | A1 |
20160276015 | Bains et al. | Sep 2016 | A1 |
20170359371 | Merza | Dec 2017 | A1 |
Entry |
---|
Co-pending U.S. Appl. No. 15/145,099, filed May 3, 2016. |
Co-pending U.S. Appl. No. 15/145,111, filed May 3, 2016. |
Co-pending U.S. Appl. No. 15/145,874, filed May 4, 2016. |
Co-pending U.S. Appl. No. 15/145,878, filed May 4, 2016. |
Co-pending U.S. Appl. No. 15/145,883, filed May 4, 2016. |
Number | Date | Country | |
---|---|---|---|
62157522 | May 2015 | US |