主权项 |
1. A method for automatically allocating space in a flash storage-based cache, the method comprising:
collecting, by a computer system, an input/output (I/O) trace log for each virtual machine in a plurality of virtual machines or each virtual disk in a plurality of virtual disks; determining, by the computer system, a cache utility model for each virtual machine or each virtual disk based on the I/O trace log for the virtual machine or the virtual disk, wherein the cache utility model defines an expected utility of allocating space in the flash storage-based cache to the virtual machine or the virtual disk over a range of different cache allocation sizes, and wherein determining the cache utility model comprises:
adding an output value of a spatial locality function for the virtual machine or the virtual disk to an output value of a temporal locality function for the virtual machine or the virtual disk to generate an intermediate sum, wherein the spatial locality function models a probability of a cache hit as a function of cache size, and wherein the temporal locality function models a probability of a cache hit as a function of time; andmultiplying the intermediate sum by:
a service time for a physical storage device associated with the virtual machine or the virtual disk; anda read/write ratio for the virtual machine or the virtual disk; calculating, by the computer system, target cache allocation sizes for the plurality of virtual machines or the plurality of virtual disks based on the cache utility models; and allocating, by the computer system, space in the flash storage-based cache based on the target cache allocation sizes. |