Questions tagged [libvirt]

libvirt is an API and toolkit for developing applications which manage virtual machine hypervisors, the virtual machines running under them, and virtual machine storage.

Filter by
Sorted by
Tagged with
0 votes
1 answer
12 views

KVM Networking - assign IP to each VM by outside DHCP

I am new to KVM and am having a problem with setting up the networking. I want each VM to get its IPs assigned by the network's DHCP, not the internal DHCP that the KVM keeps trying to set up. In ...
1 vote
1 answer
3k views

NATing through a vpn with libvirt

I installed a server with libvirt, and I've created a test VM. When I use the default network for it's interface, it gets a private IP and the NATing seems to work fine. I installed OpenVPN, so I have ...
0 votes
1 answer
23 views

`virsh -c qemu:///session list --all` lists VMs created in `QEMU/KVM` connection, but misses VM from `QEMU/KVM User session` of Virt-Manager

# virsh -c qemu:///session list --all lists only VMs created in QEMU/KVM connection (system !), but misses VM I've created in QEMU/KVM User session in GUI of Virt-Manager. Why? From below I unserstand ...
-1 votes
1 answer
30 views

Blocking mac spoofing on libvirt guests using openflow

I have a couple of kvm vms running with libvirt and they are using openvswitch bridges. I need a mechanism to prevent mac spoofing on a guest. I tried libvirt filters no-mac-spoofing and clean-traffic ...
2 votes
1 answer
3k views

Migrating from libvirt + iptables to libvirt + nftables

I'm about to migrate a Debian Stretch host using qemu-kvm to Debian Buster. I've seen people complaining on the Internet about issues due to nftables becoming default in place of iptables and libvirt ...
0 votes
0 answers
25 views

libvirt guest cannot be reboot within itself or from host

I have a guest(debian9) created by: virt-install --name vm --events=on_reboot=restart,on_poweroff=restart,on_crash=restart --disk /opt/debian9.qcow2 --import acpid is installed in guest. If I reboot ...
0 votes
1 answer
39 views

Virsh command hangs when script runs in the background

I have a bash script which runs as a cronjob. This script runs several commands and one of them is the following virsh command: /usr/bin/virsh list --all When I run this script in the terminal (as ...
3 votes
0 answers
3k views

Delayed start for Guests KVM/libvirt

Looking for any pointers anyone may have to introduce a delayed start for KVM guests i.e. 30 seconds between starting each virtual server rather than starting them all at once which thrashes the disks ...
1 vote
1 answer
62 views

Migrating libvirt guest vm to a new storage directory on the same host

I have found a few related questions/articles but nothing about just simply moving an existing VM to a new directory on the same machine. That's what this question entails. For this scenario, I need ...
0 votes
0 answers
27 views

Cannot ping/SSH VMs from Host created into Xen VM (guest) on VirtualBox hostonly network and bridged interface

I have a network related issue. Here the description of my prototype : |=========================VirtualBox==============================| | |======== LibVirt ==...
12 votes
4 answers
78k views

virsh: VM console does not show any output

I have a VM which I can start with virsh. According to virsh dumpxml VM1, this is the allocated pty: <serial type='pty'> <source path='/dev/pts/6'/> <target port='0'/> <...
0 votes
1 answer
36 views

Bridging wan interface using macvtap - no connection to host

So I have an ubuntu server with 1 WAN interface with a public ip address. I would like to bridge this interface so that the qemu guest vm will use the same interface. I used the guide in https://...
0 votes
1 answer
1k views

Accessing VirtualBox with libvirt from a guest

I have installed libvirt on OSX, and from outside a virtualbox I can access it using virsh no problem. However, I want to access it from inside a guest, and this is giving me the hopelessly useless ...
0 votes
1 answer
1k views

EL6/KVM guest dies with "pthread_create failed: Resource temporarily unavailable"

I've got a CentOS 6.5 x86-64 KVM server with a bunch of guest VMs of different breeds, mostly EL5 and EL6. However one and only one of them keeps crashing every couple of days with: pthread_create ...
1 vote
1 answer
20 views

qemu commandline can't see /dev/net/tun

i am newbie with qemu and libvirt. I hit the issue with virsh and qemu, especially with tun interface setup. Once i run qemu-system-x86_64 \ -nographic -enable-kvm \ -cpu host -m 2048 \ -...
1 vote
1 answer
1k views

SCSI virtual disks not showing up on RHEL 7.X KVM guests

For whatever reason I can't get my virtual disks to show up on any of my RHEL 7.X guests (libvirt + KVM). The XML is configured just like my other guests so I know it isn't an issue on that end. It ...
0 votes
1 answer
32 views

virsh console hangs when i connect kvm VM

KVM Host Environment:- # cat /etc/issue Welcome to openSUSE 13.2 "Harlequin" - Kernel \r (\l). # /usr/bin/qemu-system-x86_64 --version QEMU emulator version 2.1.3 Running VMs list as ...
0 votes
2 answers
42 views

How to resize kvm vm host

KVM Host Environment:- # cat /etc/issue Welcome to openSUSE 13.2 "Harlequin" - Kernel \r (\l). # /usr/bin/qemu-system-x86_64 --version QEMU emulator version 2.1.3 With the below commands i ...
1 vote
0 answers
56 views

KVM start failed (ubuntu image)

KVM start failing after I have made the below changes. Environment:- qemu-img version 2.1.3 ubuntu VM 1. Stop the VM 2. qemu-img resize vm1.img +50G 3. start the VM virsh start vm1 error: failed to ...
0 votes
0 answers
8 views

libvirt and dnsmasq does not allow to start Kea DHCP server

I have libvirt installed which instantiates dnsmasq process per each virtual bridge interface, e.g. virbr0, however for some reason I can't start kea-dhcp server on other interfaces in the system, ...
0 votes
1 answer
40 views

libvirt nwfilter breaks networking of other VMs

I just switched from VirtualBox to Virt Manager with KVM and I am very happy with the switch (my initial motivation for it was to use the same virtualization for desktop VMs and server VMs by ditching ...
0 votes
1 answer
460 views

cloud-init seems to be ignoring write-files script

H! I am trying to configure VMs with cloud-init, using the terraform Libvirt provider. For some reason I don't understand, setting hostname works, but writing and running a script for additional ...
0 votes
0 answers
16 views

Forbid LibVirt to pmsuspend

I've VMs on KVM/LibVirt. Some of them hangs after libvirt makes pmsuspend and then I pmwakeup them, and I need to force the reboot of the VM. Is there any way to make LibVirt never to pmsuspend domain?...
0 votes
1 answer
31 views

Parallel OpenVPN Connection Over multiple Libvirt Network Interfaces

Let's Say That I have 20 VMs (Host: Ubuntu, Using Qemu-KVM, libvirt) and that I would use different network interfaces for different groups of vms. (1-6 using Network1, 7-15 using Network2, 16-20 ...
2 votes
1 answer
1k views

XFS/EXT4: Why is actual file size on disk larger than apparent size? Clarification

On a CentOS 7.1.1503 (3.10.0-229.el7.x86_64) system running KVM/qemu on an XFS filesystem, I'm attempting to work out what specifically is adding additional space to a VM diskimage file. $ ls -ls --...
0 votes
1 answer
3k views

How to start a new instance of QEMU based on the same image and snapshot?

I have a QEMU image (qcow2) with a snapshot stored in it. Right now I'm using libvirt to start it. However, I want to be able to run more than one instance of the same image snapshot. I guess I can ...
1 vote
3 answers
899 views

Can't install additional VM with virt-install

Installing an additional VM with the virt-install command results in the following error: ERROR internal error: process exited while connecting to monitor: 2019-02-20T08:21:45.534416Z qemu-system-...
1 vote
1 answer
2k views

How to permanently attach USB devices to a KVM vserver?

I run a Server using KVM and virt-manager (over SSH). Currently I have the following devices which I want/need in a KVm virtual machine: +----USB-HUB +- USB Smartcard Reader #1 +- USB Smartcard ...
0 votes
1 answer
6k views

OpenStack instances power off by itself

Already asked this over on ask.openstack.org but I figured it would get more views here too. I am running OpenStack Mitaka on a 5 node cluster, 1 controller/network node and 4 compute nodes. I am ...
1 vote
1 answer
4k views

virsh attach-device for serial device

I would like to add a serial device (console) to a guest via the virsh attach-device command. I have a console.xml file containing: <serial type="pty"> <target port="0"/> </serial>...
0 votes
1 answer
257 views

Preloading shared library with libVirt

I am trying to load two shared libraries while running Qemu using libvirt. To preload the shared libraries I have added an environment variable in the $domain.xml file with the following command: ...
0 votes
0 answers
396 views

virt-manager's remote-viewer: fails to connect thru SSH tunnel with "incomplete link header (-104/16)

I have a server running libvirtd with QEMU/KVM domains. I would like to access it with virt-manager from a remote machine, for which I open an SSH tunnel and forward a TCP port (libvirtd is listening ...
0 votes
1 answer
147 views

Assigning a Public IPv4 automatically to every KVM VM thats being created?

Im wondering how would i go on about assigning a public ipv4 to each vm thats being created. Setup : Host Server with 3 IPs on CentOS8 using libvirt and kvm to virtualize Bridge br0 using eth0 as ...
1 vote
1 answer
107 views

How to change Libvirt Job type from 'Cancelled' to 'None'?

After I abort a live migrate, the Job type has changed to 'Cancelled', which makes me unable to migrate again. So,If some libvirt api (or QMP) can help me to change the Job type from 'Cancelled' to '...
5 votes
3 answers
8k views

Wake-on-lan to trigger virtual-machine with kvm and libvirt

I'm doing virtualization with KVM and managing it via the Libvirt daemon. How do I configure Libvirt or KVM to listen for Wake-On-Lan packets sent the the Virtual Machine's NIC's MAC address and to ...
1 vote
2 answers
4k views

Do not start guest after virt-install

I like to set up a new guest but do not want to start it immediately. I use virt-install with these options: virt-install \ --connect qemu:///system \ --import \ --virt-type kvm \ --...
0 votes
0 answers
639 views

How to auto redirect a usb device on virt-manager

How do I automatically redirect a USB device to a remote KVM? preferrably filtered by ID. I have a KVM running on a server (QEMU+SSH), and the display protocol is Spice. How could I always redirect a ...
3 votes
3 answers
6k views

How to setup IPTables on KVM host - iptables-persistent is being ignored

I'm trying to setup some specific IPTables rules on an ubuntu 14.04.1 host that runs some KVM guests. The box has multiple NICs with multiple IP addresses and the guests use different addresses based ...
9 votes
4 answers
7k views

How do I prevent libvirt from adding iptables rules for guest NAT networks?

Similar to this old request on BugZilla for Fedora 8, I'm hoping something has changed since then or someone knows another way. I want to manage the iptables rules by hand—the one-size-fits-all ...
2 votes
1 answer
580 views

Pacemaker cluster: Xen RA vs libvirt RA

Building a pacemaker cluster to manage Xen domU virtual machines the sysadm can choose between to different resource agents: the dedicated Xen resource agent (ocf:heartbeat:Xen) the libvirt based ...
0 votes
2 answers
2k views

How do I boot the Debian 10 image with qemu/kvm?

I'm attempting to boot the openstack image of Debian 10 using qemu and encountering an error detecting the harddrive, the end of the boot up sequence is showing: [ 0.989085] Run /init as init ...
0 votes
0 answers
221 views

qemu-kvm snapshot creations are extremely slow after a few first fast ones

Could anyone help me on this please? behavior I'm running several VMs with qemu-kvm and when creating some first few snapshots of a running VM, they are created super fast (roughly 10 seconds). ...
2 votes
3 answers
10k views

How to move KVM image to another directory/partition?

My storage devices are mounted as follows: $ df -h Filesystem Size Used Avail Use% Mounted on /dev/md2 193G 35G 148G 19% / /dev/md4 492G 73M 466G 1% /mnt My KVM image is ...
0 votes
1 answer
505 views

How to pass-through multiple USB devices with the same Vendor- and Device-ID in QEMu/Libvirt?

I have three identical USB devices on my VM host that I would like to pass-through to a VM: I can pass-through only one device as they all have the same vendor- and device-ID, the element in the VM ...
0 votes
0 answers
155 views

Terraform Libvirt - How to use local qcow2 file

i try to provision some nodes for a kubernetes cluster based on kvm and debian. I want to use the Debian 11 Genericcloud Image and clound-init to initialize it. So i put the debian baseimge to /var/...
1 vote
1 answer
225 views

libvirtd eating up to 100% CPU with no apparent reason

Few days ago libvirt has started to behave erratically on my laptop. It consumes a high amount of CPU without any apparent reason. ALL my VMs are shutoff, why is libvirt using up to 100% CPU if no VMs ...
4 votes
3 answers
11k views

Libvirt has no KVM capabilities even though qemu-kvm works

I've learned that CirrusCI offers nested virtualization in their free package for public repos and I am trying to make use of it for testing my Ansible playbooks. Unfortunately, libvirt is insisting ...
0 votes
0 answers
284 views

KVM stuck in boot loop

I have a server here, running Ubuntu 16.04 and libvirt 4.0.0. It is hosting a single KVM, a Jenkins Server. This server however is stuck in a boot loop after it was shut down for maintenance. I cannot ...
3 votes
3 answers
594 views

virsh autostart not working

root@virtual3:~# virsh autostart nstest Domain nstest marked as autostarted root@virtual3:~# virsh dominfo nstest Id: - Name: nstest UUID: 8cf691cd-7246-442b-a26b-...
0 votes
1 answer
68 views

Set the date automatically after VM unpauses

I’ve got virtual machines (with Debian or occasionally *buntu guests, GNU/Linux) running in libvirt/qemu/kvm, and I have discovered the feature to pause/unpause a VM. After unpausing (virsh resume), ...

1
2 3 4 5
13