From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Fjellstrom Subject: Re: Memory under KVM? Date: Tue, 15 Dec 2009 16:21:18 -0700 Message-ID: <200912151621.19082.tfjellstrom@shaw.ca> References: <4B22BCE5.7040208@binaryfreedom.info> <200912131016.43193.tfjellstrom@shaw.ca> <4B275FB1.7000608@redhat.com> Reply-To: tfjellstrom@shaw.ca Mime-Version: 1.0 Content-Type: Text/Plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Cc: Avi Kivity To: kvm@vger.kernel.org Return-path: Received: from idcmail-mo1so.shaw.ca ([24.71.223.10]:52893 "EHLO idcmail-mo1so.shaw.ca" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1761550AbZLOXVW (ORCPT ); Tue, 15 Dec 2009 18:21:22 -0500 In-Reply-To: <4B275FB1.7000608@redhat.com> Sender: kvm-owner@vger.kernel.org List-ID: On Tue December 15 2009, Avi Kivity wrote: > On 12/13/2009 07:16 PM, Thomas Fjellstrom wrote: > >> Linux usually keeps very little RAM free (it's kept as cache). So > >> there has to be some action on the part of the host to get the guest > >> to free things. For Windows guests you can use ksm to reclaim free > >> memory (since Windows will zero it). > > > > I'm waiting for 2.6.32 to hit Debian Sid before I start playing with > > ksm (I don't think its in 2.6.31). > > > > The problem is it should be automatic. The balloon driver itself or > > some other mechanism should be capable of noticing when it can free up > > a bunch of guest memory. I can't be bothered to manually sit around and > > monitor memory usage on my host so I can then go into virt-manager to > > reduce memory to each guest. > > That should be pretty easy though it will have an effect on guest > performance. > As long as its only done after an appropriately long idle period (ie: theres been X MB's free for a long time, give it back), I can't see it harming performance too much. At least not more than setting ram too low when manually (de)ballooning memory. -- Thomas Fjellstrom tfjellstrom@shaw.ca