KSM: Difference between revisions
No edit summary |
(Updated to 2.6.35 kernel branch) |
||
Line 1: | Line 1: | ||
=Introduction= | =Introduction= | ||
Beginning with Proxmox VE 1.5 (only with Kernel 2.6. | Beginning with Proxmox VE 1.5 (only with Kernel 2.6.35 and higher), Proxmox VE uses KSM (Kernel Samepage Merging). | ||
KSM is running in the Linux kernel scanning the memory of all the virtual machines running on a single host, looking for duplication and consolidating. With KSM we're able to improve virtual machine density by as much as 300% without impacting performance. One of the great benefits of using Linux as the hypervisor means KSM is not limited to KVM and virtual machines, but can also reduce memory pressure with normal Linux applications. | KSM is running in the Linux kernel scanning the memory of all the virtual machines running on a single host, looking for duplication and consolidating. With KSM we're able to improve virtual machine density by as much as 300% without impacting performance. One of the great benefits of using Linux as the hypervisor means KSM is not limited to KVM and virtual machines, but can also reduce memory pressure with normal Linux applications. | ||
=Howto enable KSM= | =Howto enable KSM= | ||
Just run the 2.6. | Just run the 2.6.35 kernel branch, see [[Proxmox_VE_Kernel]] | ||
Check packages version with '''pveversion -v''' (all versions should be equal or higher): | Check packages version with '''pveversion -v''' (all versions should be equal or higher): | ||
<pre>pveversion -v | <pre>pveversion -v | ||
pve-manager: 1. | pve-manager: 1.6-4 (pve-manager/1.6/5229) | ||
running kernel: 2.6. | running kernel: 2.6.35-1-pve | ||
proxmox-ve-2.6. | proxmox-ve-2.6.35: 1.6-1 | ||
pve-kernel-2.6. | pve-kernel-2.6.35-1-pve: 2.6.35-1 | ||
qemu-server: 1.1- | qemu-server: 1.1-19 | ||
pve-firmware: 1.0- | pve-firmware: 1.0-9 | ||
libpve-storage-perl: 1.0- | libpve-storage-perl: 1.0-14 | ||
vncterm: 0.9-2 | vncterm: 0.9-2 | ||
vzctl: 3.0. | vzctl: 3.0.24-1pve4 | ||
vzdump: 1.2- | vzdump: 1.2-7 | ||
vzprocps: 2.0.11-1dso2 | vzprocps: 2.0.11-1dso2 | ||
vzquota: 3.0.11-1 | vzquota: 3.0.11-1 | ||
pve-qemu-kvm: 0. | pve-qemu-kvm: 0.12.5-2 | ||
ksm-control-daemon: 1.0- | ksm-control-daemon: 1.0-4 | ||
</pre> | |||
=KSM in action= | =KSM in action= |
Revision as of 08:51, 6 October 2010
Introduction
Beginning with Proxmox VE 1.5 (only with Kernel 2.6.35 and higher), Proxmox VE uses KSM (Kernel Samepage Merging).
KSM is running in the Linux kernel scanning the memory of all the virtual machines running on a single host, looking for duplication and consolidating. With KSM we're able to improve virtual machine density by as much as 300% without impacting performance. One of the great benefits of using Linux as the hypervisor means KSM is not limited to KVM and virtual machines, but can also reduce memory pressure with normal Linux applications.
Howto enable KSM
Just run the 2.6.35 kernel branch, see Proxmox_VE_Kernel
Check packages version with pveversion -v (all versions should be equal or higher):
pveversion -v pve-manager: 1.6-4 (pve-manager/1.6/5229) running kernel: 2.6.35-1-pve proxmox-ve-2.6.35: 1.6-1 pve-kernel-2.6.35-1-pve: 2.6.35-1 qemu-server: 1.1-19 pve-firmware: 1.0-9 libpve-storage-perl: 1.0-14 vncterm: 0.9-2 vzctl: 3.0.24-1pve4 vzdump: 1.2-7 vzprocps: 2.0.11-1dso2 vzquota: 3.0.11-1 pve-qemu-kvm: 0.12.5-2 ksm-control-daemon: 1.0-4
KSM in action
Just install several KVM virtual machines with the same OS (using at least 50 % of your physical memory on the host) and wait a few minutes. you will notice higher CPU activities on the host (ksm daemon) and the used memory on the host will be lowered significantly.