[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-users] Xen live migration dom0 memory

On Thu, 2015-07-02 at 16:08 +0200, Epiontis IT wrote:
> On 07/01/2015 04:30 PM, Ian Campbell wrote:
> > On Wed, 2015-07-01 at 16:20 +0200, Epiontis IT wrote:
> >> Hello,
> >>
> >> I'm new to XEN live migration. I have a question regarding XEN memory
> >> management while doing a vm live migration. I observed that migrating a
> >> vm on XEN 4.5.1 and Linux Kernel 4.1.0 requires the dom0 on the target
> >> machine to have memory available that is the size of the memory
> >> allocated to the vm (2G). Since I follow "XEN best practices" and set
> >> dom0_mem to 512M the target machine begins swapping out 2G to disk which
> >> makes everything nearly unresponsive. Is this requirement for the dom0
> >> memory size intended or might there be an issue with my setup?
> > I don't think you should need 2G dom0 memory, you should need 2G of free
> > host memory.
> >
> > Perhaps something on your destination host is thinking it wants to
> > balloon dom0 down in order to make that free host memory available?
> >
> > Ian.
> I looked further into the issue. When I start a migration with "xl 
> migrate <vm> <destination>" the destination machine sets up a vm 
> "<vm>--incoming" and seems to sync memory because "xl list" shows "Mem" 
> for the incoming vm going up stepwise until 2048. After that though the 
> vm doesn't get launched. The vm is frozen for about a minute, the dom0 
> begins swapping out the 2GB to disk (because it only has 512M available 
> for itself) and a process
> /usr/lib/xen-4.5/bin/libxl-save-helper --restore-domain
> takes about 90% of the dom0 memory. After that the vm ist launched, 
> memory consumption goes back to normal, swap space is freed.

This sounds like a bug to me. Perhaps a memory leak in the helper or
something with similar symptoms like leaking foreign mappings.

It might be interesting to look at the pmap of the save helper process
while this is going on, since it should show some huge mapping and
whether it is associated with help or privcmd (foreign) mappings etc.

Armed with that information I think it would be appropriate to report as
a bug to the development list, see

> Is this some kind of cold migration process? Is there some option I'm 
> missing that does real live migration?

xl migrate is always live and AFAIK always has been.

Bery recent versions accept a --live option for compatibility with the
old xend/xm command, but it does nothing, because the migration is
already live.


Xen-users mailing list



Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.