RAM and SWAP for OpenVZ

flosoft

Member
Jul 6, 2008
68
0
6
Hi,

I was wondering what the difference between the RAM and SWAP field is in the VM.

It seems to both be RAM in the VM (free -m).

What is the difference? Is the one guaranteed memory, and the other one burst memory?

Is there a point in setting up a server with 80GB SSD storage for SWAP, and use that for the VMs too?
 
Hi,

any news on this? I'd love to use some SSDs for the SWAP. It's fine if it just shows up as RAM on the VPS, but that way, I can say: 512MB of RAM are guaranteed, and the rest is moved off to SWAP on SSDs if the host is running low on memory.
 
From OpenVZ forum:
As xemul said.. the VE has no concept of the difference between ram and swap. Its just "memory" at the VE level. So, your HN can have 64MB of ram and 64GB of swap. Or, your HN can have 64GB of ram and 64MB of swap. In the VE, the privvm, oomguar, vmguar are uneffected by this. Only the performance changes between the two scenarios. In either case, you can guarantee and limit each VE to an arbitrary amount of memory. This drastically differs from the conventional mem management of vmware/xen (isoloation). VZ is a shared kernel model and no resources are "hard dedicated" or "hard assigned".

-not possible to give/assign/guarantee a VE XX swap and YY physical memory
-not possible to restrict a VE from using physical memory and use swap instead


Think of the VZ virtual servers like resource containers, not individual linux boxes- VZ is a shared kernel approach to virtualization.

Hope this clears it up for you.


Rick Blundell

http://forum.openvz.org/index.php?SQ=0&t=search&srch=swap&btn_submit=Search
 

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!