4 messages in com.xensource.lists.xen-develRe: [Xen-devel] [PATCH] Make xendomai...
FromSent OnAttachments
Gawain Lynch28 Jun 2007 22:35 
Mark Williamson29 Jun 2007 08:57 
Daniel P. Berrange29 Jun 2007 09:13 
Gawain Lynch29 Jun 2007 18:07.patch
Subject:Re: [Xen-devel] [PATCH] Make xendomains ignore lost+found
From:Mark Williamson (mark@cl.cam.ac.uk)
Date:06/29/2007 08:57:55 AM
List:com.xensource.lists.xen-devel

As requested by Mark Williamson in BZ #681

Signed-off-by: Gawain Lynch <gawa@gmail.com>

Gawain, thanks for identifying this and patching it.

This fixes a breakage on resume when the XENDOMAINS_SAVE directory is a separate partition.

At some point it /might/ be nice to have more sophisticated checking of what is an suspend image, and what's not. But this patch shouldn't break anything, and should fix a user-visible bug for some people.

--- xendomains.orig 2006-06-17 14:35:48.000000000 +1000 +++ xendomains 2006-06-17 14:45:29.000000000 +1000 @@ -207,10 +207,11 @@ if [ "$XENDOMAINS_RESTORE" = "true" ] && contains_something "$XENDOMAINS_SAVE" then + XENDOMAINS_SAVED=`/bin/ls $XENDOMAINS_SAVE/* | grep -v 'lost+found'` mkdir -p $(dirname "$LOCKFILE") touch $LOCKFILE echo -n "Restoring Xen domains:" - for dom in $XENDOMAINS_SAVE/*; do + for dom in $XENDOMAINS_SAVED; do echo -n " ${dom##*/}" xm restore $dom if [ $? -ne 0 ]; then @@ -239,6 +240,7 @@ if is_running $dom; then echo -n "(skip)" else + echo "(booting)" xm create --quiet --defconfig $dom if [ $? -ne 0 ]; then rc_failed $?