Incremental backup utility
by Michael Ablassmeier
hi users,
i have started a project on github that aims to create a small backup
utility, supporting the new changed block tracking features.
If anyone wants to give it a try and has some suggestions, here
is the link:
https://github.com/abbbi/virtnbdbackup
bye,
- michael
3 years, 8 months
infinite lease time
by Francesc Guasch
Hi. First of all thanks for this great project and specially
for keeping the Perl library.
I need to keep the IP address of the virtual machines the same
as long as possible. dnsmasq provides a setting for lease time.
It can be set to infinite, but not from within libvirt.
I found this patch from 2016.
>
https://listman.redhat.com/archives/libvir-list/2016-October/msg00561.html
But it looks like it never made to libvirt.
Some time ago I made it work changing dnsmasq/default.conf.
Then we made it immutable with chattr. This no longer works
because libvirt refuses to start dnsmasq unless it can write
to it. Fair enough.
I've seen I can add manual IP addresses as stated here:
https://wiki.libvirt.org/page/Networking
This is ok, but it would be a considerable amount of work,
requiring lots of manual labour.
Is there a way to set the lease time from libvirt ?
Thank you !
3 years, 8 months
virsh capabilities does not include qemu
by shafnamol N
Hi,
I am new to Libvirt and Qemu.I have installed Libvirt 7.1.0 and qemu-kvm
4.2.0.
I configured and built libvirt based on instructions from
https://libvirt.org/compiling.html.
But when i tried to create a VM using virsh it shows the following error:
# virsh create /home/abc.xml
error: Failed to create domain from /home/abc.xml
error: invalid argument: could not find capabilities for arch=x86_64
domaintype=kvm
When i check the hypervisor capabilities ,it doest show qemu in guest
domain type.
# virsh capabilities
....................................
.....................................
</host>
<guest>
<os_type>exe</os_type>
<arch name='x86_64'>
<wordsize>64</wordsize>
<emulator>/usr/local/libexec/libvirt_lxc</emulator>
<domain type='lxc'/>
</arch>
</guest>
<guest>
<os_type>exe</os_type>
<arch name='i686'>
<wordsize>32</wordsize>
<emulator>/usr/local/libexec/libvirt_lxc</emulator>
<domain type='lxc'/>
</arch>
</guest>
</capabilities>
I have restarted libvirt to get the qemu support,but it is not shown in
capabilities list.What will be the problem?
Thanks for the help in advance....
3 years, 8 months
Access to an OCFS2 Partition outside the VM
by Lentes, Bernd
Hi,
i'm thinking about installing two Ubuntu versions on one pc, one as a host system with KVM, the other in a virtual domain.
I need access from both to several OCFS2 partitions with big amount of data. The partitions are on harddisks attached to that pc.
Is it possible to access an OCFS2 partition which is outside the domain ?
And if yes how can i do that ?
I know that i have to configure OCFS2 and that i need DLM.
Buth systems have network, that shouldn't be the problem.
Bernd
--
Bernd Lentes
System Administrator
Institute for Metabolism and Cell Death (MCD)
Building 25 - office 122
HelmholtzZentrum München
bernd.lentes(a)helmholtz-muenchen.de
phone: +49 89 3187 1241
phone: +49 89 3187 3827
fax: +49 89 3187 2294
http://www.helmholtz-muenchen.de/mcd
Helmholtz Zentrum München
Helmholtz Zentrum Muenchen
Deutsches Forschungszentrum fuer Gesundheit und Umwelt (GmbH)
Ingolstaedter Landstr. 1
85764 Neuherberg
www.helmholtz-muenchen.de
Aufsichtsratsvorsitzende: MinDir.in Prof. Dr. Veronika von Messling
Geschaeftsfuehrung: Prof. Dr. med. Dr. h.c. Matthias Tschoep, Kerstin Guenther
Registergericht: Amtsgericht Muenchen HRB 6466
USt-IdNr: DE 129521671
3 years, 8 months
Updating dnsmasq options with virsh net-update
by Alex Crawford
I'm trying to take advantage of libvirt's support for passing through
options to dnsmasq
<https://libvirt.org/formatnetwork.html#elementsNamespaces>, but I'm having
trouble getting it to take effect. I have a network already created and I'm
trying to use net-update to add the options, but it's not clear to me what
section I should specify. By the way, is there a good way to list the
available sections? I've been resorting to reading the code
<https://gitlab.com/libvirt/libvirt/-/blob/18d0f2f9569edf3c26d912a7d8974a5...>.
Working in a different direction, I tried using net-edit to make the
changes but they seem to have been silently discarded:
$ virsh -c qemu:///system net-edit crawford-libvirt-67v2h
Network crawford-libvirt-67v2h XML configuration edited.
$ virsh -c qemu:///system net-dumpxml crawford-libvirt-67v2h | grep
--count <my changes>
0
Can anyone tell me what I'm doing wrong or how this feature was intended to
be used? Thank you.
-Alex
3 years, 8 months
Question about migrate the vm with host-passthrough cpu
by Guoyi Tu
Hi there,
Sorry to bother you, but could I ask you a question about the live
migration of virtual machine configured with host-passthough cpu, it
confuse me a lot.
Here i have two hosts with different cpu, and the cpu feature set of old
host is subset of the new one (by virsh cpu-compare). If the vm was
first started on the old host,is it safe to migrate the vm between the
two hosts back and forth with the vm always keep running?
I've test the case in my environment, and the migration succeeds, the
cpu family/model/stepping and features of lscpu in Guest OS is the same.
--
Best Regards,
Guoyi Tu
3 years, 8 months
Using cgroups in QEMU hooks
by Melissa Nuño
Hi all,
I'm creating a device during the prepare hook, and would like to add it to
the device.allow file for the VM. The cgroup doesn't exist during the
prepare hook or the start hook and will fail with an "Operation not
permitted" error. I can add the expected path to qemu.conf and restart
libvirtd, but this isn't very flexible since I'd have to do it for each
device for each VM I create. All of the other libvirt cgroups seem to allow
all devices, so I'm not seeing where the VM cgroup is getting its initial
list.
Is there a way to access the cgroup for a VM before it has started? I can't
even predict where it should be since it contains the domain ID.
Thanks!
3 years, 8 months
Re: Issue
by Samuel Thampy
Is there any additional info anyone who needs?
________________________________
From: Samuel Thampy <samjiks(a)hotmail.com>
Sent: 03 March 2021 22:11
To: libvirt-users(a)redhat.com <libvirt-users(a)redhat.com>
Subject: Issue
I have a storage backend san disks, I have five servers which is KVM hosted guests.
I am looking to clone an image of a guest machine, so I can use a new VM form the image on a different server..
I am not sure what the best way. But when I do that, I get a memory error, and need to xfs_repair and damages the original machine.
My steps are
One vm machine on the same server
* dd create original vm to template.img
* lvcreate -L 9G -n <vol-name> <pool>
* dd template.img to /dev/<pool>/<vol-name>
* virsh define <vm_name>.xml
another vm machine on the secondary server
* copy template.img to another server
* lvcreate -L 9G -n <vol-name> <pool>
* dd if=template.img of=/dev/<pool>/<vol-name>
* virsh define <vm_name>.xml
May I know the steps are missing something because both are getting corrupted. Thanks for your help.
Regards
Samuel Thampy
3 years, 8 months
Bridge and VLAN trunk
by Gionatan Danti
Dear list,
I am a question about the best use of bridge, vlan trunk and libvirt.
When dealing with virtual machies bound to specific vlan, I generally
use a straightforward approach:
eth -> bridge -> vm (for untagged traffic)
eth -> eth.10 -> bridge -> vm
eth -> eth.nn -> bridge -> vm
Now I am faced with enabling vlan trunking for a specific vm (a
virtualized firewall). The simpler approach would be:
eth -> bridge -> vm (for the vm needing trunk)
eth -> bridge.10 -> macvtap -> vm
The issue with the above method is that any VM on the main untagged vlan
needs to be bound to the "plain" bridge, having access to *any* traffic
of *any* other vlan. If this is ok (and the desired behavior) for the
firewall, it is clearly wrong for the other VMs.
A simple fix would be to use ebtables to block/drop vlan tagged traffic
on the main bridge for any virtual adapter except the required one (ie:
the firewall virtual interface). It works, but I wounder if other
preferred approaches exists.
For example, I tested another more convoluted setup:
eth -> bridge -> firewall vm
eth -> bridge.10 -> macvtap -> vm
eth -> bridge -> veth0 -> veth1 -> other bridge with vlan filtering on
-> vm
The last row show the use of veth virtual interface, configurable via ip
link. Enabling vlan filtering on the second bridge (rather than on the
first) is to keep vlan filtering simple: rathen than enabling all
required vlan on the first bridge, I simply enable only untagged traffic
on the second one.
Does libvirt support bridge vlan filtering natively? Reading the docs,
it seems to the supported only on OpenVSwitch or SRV-IO based adapter.
Thanks.
--
Danti Gionatan
Supporto Tecnico
Assyoma S.r.l. - www.assyoma.it
email: g.danti(a)assyoma.it - info(a)assyoma.it
GPG public key ID: FF5F32A8
3 years, 8 months
Snapshot operation aborted and volume usage
by Liran Rotenberg
We recently had this bug[1]. The thought that came from it is the handling
of error code after running virDomainSnapshotCreateXML, we encountered
VIR_ERR_OPERATION_ABORTED(78).
Apparently, the new volume is in use. Are there cases where this will
happen and the new volume won't appear in the volumes chain? Can we detect
/ know when?
Thinking aloud, if we can detect such cases we can prevent rolling back by
reporting it back from VDSM to ovirt. Or, if it can't be detected to go on
the safe side in order to save data corruption and prevent the rollback as
well.
Currently, in ovirt, if the job is aborted, we will look into the chain to
decide whether to rollback or not.
Regards,
Liran.
[1] - https://bugzilla.redhat.com/show_bug.cgi?id=1916122
3 years, 8 months