From f5944302fd0cd1e2a60cc97435d1e71ab46a31da Mon Sep 17 00:00:00 2001 From: Jerry Zhao Date: Sat, 27 Dec 2014 09:48:08 -0800 Subject: [PATCH] change pxe image location from /tmp to /home /tmp can be filled up by those image files, move those to a location with large space. Change-Id: I4d57136b3b38dec5cc5cab0807549d57ee6410f6 --- regtest/regtest.sh | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/regtest/regtest.sh b/regtest/regtest.sh index bf99283b..c3caba0a 100755 --- a/regtest/regtest.sh +++ b/regtest/regtest.sh @@ -43,20 +43,21 @@ machines='' tear_down_machines echo "setup $VIRT_NUM virt machines" +rm -rf /tmp/pxe*.raw for i in `seq $VIRT_NUM`; do - if [[ ! -e /tmp/pxe${i}.raw ]]; then + if [[ ! -e /home/pxe${i}.raw ]]; then echo "create image for instance pxe$i" - qemu-img create -f raw /tmp/pxe${i}.raw ${VIRT_DISK} + qemu-img create -f raw /home/pxe${i}.raw ${VIRT_DISK} if [[ "$?" != "0" ]]; then - echo "create image /tmp/pxe${i}.raw failed" + echo "create image /home/pxe${i}.raw failed" exit 1 fi else echo "recreate image for instance pxe$i" - rm -rf /tmp/pxe${i}.raw - qemu-img create -f raw /tmp/pxe${i}.raw ${VIRT_DISK} + rm -rf /home/pxe${i}.raw + qemu-img create -f raw /home/pxe${i}.raw ${VIRT_DISK} if [[ "$?" != "0" ]]; then - echo "create image /tmp/pxe${i}.raw failed" + echo "create image /home/pxe${i}.raw failed" exit 1 fi fi @@ -68,7 +69,7 @@ for i in `seq $VIRT_NUM`; do --network=bridge:installation \ --network=bridge:installation \ --name pxe${i} --ram=${VIRT_MEM} \ - --disk /tmp/pxe${i}.raw,format=raw \ + --disk /home/pxe${i}.raw,format=raw \ --vcpus=${VIRT_CPUS} \ --graphics vnc,listen=0.0.0.0 \ --noautoconsole \ @@ -185,6 +186,7 @@ if [[ $rc != 0 ]]; then echo "deployment failed" exit 1 fi +tear_down_machines #if [[ $tempest == true ]]; then # ./tempest_run.sh # if [[ $? != 0 ]]; then