Bug 497080 - check amount of free disk space before attempting to suspend
check amount of free disk space before attempting to suspend
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: xen (Show other bugs)
All Linux
low Severity medium
: rc
: ---
Assigned To: Xen Maintainance List
Virtualization Bugs
: 589123 626339 (view as bug list)
Depends On:
Blocks: 615187 618569 690419 699611
  Show dependency treegraph
Reported: 2009-04-22 05:59 EDT by Chris Lalancette
Modified: 2012-02-21 00:54 EST (History)
9 users (show)

See Also:
Fixed In Version: xen-3.0.3-133.el5
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2012-02-21 00:54:16 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Chris Lalancette 2009-04-22 05:59:25 EDT
Description of problem:
In an upstream xen-devel discussion, it was suggested that we really have the ability to have suspend cancellation in the RHEL kernels, which has been in upstream Xen for some time.  I'm still waiting on clarification of what particular scenarios would be helped by suspend cancellation, but we might want to think about backporting this feature into the RHEL-5 kernel.  The link to my email is here:


And some of the relevant upstream c/s dealing with suspend cancellation are:

xen-unstable.hg: 13519
linux-2.6.18-xen.hg: 623
Comment 1 Paolo Bonzini 2009-11-11 08:57:01 EST
Unassigning for now.
Comment 3 Paolo Bonzini 2010-11-09 04:47:20 EST
*** Bug 626339 has been marked as a duplicate of this bug. ***
Comment 5 Laszlo Ersek 2011-03-02 11:01:36 EST
Looking at the current state of the files modified by the commits listed in comment 0, additional linux-2.6.18-xen.hg commits to consider the backporting of, on top of 623:

1051:c72ead7ec595 -- Don't register shutdown watch and suspend event channel for Dom0 [if we have 591:cdadea74443c in place -- "Set up an event channel to accept suspend requests. This is much faster than going through xenstore."]

629:abcb2a10ff2f -- linux/x86-64: use xen_new_user_pt() rather than open-coding it [if we have xen_new_user_pt()]

I will have to check xen-unstable.hg as well.
Comment 7 Laszlo Ersek 2011-06-15 08:40:09 EDT
We discussed this, and decided against backporting suspend cancellation.

The most common reason of failure to suspend is insufficient disk space. Userspace could / should do a preventive (best effort) check to see if there's enough free space in the target filesystem. If there isn't, then refuse to suspend.

Changing component to "xen", and retitling.
Comment 8 Laszlo Ersek 2011-06-15 08:41:14 EDT
*** Bug 589123 has been marked as a duplicate of this bug. ***
Comment 15 Yuyu Zhou 2011-11-30 02:00:40 EST
Reproduce the bug on xen-3.0.3-132.el5 and verify the bug on xen-3.0.3-135.el5.

1. Start a guest.
2. Prepare a disk with insuffient space, for example
#dd if=/dev/zero of=/tmp/small.img bs=1M count=100
#mkfs /tmp/small.img
#mount /tmp/small /mnt/small -o loop
3. Save the guest to the inffient space disk
#xm save vm1 /mnt/small/savefile

on xen-3.0.3-132.el5, free disk space is not checked before attempting to suspend:
# xm save 14 /mnt/small/14.save
Error: /usr/lib64/xen/bin/xc_save 4 14 0 0 4 failed
Usage: xm save <Domain> <CheckpointFile>

Save a domain state to restore later.

on xen-3.0.3-135.el5, free disk space is checked before attempting to suspend the guest, and proper message is given.
# xm save 15 /mnt/small/15.save
Error: can't write guest state file /mnt/small/15.save: No space left on device
Usage: xm save <Domain> <CheckpointFile>

Save a domain state to restore later.

So, change this bug to VERIFIED.
Comment 16 errata-xmlrpc 2012-02-21 00:54:16 EST
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


Note You need to log in before you can comment on or make changes to this bug.