From: Evan Broder Date: Fri, 21 Nov 2008 03:46:49 +0000 (-0500) Subject: Use xm reboot instead of a destroy and create to reboot VMs X-Git-Tag: invirt-remote-host/0.0.9^0 X-Git-Url: http://xvm.mit.edu/gitweb/invirt/packages/invirt-remote.git/commitdiff_plain/a35086e352c6152814acdcf916aef6ba23452d06?ds=sidebyside Use xm reboot instead of a destroy and create to reboot VMs svn path=/trunk/packages/invirt-remote-host/; revision=1723 --- diff --git a/debian/changelog b/debian/changelog index 0739c67..209bb16 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,9 @@ +invirt-remote-host (0.0.9) unstable; urgency=low + + * Use `xm reboot` for reboots instead of a destroy and create + + -- Evan Broder Thu, 20 Nov 2008 10:54:13 -0500 + invirt-remote-host (0.0.8) unstable; urgency=low * I know this is the wrong answer, but doing lvchange -a n twice before diff --git a/files/usr/sbin/invirt-vmcontrol b/files/usr/sbin/invirt-vmcontrol index 5a47705..1391db4 100755 --- a/files/usr/sbin/invirt-vmcontrol +++ b/files/usr/sbin/invirt-vmcontrol @@ -17,17 +17,13 @@ case "$ACTION" in list|vcpu-list|uptime) xm "$ACTION" "$MACHINE" ;; - destroy|shutdown) + destroy|shutdown|reboot) xm "$ACTION" "$MACHINE" /usr/sbin/invirt-update-conserver /dev/null 2>&1 & ;; - install|create|reboot) + install|create) shift; shift; - if [ "$ACTION" = "reboot" ]; then - xm destroy "$MACHINE" 2>/dev/null - else - xm list "$MACHINE" >/dev/null 2>/dev/null && echo "$MACHINE already exists" && exit 1 - fi + xm list "$MACHINE" >/dev/null 2>/dev/null && echo "$MACHINE already exists" && exit 1 if [ "$ACTION" = "install" ]; then xm create invirt-database machine_name="$ORIGMACHINE" installer_options="$(printf '%q ' "$@")" elif [ -n "$1" ]; then