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/
Home Products Support Community News


RE: [Xen-devel] failed to start centos 5 domU with maxmem=30000

> > > Why this is not provided in documentation or on web site?
> >
> > Hi Vasily --
> >
> > This function limits how far memory can be reduced when
> > ballooning a guest (including dom0).  It is only a heuristic
> > but is intended to take into account the various overheads
> > a guest Linux kernel requires to manage memory to avoid
> > out-of-memory conditions.
> >
> > But I think you are correct... the same (or similar)
> > function should be published as it also serves as a
> > guideline for the ratio between memory= and maxmem=
> > parameters when creating a guest:  If the ratio
> > of maxmem divided by memory is too high, the guest
> > will not even boot.
> Is that possible to use memory=32 and maxmem=60000 ?

I think the answer is no.  I believe there is a kernel
data structure for each 4K page in physical memory
I don't remember the size of this data structure, but
assume it is 4 bytes.  That means that for 1GB of
physical memory (as specified by maxmem) this data
structure requires 1MB of physical memory just to track
the 1GB.  So for your maxmem=60000, memory=60 would
only be enough for this one kernel data structure (and
the kernel requires many other data structures to
be functional).

Daniel Kiper is developing virtual hotplug memory for Xen
guests.  This may be a good use case for it.
> > I am curious as to why you would specify memory= so
> > much smaller than maxmem=.  Are you trying to overcommit
> > memory for guests that are often idle but sometimes use
> > a very large amount of memory?
> We want to provide ability to use small as possible memory if the guest
> is idle. And much as possible when the guest under heavy load.

This is a much harder problem than it seems.  You may want
to look at some of the presentations on Transcendent Memory
that explain why it is hard.  (Most can be found at
http://oss.oracle.com/projects/tmem )


Xen-devel mailing list