Skip to Main content Skip to Navigation
Reports

Swap Fairness for Thrashing Mitigation

François Goichon 1, 2, * Guillaume Salagnac 1, 2 Stéphane Frénot 1, 3, * 
* Corresponding author
2 SOCRATE - Software and Cognitive radio for telecommunications
Inria Grenoble - Rhône-Alpes, CITI - CITI Centre of Innovation in Telecommunications and Integration of services
3 DICE - Data on the Internet at the Core of the Economy
Inria Grenoble - Rhône-Alpes, CITI - CITI Centre of Innovation in Telecommunications and Integration of services
Abstract : The swap mechanism allows operating systems to manage more memory than the available RAM space, by temporarily storing unused memory pages on disk. However, disk transfers are way slower than normal RAM operations, and under memory pressure, the system may spend more time in retrieving and storing swapped pages than performing actual computation: this state is called memory thrashing. To reduce thrashing, several ideas were brought up to optimize page replacement algorithms and system-wide load. For instance, Linux currently implements the swap-token, a mechanism designed to immunize the memory pages of the heaviest process against swapping. Such a mechanism eliminates early thrashing peaks and improves general system performance if the process is to finish quickly. The swap-token may however be counterproductive when it is tricked into advantaging malicious or long-standing processes. This is particularily true in the context of shared hosting or virtualization, where multiple users run uncoordinated and selfish workloads. In this paper, we present an accounting layer that forces swap fairness among processes competing for main memory. It ensures that a process cannot perform longer swap operations than others, and delays the swap operations of processes abusing the swapping mechanism. With such a layer, we are able to significantly reduce the dispersion of execution times under memory pressure, and generally improve the performance of legit, memory-heavy processes running concurrently with abusive ones.
Document type :
Reports
Complete list of metadata

Cited literature [14 references]  Display  Hide  Download

https://hal.inria.fr/hal-00879084
Contributor : Guillaume Salagnac Connect in order to contact the contributor
Submitted on : Thursday, October 31, 2013 - 4:57:13 PM
Last modification on : Wednesday, March 9, 2022 - 3:29:47 PM
Long-term archiving on: : Saturday, February 1, 2014 - 4:30:44 AM

File

RR-8388.pdf
Files produced by the author(s)

Identifiers

  • HAL Id : hal-00879084, version 1

Collections

Citation

François Goichon, Guillaume Salagnac, Stéphane Frénot. Swap Fairness for Thrashing Mitigation. [Research Report] RR-8388, INRIA. 2013, pp.17. ⟨hal-00879084⟩

Share

Metrics

Record views

181

Files downloads

234