All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nathan Fontenot <nfont@linux.vnet.ibm.com>
To: Michael Roth <mdroth@linux.vnet.ibm.com>,
	bharata@linux.vnet.ibm.com, qemu-devel@nongnu.org
Cc: khandual@linux.vnet.ibm.com, qemu-ppc@nongnu.org,
	david@gibson.dropbear.id.au
Subject: Re: [Qemu-devel] [RFC PATCH v0] spapr: Disable memory hotplug when HTAB size is insufficient
Date: Fri, 04 Sep 2015 10:49:18 -0500	[thread overview]
Message-ID: <55E9BD7E.8020801@linux.vnet.ibm.com> (raw)
In-Reply-To: <20150904153317.10296.41287@loki>

On 09/04/2015 10:33 AM, Michael Roth wrote:
> Quoting Nathan Fontenot (2015-09-03 13:50:59)
>> On 09/01/2015 10:28 PM, Bharata B Rao wrote:
>>> On Mon, Aug 24, 2015 at 09:01:51AM +0530, Bharata B Rao wrote:
>>>> The hash table size allocated to guest depends on the maxmem size.
>>>> If the host isn't able to allocate the required hash table size but
>>>> instead allocates less than the optimal requested size, then it will
>>>> not be possible to grow the RAM until maxmem via memory hotplug.
>>>> Attempts to hotplug memory till maxmem could fail and this failure
>>>> isn't being currently handled gracefully by the guest kernel thereby
>>>> causing guest kernel oops.
>>>>
>>>> This should eventually get fixed when we move to completely in-kernel
>>>> memory hotplug instead of the current method where userspace tool drmgr
>>>> drives the hotplug. Until the in-kernel memory hotplug is available
>>>> for PowerKVM, disable memory hotplug when requested hash table size
>>>> isn't allocated.
>>>
>>> David - Do you have any views on how to go about this ? Due to the way
>>> we do hotplug currently using drmgr, it appears that it is very difficult
>>> to have a graceful recovery within the guest kernel when memory hotplug
>>> request can't be fulfilled due to insufficient HTAB size. (Anshuman can
>>> elaborate on this with the exact description on why it is so hard to
>>> recover).
>>>
>>> Do you think disabling memory hotplug upfront is a reasonable workaround
>>> for this problem ?
>>>
>>> Nathan - When you enable in-kernel memory hotplug for PowerKVM, will you
>>> be exporting something for the userspace (capability ?) to check and
>>> determine the presense of in-kernel memory hotplug feature so that we
>>> can depend on graceful recovery instead of upfront disablement of
>>> memory hotplug from QEMU ?
>>>
>>
>> I did not have any plans currently to export something indicating we are
>> using the in-kernel memory hotplug code.
>>
>> Perhaps this is something we should consider adding the to the PAPR update
>> proposal that is being worked? Something to indicate we can gracefully handle
>> adding memory beyond HTAB size.
> 
> That might make sense, but I'm curious what constitutes graceful
> recovery in this context. What can we do with in-kernel hotplug that's not
> possible with userspace tools? If it's graceful failure, is there really
> nothing that can be done by QEMU as the DRC level to get the same
> result?

I don't have an answer for how to recover gracefully or if it will be possible.
If/when we can determine how to do that my thought was to use the PAPR updates
we are working on to indicate to QEMU that the guest is able to handle this
situation.

-Nathan

  reply	other threads:[~2015-09-04 15:49 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-24  3:31 [Qemu-devel] [RFC PATCH v0] spapr: Disable memory hotplug when HTAB size is insufficient Bharata B Rao
2015-08-24  4:34 ` Anshuman Khandual
2015-09-02  3:28 ` Bharata B Rao
2015-09-03  2:34   ` David Gibson
2015-09-03 18:50   ` Nathan Fontenot
2015-09-04 15:33     ` Michael Roth
2015-09-04 15:49       ` Nathan Fontenot [this message]
2015-09-04 16:12         ` Michael Roth
2015-09-09  9:06           ` Anshuman Khandual

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=55E9BD7E.8020801@linux.vnet.ibm.com \
    --to=nfont@linux.vnet.ibm.com \
    --cc=bharata@linux.vnet.ibm.com \
    --cc=david@gibson.dropbear.id.au \
    --cc=khandual@linux.vnet.ibm.com \
    --cc=mdroth@linux.vnet.ibm.com \
    --cc=qemu-devel@nongnu.org \
    --cc=qemu-ppc@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.