summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rwxr-xr-xcreate-new-vm.sh4
-rwxr-xr-xremove-vm.sh2
2 files changed, 3 insertions, 3 deletions
diff --git a/create-new-vm.sh b/create-new-vm.sh
index b42e3cd..8419ff1 100755
--- a/create-new-vm.sh
+++ b/create-new-vm.sh
@@ -39,7 +39,7 @@ cat <<EOF >vm.xml
<emulator>/usr/sbin/qemu-system-x86_64</emulator>
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2'/>
- <source file='/mnt/data/libvirt/storage/${name}.img'/>
+ <source file='/var/lib/libvirt/images/${name}.img'/>
<target dev='vda' bus='virtio'/>
</disk>
<controller type='usb' index='0'>
@@ -74,7 +74,7 @@ cat <<EOF >vm.xml
</domain>
EOF
-virsh vol-create-as nfs ${name}.img $size --format qcow2
+virsh vol-create-as default ${name}.img $size --format qcow2
virsh define vm.xml
vmmac=$(virsh domiflist $name | grep -oE "[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}:[0-9a-f]{2}")
diff --git a/remove-vm.sh b/remove-vm.sh
index 97f0161..b12cb8b 100755
--- a/remove-vm.sh
+++ b/remove-vm.sh
@@ -9,5 +9,5 @@ fi
virsh destroy $name
virsh undefine $name
-virsh vol-delete $name.img nfs
+virsh vol-delete $name.img default