What happens when RAM + Swap runs out?

harmonyp

Member
Nov 26, 2020
196
4
23
46
So I have noticed that when swap starts (currently set to swappiness 0) the swap that is taken actually reduces the current RSS memory a virtual machine has. For example if I allocated a virtual machine 10GB of RAM and it peaked at 10GB of RAM the reserved memory for that running machine would remain at 100% until either swap activates or I turn the machine off/on.

What happens when both RAM and swap reaches 100%? Does the RSS memory get taken away from a virtual machine or does some of them virtual machines just get killed from being OOM?

Code:
/proc/sys/vm/overcommit_memory
is set to 1
 
If you run out of RAM the OOM kicks in and will kill VMs. Overcommiting memory isn't really working, even if you use ballooning.
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!