# HG changeset patch # User Olaf Hering <olaf@aepfle.de> # Date 1336159720 -7200 # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 xl.cfg: document the maxmem= option Signed-off-by: Olaf Hering <olaf@aepfle.de> diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 --- a/docs/man/xl.cfg.pod.5 +++ b/docs/man/xl.cfg.pod.5 @@ -484,6 +484,14 @@ are not using hardware assisted paging ( mode) and your guest workload consists of a a very large number of similar processes then increasing this value may improve performance. +=item B<maxmem=MBYTES> + +Specifies the maximum amount of memory the HVM guest can ever see. +In combination with the memory= option it will enable the PoD (populate +on demand) mode for the guest iff the values of memory= and maxmem+differ. The guest needs a balloon driver in this case. The value of +maxmem= must be equal or greater than memory=. + =back =head3 Processor and Platform Features @@ -955,10 +963,6 @@ XXX XXX -=item B<maxmem=NUMBER> - -XXX - =item B<nodes=XXX> XXX
Konrad Rzeszutek Wilk
2012-May-04 19:42 UTC
Re: [PATCH] xl.cfg: document the maxmem= option
On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote:> # HG changeset patch > # User Olaf Hering <olaf@aepfle.de> > # Date 1336159720 -7200 > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > xl.cfg: document the maxmem= option > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > --- a/docs/man/xl.cfg.pod.5 > +++ b/docs/man/xl.cfg.pod.5 > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > mode) and your guest workload consists of a a very large number of > similar processes then increasing this value may improve performance. > > +=item B<maxmem=MBYTES> > + > +Specifies the maximum amount of memory the HVM guest can ever see.Isn''t it also for PV guests (though without the PoD functionality)?> +In combination with the memory= option it will enable the PoD (populate > +on demand) mode for the guest iff the values of memory= and maxmem> +differ. The guest needs a balloon driver in this case. The value of > +maxmem= must be equal or greater than memory=. > + > =back > > =head3 Processor and Platform Features > @@ -955,10 +963,6 @@ XXX > > XXX > > -=item B<maxmem=NUMBER> > - > -XXX > - > =item B<nodes=XXX> > > XXX > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel
On Fri, May 04, Konrad Rzeszutek Wilk wrote:> On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > # HG changeset patch > > # User Olaf Hering <olaf@aepfle.de> > > # Date 1336159720 -7200 > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > xl.cfg: document the maxmem= option > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > --- a/docs/man/xl.cfg.pod.5 > > +++ b/docs/man/xl.cfg.pod.5 > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > mode) and your guest workload consists of a a very large number of > > similar processes then increasing this value may improve performance. > > > > +=item B<maxmem=MBYTES> > > + > > +Specifies the maximum amount of memory the HVM guest can ever see. > > Isn''t it also for PV guests (though without the PoD functionality)?Now that I look again at libxl__build_pre(), it appearently does also something for PV guests. I will resend the patch. Thanks for the review. Olaf
On Fri, 2012-05-04 at 16:18 -0400, Olaf Hering wrote:> On Fri, May 04, Konrad Rzeszutek Wilk wrote: > > > On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > > # HG changeset patch > > > # User Olaf Hering <olaf@aepfle.de> > > > # Date 1336159720 -7200 > > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > > xl.cfg: document the maxmem= option > > > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > > --- a/docs/man/xl.cfg.pod.5 > > > +++ b/docs/man/xl.cfg.pod.5 > > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > > mode) and your guest workload consists of a a very large number of > > > similar processes then increasing this value may improve performance. > > > > > > +=item B<maxmem=MBYTES> > > > + > > > +Specifies the maximum amount of memory the HVM guest can ever see. > > > > Isn''t it also for PV guests (though without the PoD functionality)? > > Now that I look again at libxl__build_pre(), it appearently does also > something for PV guests.Right. Some people call this booting "pre-ballooned". Essentially n PV the balloon driver can be initialised early enough that something like PoD is not required -- the missing pages are just incorporated directly into the balloon. (strictly speaking the balloon driver isn''t actually initialised early, but rather the pages are reserved/set-aside for it very early on). Ian.
On Sun, May 06, Ian Campbell wrote:> On Fri, 2012-05-04 at 16:18 -0400, Olaf Hering wrote: > > On Fri, May 04, Konrad Rzeszutek Wilk wrote: > > > > > On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > > > # HG changeset patch > > > > # User Olaf Hering <olaf@aepfle.de> > > > > # Date 1336159720 -7200 > > > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > > > xl.cfg: document the maxmem= option > > > > > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > > > --- a/docs/man/xl.cfg.pod.5 > > > > +++ b/docs/man/xl.cfg.pod.5 > > > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > > > mode) and your guest workload consists of a a very large number of > > > > similar processes then increasing this value may improve performance. > > > > > > > > +=item B<maxmem=MBYTES> > > > > + > > > > +Specifies the maximum amount of memory the HVM guest can ever see. > > > > > > Isn''t it also for PV guests (though without the PoD functionality)? > > > > Now that I look again at libxl__build_pre(), it appearently does also > > something for PV guests. > > Right. Some people call this booting "pre-ballooned". Essentially n PV > the balloon driver can be initialised early enough that something like > PoD is not required -- the missing pages are just incorporated directly > into the balloon.What about this wording? Specifies the maximum amount of memory a guest can ever see. The value of maxmem= must be equal or greater than memory=. In combination with the memory= option it will start the guest "pre-ballooned". In a HVM guest it will enable the PoD (populate on demand) mode, iff the values of memory= and maxmem= differ. The guest needs a balloon driver in this case, without a balloon driver it will crash. Olaf
> From: Ian Campbell [mailto:Ian.Campbell@citrix.com] > Sent: Sunday, May 06, 2012 3:36 AM > To: Olaf Hering > Cc: xen-devel@lists.xensource.com; Konrad Rzeszutek Wilk > Subject: Re: [Xen-devel] [PATCH] xl.cfg: document the maxmem= option > > On Fri, 2012-05-04 at 16:18 -0400, Olaf Hering wrote: > > On Fri, May 04, Konrad Rzeszutek Wilk wrote: > > > > > On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > > > # HG changeset patch > > > > # User Olaf Hering <olaf@aepfle.de> > > > > # Date 1336159720 -7200 > > > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > > > xl.cfg: document the maxmem= option > > > > > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > > > --- a/docs/man/xl.cfg.pod.5 > > > > +++ b/docs/man/xl.cfg.pod.5 > > > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > > > mode) and your guest workload consists of a a very large number of > > > > similar processes then increasing this value may improve performance. > > > > > > > > +=item B<maxmem=MBYTES> > > > > + > > > > +Specifies the maximum amount of memory the HVM guest can ever see.can _ever_ see... What about guest OS''s that support hotplug memory? Also, a subtle point, but is this the maximum physical address that will contain read/write pages or the maximum amount of RAM that the guest OS should be prepared to map as read/writeable (e.g. after subtracting off reserved e820 ranges) or ???
On Mon, 2012-05-07 at 17:37 +0100, Dan Magenheimer wrote:> > From: Ian Campbell [mailto:Ian.Campbell@citrix.com] > > Sent: Sunday, May 06, 2012 3:36 AM > > To: Olaf Hering > > Cc: xen-devel@lists.xensource.com; Konrad Rzeszutek Wilk > > Subject: Re: [Xen-devel] [PATCH] xl.cfg: document the maxmem= option > > > > On Fri, 2012-05-04 at 16:18 -0400, Olaf Hering wrote: > > > On Fri, May 04, Konrad Rzeszutek Wilk wrote: > > > > > > > On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > > > > # HG changeset patch > > > > > # User Olaf Hering <olaf@aepfle.de> > > > > > # Date 1336159720 -7200 > > > > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > > > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > > > > xl.cfg: document the maxmem= option > > > > > > > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > > > > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > > > > --- a/docs/man/xl.cfg.pod.5 > > > > > +++ b/docs/man/xl.cfg.pod.5 > > > > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > > > > mode) and your guest workload consists of a a very large number of > > > > > similar processes then increasing this value may improve performance. > > > > > > > > > > +=item B<maxmem=MBYTES> > > > > > + > > > > > +Specifies the maximum amount of memory the HVM guest can ever see. > > can _ever_ see... > > What about guest OS''s that support hotplug memory?Does the toolstack (need to) expose the capability to drive that as a host admin? I don''t think xl does... In which case this wording can be tweaked when that feature is added?> Also, a subtle point, but is this the maximum physical address that > will contain read/write pages or the maximum amount of RAM that the > guest OS should be prepared to map as read/writeable (e.g. after > subtracting off reserved e820 ranges) or ???I think it is total number of memory pages, not the maximum PFN. e.g. the maximum address might be 4.5GB on a 4GB machine with a PCI hole. I *think*... Ian.
> From: Ian Campbell [mailto:Ian.Campbell@citrix.com] > Sent: Tuesday, May 08, 2012 6:41 AM > To: Dan Magenheimer > Cc: Olaf Hering; xen-devel@lists.xensource.com; Konrad Wilk > Subject: RE: [Xen-devel] [PATCH] xl.cfg: document the maxmem= option > > On Mon, 2012-05-07 at 17:37 +0100, Dan Magenheimer wrote: > > > From: Ian Campbell [mailto:Ian.Campbell@citrix.com] > > > Sent: Sunday, May 06, 2012 3:36 AM > > > To: Olaf Hering > > > Cc: xen-devel@lists.xensource.com; Konrad Rzeszutek Wilk > > > Subject: Re: [Xen-devel] [PATCH] xl.cfg: document the maxmem= option > > > > > > On Fri, 2012-05-04 at 16:18 -0400, Olaf Hering wrote: > > > > On Fri, May 04, Konrad Rzeszutek Wilk wrote: > > > > > > > > > On Fri, May 04, 2012 at 09:31:42PM +0200, Olaf Hering wrote: > > > > > > # HG changeset patch > > > > > > # User Olaf Hering <olaf@aepfle.de> > > > > > > # Date 1336159720 -7200 > > > > > > # Node ID c414728d0d12f1c3e416e40cceefca2f0b00578e > > > > > > # Parent 8f556a70ae0bef47e242f9e7be0a054769fc8277 > > > > > > xl.cfg: document the maxmem= option > > > > > > > > > > > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > > > > > > > > > > > diff -r 8f556a70ae0b -r c414728d0d12 docs/man/xl.cfg.pod.5 > > > > > > --- a/docs/man/xl.cfg.pod.5 > > > > > > +++ b/docs/man/xl.cfg.pod.5 > > > > > > @@ -484,6 +484,14 @@ are not using hardware assisted paging ( > > > > > > mode) and your guest workload consists of a a very large number of > > > > > > similar processes then increasing this value may improve performance. > > > > > > > > > > > > +=item B<maxmem=MBYTES> > > > > > > + > > > > > > +Specifies the maximum amount of memory the HVM guest can ever see. > > > > can _ever_ see... > > > > What about guest OS''s that support hotplug memory? > > Does the toolstack (need to) expose the capability to drive that as a > host admin? I don''t think xl does... In which case this wording can be > tweaked when that feature is added?I don''t know if the matching support ever was implemented in xl, but hotplug memory support for Xen is in upstream Linux. http://lists.xen.org/archives/html/xen-devel/2011-05/msg01060.html If it _is_ in xl, "can ever see" seems a bit too strong... maybe something like "memory the HVM guest can see unless changed later via ''xl mem-max''" or "memory the HVM guest can see when it boots" would be better. But this is a nit. It''s impossible to both be precise and brief in descriptions such as these.> > Also, a subtle point, but is this the maximum physical address that > > will contain read/write pages or the maximum amount of RAM that the > > guest OS should be prepared to map as read/writeable (e.g. after > > subtracting off reserved e820 ranges) or ??? > > I think it is total number of memory pages, not the maximum PFN. e.g. > the maximum address might be 4.5GB on a 4GB machine with a PCI hole. > > I *think*...OK. If so, then the proposed wording is fine, though maybe adding one word "maximum amount of _usable_ memory" might help.
# HG changeset patch # User Olaf Hering <olaf@aepfle.de> # Date 1338476618 -7200 # Node ID 4dad9647a0963a2665ccf055492e740c2b399517 # Parent d7318231cfe3498947bf75f09d6675407d7b4e76 xl.cfg: document the maxmem= option Signed-off-by: Olaf Hering <olaf@aepfle.de> diff -r d7318231cfe3 -r 4dad9647a096 docs/man/xl.cfg.pod.5 --- a/docs/man/xl.cfg.pod.5 +++ b/docs/man/xl.cfg.pod.5 @@ -174,6 +174,14 @@ Honoured by the sedf scheduler. Start the guest with MBYTES megabytes of RAM. +=item B<maxmem=MBYTES> + +Specifies the maximum amount of memory a guest can ever see. +The value of maxmem= must be equal or greater than memory=. +In combination with the memory= option it will start the guest "pre-ballooned". +In a HVM guest it will enable the PoD (populate on demand) mode, iff the values of memory= and maxmem= differ. +The guest needs a balloon driver in this case, without a balloon driver it will crash. + =item B<on_poweroff="ACTION"> Specifies what should be done with the domain if it shuts itself down. @@ -971,10 +979,6 @@ XXX XXX -=item B<maxmem=NUMBER> - -XXX - =item B<nodes=XXX> XXX
On Thu, 2012-05-31 at 16:04 +0100, Olaf Hering wrote:> # HG changeset patch > # User Olaf Hering <olaf@aepfle.de> > # Date 1338476618 -7200 > # Node ID 4dad9647a0963a2665ccf055492e740c2b399517 > # Parent d7318231cfe3498947bf75f09d6675407d7b4e76 > xl.cfg: document the maxmem= option > > Signed-off-by: Olaf Hering <olaf@aepfle.de> > > diff -r d7318231cfe3 -r 4dad9647a096 docs/man/xl.cfg.pod.5 > --- a/docs/man/xl.cfg.pod.5 > +++ b/docs/man/xl.cfg.pod.5 > @@ -174,6 +174,14 @@ Honoured by the sedf scheduler. > > Start the guest with MBYTES megabytes of RAM. > > +=item B<maxmem=MBYTES> > + > +Specifies the maximum amount of memory a guest can ever see. > +The value of maxmem= must be equal or greater than memory=. > +In combination with the memory= option it will start the guest "pre-ballooned". > +In a HVM guest it will enable the PoD (populate on demand) mode, iff the values of memory= and maxmem= differ. > +The guest needs a balloon driver in this case, without a balloon driver it will crash."iff" has proven to be confusing in the past (we keep getting "fix typo" patches for existing ones) maybe just spell it out? Otherwise Ack on the text. Although may add a note that booting a PV guest "pre-ballooned" Just Works? Formatting wise some of these lines are very long. Can you wrap to 80 columns please. Also why have you wrapped this as one sentence per line rather than wrapping it as paragraphs (which should have blank lines between them)? I think maxmem= should be B<maxmem=> and the same for memory=. Ian.> + > =item B<on_poweroff="ACTION"> > > Specifies what should be done with the domain if it shuts itself down. > @@ -971,10 +979,6 @@ XXX > > XXX > > -=item B<maxmem=NUMBER> > - > -XXX > - > =item B<nodes=XXX> > > XXX > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel
# HG changeset patch # User Olaf Hering <olaf@aepfle.de> # Date 1338562334 -7200 # Node ID fde8ad0252ee6ddb8d71dda869db3b20b3d9ca62 # Parent 3b4346d6002e9ffcd4a9f50b031bd2a77b16b1dd xl.cfg: document the maxmem= option Signed-off-by: Olaf Hering <olaf@aepfle.de> diff -r 3b4346d6002e -r fde8ad0252ee docs/man/xl.cfg.pod.5 --- a/docs/man/xl.cfg.pod.5 +++ b/docs/man/xl.cfg.pod.5 @@ -174,6 +174,16 @@ Honoured by the sedf scheduler. Start the guest with MBYTES megabytes of RAM. +=item B<maxmem=MBYTES> + +Specifies the maximum amount of memory a guest can ever see. +The value of B<maxmem=> must be equal or greater than B<memory=>. + +In combination with B<memory=> it will start the guest "pre-ballooned", +if the values of B<memory=> and B<maxmem=> differ. +A "pre-ballooned" HVM guest needs a balloon driver, without a balloon driver +it will crash. + =item B<on_poweroff="ACTION"> Specifies what should be done with the domain if it shuts itself down. @@ -971,10 +981,6 @@ XXX XXX -=item B<maxmem=NUMBER> - -XXX - =item B<nodes=XXX> XXX
On Fri, Jun 01, Ian Campbell wrote:> On Thu, 2012-05-31 at 16:04 +0100, Olaf Hering wrote: > > +=item B<maxmem=MBYTES> > > + > > +Specifies the maximum amount of memory a guest can ever see. > > +The value of maxmem= must be equal or greater than memory=. > > +In combination with the memory= option it will start the guest "pre-ballooned". > > +In a HVM guest it will enable the PoD (populate on demand) mode, iff the values of memory= and maxmem= differ. > > +The guest needs a balloon driver in this case, without a balloon driver it will crash. > > "iff" has proven to be confusing in the past (we keep getting "fix typo" > patches for existing ones) maybe just spell it out? Otherwise Ack on the > text. Although may add a note that booting a PV guest "pre-ballooned" > Just Works?I just send a simplified version of this patch. Mentioning PoD is not really needed because its an hypervisor internal feature.> Formatting wise some of these lines are very long. Can you wrap to 80 > columns please.Done.> Also why have you wrapped this as one sentence per line rather than > wrapping it as paragraphs (which should have blank lines between them)?Just a habit.> I think maxmem= should be B<maxmem=> and the same for memory=.Done. Olaf
On Fri, 2012-06-01 at 15:55 +0100, Olaf Hering wrote:> # HG changeset patch > # User Olaf Hering <olaf@aepfle.de> > # Date 1338562334 -7200 > # Node ID fde8ad0252ee6ddb8d71dda869db3b20b3d9ca62 > # Parent 3b4346d6002e9ffcd4a9f50b031bd2a77b16b1dd > xl.cfg: document the maxmem= option > > Signed-off-by: Olaf Hering <olaf@aepfle.de>Applied, thanks.> > diff -r 3b4346d6002e -r fde8ad0252ee docs/man/xl.cfg.pod.5 > --- a/docs/man/xl.cfg.pod.5 > +++ b/docs/man/xl.cfg.pod.5 > @@ -174,6 +174,16 @@ Honoured by the sedf scheduler. > > Start the guest with MBYTES megabytes of RAM. > > +=item B<maxmem=MBYTES> > + > +Specifies the maximum amount of memory a guest can ever see. > +The value of B<maxmem=> must be equal or greater than B<memory=>. > + > +In combination with B<memory=> it will start the guest "pre-ballooned", > +if the values of B<memory=> and B<maxmem=> differ. > +A "pre-ballooned" HVM guest needs a balloon driver, without a balloon driver > +it will crash. > + > =item B<on_poweroff="ACTION"> > > Specifies what should be done with the domain if it shuts itself down. > @@ -971,10 +981,6 @@ XXX > > XXX > > -=item B<maxmem=NUMBER> > - > -XXX > - > =item B<nodes=XXX> > > XXX > > _______________________________________________ > Xen-devel mailing list > Xen-devel@lists.xen.org > http://lists.xen.org/xen-devel