Re: [libvirt-users] snapshot of running vm's

Dominique wrote:
-----Original Message----- From: Dominique Ramaekers [mailto:dominique.ramaekers@cometal.be] Sent: Thursday, December 03, 2015 9:46 AM To: Lentes, Bernd Subject: RE: snapshot of running vm's
-----Oorspronkelijk bericht----- Van: Lentes, Bernd [mailto:bernd.lentes@helmholtz-muenchen.de] Verzonden: woensdag 2 december 2015 21:22 Aan: Dominique Ramaekers; libvirt-ML Onderwerp: RE: snapshot of running vm's
...
Hi,
i have inserted:
<channel type='unix'> <source mode='bind'
path='/var/lib/libvirt/qemu/channel/target/sles11.org.qemu.guest_age nt
.0'/
<target type='virtio' name='org.qemu.guest_agent.0'/> <address type='virtio-serial' controller='0' bus='0' port='2'/> </channel>
I didn't insert the path, it was added automatically, the same with "<address type='virtio-serial' controller='0' bus='0' port='2'/>". I tried already port 1 and 2, but get this error:
sunhb58820:~/libvirt_1.2.11 # virsh start sles11 error: Failed to start domain sles11 error: internal error: process exited while connecting to monitor: qemu-kvm: -chardev
socket,id=charchannel0,path=/var/lib/libvirt/qemu/channel/target/sles1
1.or g.qemu.guest_agent.0,server,nowait: Failed to bind socket: No such file or directory chardev: opening backend "socket" failed
Does the path /var/lib/libvirt/qemu/channel/target/ exists? Is libvirt able to write to this path?
Hi Dominique, no, the path does not exist. But from where does libvirt derive it ? I forgot: I'm still running libvirt 1.2.5. Do I need to update also for this problem ? Bernd Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir'in Baerbel Brumme-Bothe Geschaeftsfuehrer: Prof. Dr. Guenther Wess, Dr. Nikolaus Blum, Dr. Alfons Enhsen Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

-----Oorspronkelijk bericht----- Van: Lentes, Bernd [mailto:bernd.lentes@helmholtz-muenchen.de] Verzonden: donderdag 3 december 2015 13:54 Aan: libvirt-ML CC: Dominique Ramaekers Onderwerp: RE: snapshot of running vm's
...
Hi,
i have inserted:
<channel type='unix'> <source mode='bind'
path='/var/lib/libvirt/qemu/channel/target/sles11.org.qemu.guest_age nt
.0'/
<target type='virtio' name='org.qemu.guest_agent.0'/> <address type='virtio-serial' controller='0' bus='0' port='2'/> </channel>
I didn't insert the path, it was added automatically, the same with "<address type='virtio-serial' controller='0' bus='0' port='2'/>". I tried already port 1 and 2, but get this error:
sunhb58820:~/libvirt_1.2.11 # virsh start sles11 error: Failed to start domain sles11 error: internal error: process exited while connecting to monitor: qemu-kvm: -chardev
socket,id=charchannel0,path=/var/lib/libvirt/qemu/channel/target/sles1
1.or g.qemu.guest_agent.0,server,nowait: Failed to bind socket: No such file or directory chardev: opening backend "socket" failed
Does the path /var/lib/libvirt/qemu/channel/target/ exists? Is libvirt able to write to this path?
Hi Dominique,
no, the path does not exist. But from where does libvirt derive it ?
I think the path is compiled into the binaries. Just create the path and make sure libvirt can write to it root@CmsrvVH3:/var/lib/libvirt/qemu/channel# ls -lh totaal 4,0K drwxr-xr-x 2 libvirt-qemu kvm 4,0K nov 23 20:49 target
I forgot: I'm still running libvirt 1.2.5. Do I need to update also for this problem ?
I don't think so... Until you want to use active block commit, your good with 1.2.5
Bernd
Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir'in Baerbel Brumme-Bothe Geschaeftsfuehrer: Prof. Dr. Guenther Wess, Dr. Nikolaus Blum, Dr. Alfons Enhsen Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671

Dominique wrote:
Having this configuration in the xml it worked: <channel type='unix'> <source mode='bind' path='/var/lib/libvirt/qemu/channel/target/sles11.org.qemu.guest_agent.0'/
<target type='virtio' name='org.qemu.guest_agent.0'/> <address type='virtio-serial' controller='0' bus='0' port='2'/> </channel> The file exists now: srwxrwxr-x 1 root root 0 Dec 3 14:15 /var/lib/libvirt/qemu/channel/target/sles11.org.qemu.guest_agent.0= I had to add the directories channel and target. VM is starting fine, snapshot is possible. But still some slight problems: virsh # snapshot-create-as --domain sles11 --name sn_sles11 --atomic --disk-only --live --quiesce error: Operation not supported: live snapshot creation is supported only with external checkpoints I thought --disk-only would create external snapshots ? virsh # snapshot-create-as --domain sles11 --name sn_sles11 --atomic --disk-only --live --quiesce --diskspec vdb,snapshot=external error: Operation not supported: live snapshot creation is supported only with external checkpoints Hm. Specifying external explicitely also does not help. virsh # snapshot-create-as --domain sles11 --name sn_sles11 --atomic --disk-only --quiesce --diskspec vdb,snapshot=external,file=/var/lib/kvm/images/sles11/sn_disk0.qcow2 Domain snapshot sn_sles11 created Omitting --live is the key. But I thought I need it because i'm snapshotting a running vm ?
I forgot: I'm still running libvirt 1.2.5. Do I need to update also for this problem ? I don't think so... Until you want to use active block commit, your good with 1.2.5
I still have 1.2.5. I tried to blockcommit: virsh # blockcommit sles11 vdb --path /var/lib/kvm/images/sles11/sn_disk0.qcow2 --wait --verbose --delete error: option --path already seen what does that mean ? virsh # blockcommit sles11 --path /var/lib/kvm/images/sles11/sn_disk0.qcow2 --wait --verbose --delete error: unsupported flags (0x2) in function qemuDomainBlockCommit virsh # blockcommit sles11 --path /var/lib/kvm/images/sles11/sn_disk0.qcow2 --wait --verbose error: Operation not supported: committing the active layer not supported yet Ok. Omitting --delete removes one error, but now I have another one. What means "not supported yet" ? Does that mean I have a software which offers blockcommit in the help, but it is not completely implemented ? virsh # blockcommit sles11 --path /var/lib/kvm/images/sles11/sn_disk0.raw --wait --verbose error: invalid argument: No device found for specified path Which path do I have to provide ? The one to the base or the one to the snapshot ? I tried both, but not working. Do I have all these problems because I'm using 1.2.5 ? That's the official version of libvirt which is included by SuSE for SLES 11 SP4. But it's lacking functionality which is offered in the help ? Oh my god. Bernd Helmholtz Zentrum Muenchen Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH) Ingolstaedter Landstr. 1 85764 Neuherberg www.helmholtz-muenchen.de Aufsichtsratsvorsitzende: MinDir'in Baerbel Brumme-Bothe Geschaeftsfuehrer: Prof. Dr. Guenther Wess, Dr. Nikolaus Blum, Dr. Alfons Enhsen Registergericht: Amtsgericht Muenchen HRB 6466 USt-IdNr: DE 129521671
participants (2)
-
Dominique Ramaekers
-
Lentes, Bernd