主权项 |
1. A method of managing a file cache, the method comprising:
identifying a primary elimination policy associated with the file cache, the file cache having a number of available cache pages, the primary elimination policy dependent on whether the file cache is full; receiving a first filesystem mount command for a first filesystem, the first filesystem associated with a first set of file pages, the first filesystem mount command associating the first set of file pages with a secondary elimination policy, the first filesystem mount command specifying a time interval for the secondary elimination policy, the secondary elimination policy configured to use a Least Recently Used (LRU) algorithm, in conjunction with historical LRU data, to modify the time interval, the secondary elimination policy different from the primary elimination policy; storing the first set of file pages in the file cache, the first set of file pages including a first file page stored in a first cache page and further including a second file page stored in a second cache page; determining that the time interval has elapsed since the receiving the first filesystem mount command; removing, based on the determining, the first file page from the file cache according to the secondary elimination policy, the removing returning the first cache page to the number of available cache pages, wherein allowing the first file page to remain stored in the file cache does not violate the primary elimination policy; and not removing, based on the determining, the second file page from the file cache according to the secondary elimination policy. |