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

RE: [Xen-devel] [PATCH 0 of 9] v2: xl/libxl autoballooning



On Fri, 27 Aug 2010, Dan Magenheimer wrote:
> Hi Stefano --
> 
> I'm glad you have been working on this for xl since this dom0
> capability is also the foundation for ensuring domain creation works
> properly when tmem is both enabled on Xen and enabled on one or more
> running guests.  In that situation, tmem absorbs much (or even
> all) of the free memory in the system, much like dom0 starts
> with all the memory and must surrender it to start other guests.
> One big difference though is that dom0 doesn't asynchronously
> grow and claim the memory back, which can happen with tmem.
> Tmem has functionality to cover this case though.
> 
> I'm not able to work on this right now... it will probably
> be a few weeks before I can, due to various constraints.  But
> since you have just implemented this, I'm sure it is fresh
> in your brain and you may be able to check or update your
> patch to ensure it will easily support tmem as well.
> Perhaps you can at least insert comments at the points
> where you think the tmem hooks would be necessary?  Or if
> you insert actual code that works with tmem disabled,
> I can try/debug it later with tmem enabled?  Either way
> would make it much easier for me to finish the job later.
> 

I think you'll find very easy to add tmem support on top of this series
because the way it works is very similar to what xend does now.

In fact after trying few other approaches and throwing them away because
either too hard or racy, I decided to go for the very simple "global
lock" method.  So right before building the domain in the create_domain
function xl acquires a lock and calls freemem.  Freemem is an xl
function, very similar to the free function in balloon.py in xend, that
calculates how much memory the new domain needs and frees it, using libxl
memory management functions.
Adding few libxl tmem calls in freemem should do the job.




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


 


Rackspace

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