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-devel

Re: [Xen-devel] RAM allocation and miscellaneous questions

> It certainly does Mark (help, that is). I would like to learn more about
> this balloon driver, which could make things very managable. Is there any
> documentation or tutorial-like info about?

AFAIK, there's a file in /proc/xen called memory_target or something similar.  
You just write your memory target into there as ASCII text.
e.g. echo target > /proc/xen/memory_target

The idea is that there'll (at some stage) be control messages from dom0 to do 
this so that you don't have to log into a domain to change it's memory 
target.

As Ian said, the driver isn't yet ported to 2.6 (I forgot that) but it 
shouldn't take long when someone gets around to it :-)

> Also, though my domains are running happily, I am seeing plenty of
> memory-related errors. I've just hooked up a serial cable between my
> development servers and my desktop (I live with fans) so I'll be able to
> furnish the list with more details.

I can relate to living with fans :-)  It's useful to have a serial console 
available in case of machine crashes / hangs.  When the machine is still 
operational, xm dmesg will retrive Xen's boot output.

> I have been wondering why my Domain-0 machine hasn't been using swap! :o)

I should have explained this better: domains can swap their own memory to / 
from disk as much as they like.  In contrast, Xen itself does not do any 
swapping to provide the illusion of bigger physical memory.  If domains want 
a bigger memory than you gave them, it's up to them to do all their own 
swapping.

If you want dom0 to swap, you should be able to set up swap in the usual way 
(if it worked on vanilla linux, it should just keep working).  If you want 
other domains to swap, you can give them VBDs to swap to - you just have to 
mkswap on them and configure it in the fstab, same as usual.

> So I should just dump that partition? I suppose I'll have to be very
> rigorous when it comes to keeping that domain lean yes? (Especially as I
> only have 4GB to play with!). Out side of basic OS functionality, are there
> any Xen or LVM2 related processes I have to account for when setting the
> amount of RAM I can use for Domain-0?
>
> I don't suppose I could use the ballon driver for Domain-0 too!?!
>
> Thanks for your reply.
>
> Regards,
> Paul
>
> On Wednesday 29 September 2004 03:30 pm, Mark A. Williamson wrote:
> > > I'm running 10 VMs now quite happily, using LVM2 with distinct storage
> > > areas for each VM filesystem.
> >
> > Cool!
> >
> > > can I allocate more RAM to each VM than arithmetic would suggest?
> >
> > Yes and no ;-)
> >
> > Xen does not do paging to disk, so you can't (for instance) tell a domain
> > it has 256MB but only give it 128MB and then fake out the extra capacity
> > using disk.  The solution under Xen would be to just get the domain to do
> > its own paging - this has the same end result and avoids certain
> > performance and implementation nasties associated with paging in the VMM.
> >
> > Using the balloon driver, you can have a setup where you add and remove
> > memory to / from domains according to their need, so that you can shrink
> > the memory footprints of domains that don't (currently) need as much in
> > core.  This is done manually.
> >
> > Of course, you can also use suspend / resume and live migration to move
> > domains around in order to balance memory load.
> >
> > > Is there some kind of compression or COW
> > > that goes on in the Xen memory management code?
> >
> > Not right now.  There is a plan to implement a shared buffer cache, which
> > would allow domains to share unmodified pages of data that have been read
> > from disk.  This is planned as a performance optimisation not a space
> > optimisation, however.
> >
> > > Would it be best to run one replicated MySQL server (or several with
> > > different versions) loaded into a VM on each physical machine, and have
> > > all the other machines use that over virtual network connections?
> >
> > It probably depends.  I guess you'd save some memory footprint that way
> > (compared to running many copies of the servers) but I really don't know
> > how much.
> >
> > > [64 bit machines]
> > > Does Xen work well with Opterons?
> >
> > In 32-bit mode, it works.  In 64-bit mode, not quite yet.  x86_64 support
> > is under development at the moment and is scheduled as a post-2.0
> > feature. However that will be the preferred path to large memory
> > configurations.
> >
> > HTH,
> > Mark


-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/xen-devel