Hallo,
ich kann es drehen und wenden wie ich es will, aber anscheinend hat virsh einen bug. Anders kann ich es mir nicht erklären.
Ich habe mir ein Script geschrieben, mit dem ich ein BackUp der VM-Disk mache. Vorlage ware die Anleitung von der libvirt Seite.
Hier mal kurz, was passiert...
Erst mal... der Server:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
|
root@vmm:~# virsh domblklist wotan
Target Source
------------------------------------------------
vda /opt/VMs/qemu/storage/SysDev/images/wotan.qcow2
vdb /dev/vms_extra/wotan_freespace1
root@vmm:~# sed '/disk type/,/\/disk/!d' /etc/libvirt/qemu/wotan.xml
<disk type='file' device='disk'>
<driver name='qemu' type='qcow2' cache='writeback'/>
<source file='/opt/VMs/qemu/storage/SysDev/images/wotan.qcow2'/>
<target dev='vda' bus='virtio'/>
<boot order='1'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x06' function='0x0'/>
</disk>
<disk type='block' device='disk'>
<driver name='qemu' type='raw' cache='directsync' io='native'/>
<source dev='/dev/vms_extra/wotan_freespace1'/>
<target dev='vdb' bus='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x07' function='0x0'/>
</disk>
|
Also, vda ist ein quemu qcow2 image und vdb ein LVM Block-Device. Das Block-Device soll NICHT gesichert werden!
root@vmm:~# virsh snapshot-create-as wotan snap_wotan.qcow2 --diskspec vda,file=/opt/VMs/qemu/storage/SysDev/images/snap_wotan.qcow2 --no-metadata --disk-only --atomic --quiesce
error: unsupported configuration: source for disk 'vdb' is not a regular file; refusing to generate external snapshot name
Tja und diese Fehlermeldung bekomme ich jedes mal und es wird kein SnapShot erstellt! Obwohl ja VDA und nicht VDB gesichert werden soll.
Meiner Meinung ist das ein Bug in
virsh.
Oder hat jemand eine Lösung / Erklärung dafür?
Gruß
Robert
--
Verschoben von Fredl aus "Software » Netzwerk+Internet - Anwendungen » Server, Fernzugriff und verteilte Dateisysteme". Bitte die Forenbeschreibungen beachten, danke!