Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 25 Aug 2014 01:36:56 +0000 (UTC)
From:      Craig Rodrigues <rodrigc@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r270513 - head/share/examples/bhyve
Message-ID:  <201408250136.s7P1audn060523@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: rodrigc
Date: Mon Aug 25 01:36:56 2014
New Revision: 270513
URL: http://svnweb.freebsd.org/changeset/base/270513

Log:
  If the VM was reset via "/sbin/reboot" or "shutdown -r",
  then it is no longer necessary to "bhyvectl --destroy" the VM when it reboots.
  Move the "bhyvectl --destroy" outside of the while loop.
  
  Reviewed by: neel

Modified:
  head/share/examples/bhyve/vmrun.sh

Modified: head/share/examples/bhyve/vmrun.sh
==============================================================================
--- head/share/examples/bhyve/vmrun.sh	Mon Aug 25 01:04:07 2014	(r270512)
+++ head/share/examples/bhyve/vmrun.sh	Mon Aug 25 01:36:56 2014	(r270513)
@@ -173,8 +173,9 @@ echo "Launching virtual machine \"$vmnam
 
 virtio_diskdev="$disk_dev0"
 
+${BHYVECTL} --vm=${vmname} --destroy > /dev/null 2>&1
+
 while [ 1 ]; do
-	${BHYVECTL} --vm=${vmname} --destroy > /dev/null 2>&1
 
 	file ${virtio_diskdev} | grep "boot sector" > /dev/null
 	rc=$?



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201408250136.s7P1audn060523>