Bug 222467

Summary: [XEN-VT]'Cannot allocate memory' error
Product: Red Hat Enterprise Linux 5 Reporter: Steven Rostedt <srostedt>
Component: xenAssignee: Xen Maintainance List <xen-maint>
Status: CLOSED CURRENTRELEASE QA Contact:
Severity: high Docs Contact:
Priority: high    
Version: 5.0CC: clalance, gcase, kzak, mjenner, sputhenp, xen-maint
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 5.0.0 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2007-02-14 16:32:04 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 217056    
Bug Blocks:    
Attachments:
Description Flags
Enable shadow before memory reservation for HVM
none
[XEN]: Enable shadow before memory reservation for HVM none

Comment 1 Herbert Xu 2007-01-27 05:17:32 UTC
Created attachment 146739 [details]
Enable shadow before memory reservation for HVM

It turns out that the bogus m2p entries are a recent introduction.  When
shadow2 (changeset 11151) was introduced, upstream moved the code that enables
shadow mode for HVM guests to user-space.  In particular, this was done after
memory allocation and before the physmap has been populated.  This only
affected HVM because PV translate mode populated the physmap before enabling
shadow mode.

Upstream has since fixed it by moving the enabling of shadow mode back into the
hypervisor which means that it will occur before memory allocation.  This patch
tries to do this in a more conservative way by simply moving the enabling of
shadow mode before memory allocation.

I've verified that running this version of xend allows me to start HVM guests
on a host where otherwise you can't start HVM guests at all due to this bug.

When we move to 3.0.4 we can remove the shadow_enable function from the python
bindings of libxc.

Comment 2 Herbert Xu 2007-01-28 10:57:35 UTC
Created attachment 146761 [details]
[XEN]: Enable shadow before memory reservation for HVM

This version adds an HVM check so that we only enable shadow mode on HVM
guests.  The shadow_enable function is also renamed to hvm_shadow_enable.

Comment 5 Jay Turner 2007-01-29 20:45:20 UTC
QE ack for RHEL5.

Comment 6 Brian Stein 2007-01-29 20:47:37 UTC
Rik - Let's build the pacakge and the version number in the BZ.  If we decide to
include it in a respin, we can drag it in.

Brian

Comment 8 Rik van Riel 2007-02-01 22:18:34 UTC
in 3.0.3-23.el5

Comment 10 Jay Turner 2007-02-14 16:32:04 UTC
Closing out.