WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-users

Re: [Xen-users] Memory problems persist... Cannot allocate memory

To: James Pifer <jep@xxxxxxxxxxxxxxxx>
Subject: Re: [Xen-users] Memory problems persist... Cannot allocate memory
From: Pasi Kärkkäinen <pasik@xxxxxx>
Date: Thu, 31 Dec 2009 16:05:13 +0200
Cc: Xen List <xen-users@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 31 Dec 2009 06:06:04 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1262234360.15120.16.camel@xxxxxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-users-request@lists.xensource.com?subject=help>
List-id: Xen user discussion <xen-users.lists.xensource.com>
List-post: <mailto:xen-users@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-users>, <mailto:xen-users-request@lists.xensource.com?subject=unsubscribe>
References: <1262234360.15120.16.camel@xxxxxxxxxxxxxxxxxxxxxxxx>
Sender: xen-users-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.13 (2006-08-11)
On Wed, Dec 30, 2009 at 11:39:20PM -0500, James Pifer wrote:
> I have always had a problem with my xen servers having memory problems
> after a random period of time. For example, even if there's free memory
> available, if you try to add a new domU or restart one, virt-manager
> says it can't allocate memory. I was really hoping I had gotten past
> this issue on my latest SLES11 servers running xen 3.4 by specifying
> domU memory and disabling ballooning. 
> 

How do you check this 'free memory'? from dom0, or from Xen hypervisor
"xm info" ?

> Unfortunately the problem has reappeared on one of these servers. My
> only solution is a restart, which affects 12-15 servers. Are others
> having this problem? There has to be a resolution to this. 
> 

This could be because you haven't limited dom0 memory to a dedicated
amount, and now you need to balloon down dom0 memory every time you
start a new guest..

> I will try restarting xend and see if that resolves it, but I need to
> wait until I can restart dom0 in case it completely hoses it. 
> 
> I also just made another post that has me scared to death where I
> completely lost a whole domU from my ocfs2 volume when I rebooted a
> server, so I'm a bit gun shy right now!
> 

Have you dedicated memory to dom0? ie. have you specified dom0_mem=512M
(or whatever you need) in grub.conf for xen.gz ? 

In addition to dom0_mem for Xen hypervisor, you should also have
dom0-min-mem= specified in /etc/xen/xend-config.sxp to prevent dom0 from
being ballooned down.

If you don't have dom0_mem set for xen.gz, then dom0 will have all the
memory visible to it, and many dom0 Linux kernel parameters and buffers
are calculated/allocated based on that initial amount of memory - and
then during runtime when you start guests dom0 memory needs to be
ballooned down, and things start to go wrong at some point. Linux
doesn't really like when it's memory goes to a only small fraction of
what it had in the beginning (during startup).

So yeah, make sure dom0 doesn't need to be ballooned down during runtime.
Dedicate fixed amount of memory for dom0.

-- Pasi


_______________________________________________
Xen-users mailing list
Xen-users@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-users