disk=$2
target_vg=ssd
+# to specify target vg use VG enviroment varible like:
+# VG=oscarvg ./gnt-lv2ssd.sh dataverse 0
+
if [ "$1" = '-' ] ; then
read instance disk
elif [ -z "$instance" -o -z "$disk" ] ; then
test -z "$instance" && exit 1
+test ! -z "VG" && target_vg=$VG
+
instance=`gnt-instance list --no-headers -o name $instance | head -1`
node=`gnt-instance list -o pnode --no-headers $instance`
ssh $node sh -xe /dev/shm/$instance.sh
+
+ echo "TEST: kvm -m 1024 -drive file=/dev/$target_vg/$instance.$disk_nr,format=raw,if=virtio -nographic -net nic -net user"
+ echo "after login: ifdown eth0 ; dhclient eth0"
done
+