tweaks per jesse comments
diff --git a/stack.sh b/stack.sh
index 79cc377..2b38f32 100755
--- a/stack.sh
+++ b/stack.sh
@@ -546,9 +546,9 @@
#
# By default, the backing file is 2G in size, and is stored in /opt/stack.
#
- VOLUME_BACKING_FILE=${VOLUME_BACKING_FILE:-/opt/stack/nova-volumes-backing-file}
- VOLUME_BACKING_FILE_SIZE=${VOLUME_BACKING_FILE_SIZE:-2052M}
if ! sudo vgdisplay | grep -q nova-volumes; then
+ VOLUME_BACKING_FILE=${VOLUME_BACKING_FILE:-/opt/stack/nova-volumes-backing-file}
+ VOLUME_BACKING_FILE_SIZE=${VOLUME_BACKING_FILE_SIZE:-2052M}
truncate -s $VOLUME_BACKING_FILE_SIZE $VOLUME_BACKING_FILE
DEV=`sudo losetup -f --show $VOLUME_BACKING_FILE`
sudo vgcreate nova-volumes $DEV