Questions tagged [virsh]

The virsh program is the main interface for managing virsh guest domains. Virtualization of the Linux Operating System means the ability to run multiple instances of Operating Systems concurrently on a single hardware system where the basic resources are driven by a Linux instance. The library aims at providing a long term stable C API .

The virsh program is the main interface for managing virsh guest domains. The program can be used to create, pause, and shutdown domains. It can also be used to list current domains. Libvirt is a C toolkit to interact with the virtualization capabilities of recent versions of Linux (and other OSes). It is free software available under the GNU Lesser General Public License. Virtualization of the Linux Operating System means the ability to run multiple instances of Operating Systems concurrently on a single hardware system where the basic resources are driven by a Linux instance. The library aims at providing a long term stable C API . It currently supports Xen, QEmu, KVM , LXC , OpenVZ, VirtualBox, OpenNebula, and VMware ESX .

You can find all info and options on virsh on this page.

155 questions
1
vote
1 answer

Unable create/access storage pool in a KVM

I have trouble using storage pools in my KVM setup. I get the following error message whenever I try to use a pool-* command in my virsh shell. virsh # pool-list error: Failed to get the number of active pools error: this function is not supported…
user2887201
  • 223
  • 1
  • 2
  • 5
1
vote
1 answer

Changing qemu/libvirt default gateway IPv4 IP to something other than x.x.x.1/24

General info: I have a KVM-libvirt/qemu running on ArchLinux; 3.18.2-2-ARCH ls | egrep -i…
1
vote
4 answers

internal error: unable to execute QEMU command 'cont': Resetting the Virtual Machine is required

I try to install a kvm img in my vps, but after i install it, it show root@wz:~# virsh list Id Name State ---------------------------------------------------- 12 guaji paused and i run…
anyvoleki
  • 9
  • 1
  • 3
1
vote
2 answers

Assigning video card to KVM guest VM with PCI-Pass Through

This is on Ubuntu 12.04LTS using KVM. The system has a graphics card which is visible to the hypervisor's kernel shown as follows: # virsh nodedev-dumpxml pci_0000_21_00_0 pci_0000_21_00_0
AlanObject
  • 662
  • 2
  • 9
  • 20
1
vote
1 answer

kvm - Recover domain from .img file alone

Yesterday I had a drive failure (raid-0) in the host system and had to re-install the os. Fortunately the vps images were on another raid array (raid-5) and the .img files are still available. However when I try to run one of the images, virsh…
Mike Purcell
  • 1,708
  • 7
  • 32
  • 54
1
vote
1 answer

reseting password not working in KVM guest

I lost the root password for a guest system. I mounted the guest system and changed it to single user mode. Then I used virsh console to access the guest system, which was now in single user mode, and used a command echo "root":"123456" | chpasswd…
Purres
  • 239
  • 1
  • 4
  • 18
1
vote
4 answers

Virsh can't connect to ovirt hypervisor

I installed Ovirt and want to add network interface for NAT. So I need to connect to hypervisor by virsh and add nic. Ovirt installed on my local server, host (ovirt-engine.kvmserver.net) is on the same server. I tried to connect in readable mode is…
Abdus
  • 115
  • 1
  • 2
  • 8
1
vote
1 answer

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: And I run the following command: sudo virsh attach-device VMNAME…
D.Mill
  • 379
  • 5
  • 15
1
vote
0 answers

Domus Memory Used Issue With Xen On CentOS

Anyone know why I'm receiving this error? I compiled latest libvirt from source, I also tried with various rpm. I would like to get memory used by domus and it looks like it's not working with Xen 3 on CentOS 5. virsh # dommemstat…
Julio Fong
  • 201
  • 1
  • 3
  • 7
1
vote
0 answers

libvirt virsh not using a predefined target while attaching interface

I am trying to automate the process of creating a Guest VM. I am using uvt-kvm to create the VM. I am also taking a network type as a parameter. This can be either nat or macvtap. Now in the script I create the macvtap interface using these…
akarX_123
  • 11
  • 2
1
vote
1 answer

Migration disabled: vhost-user backend lacks VHOST_USER_PROTOCOL_F_LOG_SHMFD feature

I tried this command on the host. virsh snapshot-create-as --domain test_vm_back --name "snapshot-before-install-package" --description "snapshot test" As you know, this is just a simple command from tutorials to create a snapshot of the VM. The VM…
1
vote
0 answers

How can I blockpull an inactive domain?

For active domain I can do virsh blockpull --domain ... --path ... --base ... I would expect the blockpull should also work with inactive domain since it should be even easier (there is no write operation from guest os interfering the merge…
Wang
  • 292
  • 1
  • 2
  • 11
1
vote
1 answer

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 follows, # virsh list --all Id Name …
user4948798
  • 115
  • 4
1
vote
1 answer

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 to move an existing virtual machine storage from…
Rino Bino
  • 511
  • 5
  • 21
1
vote
1 answer

Copy and paste from a QEMU VM with VNC graphics?

I run a headless server that uses qemu + kvm to run a few VMs, and I manage them with virsh + xml file definitions. Because this a remote / headless system, I set the graphics as VNC, and then with ssh port forwarding, I can use TightVNC / RealVNC…
Jason
  • 11
  • 2