Libvir Qemu Error Cannot Change To
Contents |
of setvcpus Date: Fri, 09 Aug 2013 17:01:01 +0200 Am 09.08.13 15:09, schrieb Eric Blake: > On 08/09/2013 06:26 '/var/run/libvirt/libvirt-sock': no such file or directory AM, Thomas Stein wrote: >> Hello. >> >> Does someone
Qemu-kvm Could Not Open Disk Image Permission Denied
know in what state setvcpu command is? >> >> I get: >> >> virsh # libvirt cannot access storage file setvcpus gentookvm 4 >> error: internal error: cannot change vcpu count of this domain >> >> and >> >> error : qemuDomainHotplugVcpus:4087 : internal error: virsh error: failed to connect to the hypervisor cannot change vcpu >> count of this domain >> >> Does this work for someone? > > It works for xen:// URIs. Upstream qemu vcpu hotplug is still a work in > progress; I don't know if qemu 1.6 will support it, or if you'll have to > wait for qemu
Error: Failed To Connect Socket To '/var/run/libvirt/libvirt-sock': Permission Denied
1.7. Meanwhile, you can try using 'setvcpus gentookvm > --guest 4' to use the guest agent (assuming you have qemu-ga running in > the guest, and the proper plumbing of the guest agent channel in your > domain XML) to use the guest to take vcpus on- or offline. Tried that with no luck so far. virsh # setvcpus gentookvm --guest 2 error: internal error: unable to execute QEMU agent command 'guest-get-vcpus': The command guest-get-vcpus has not been found It's qemu-1.4.2 and libvirt-1.1.1. In general it seems to work. virsh # shutdown 3 --mode agent Domain 3 is being shutdown Any hints? And once again, thanks for your support Eric. cheers t. Follow-Ups: Re: [libvirt-users] state of setvcpus From: Eric Blake References: [libvirt-users] state of setvcpus From: Thomas Stein Re: [libvirt-users] state of setvcpus From: Eric Blake [Date Prev][Date Next] [Thread Prev][Thread Next] [Thread Index] [Date Index] [Author Index]
navigation, search Contents 1 Libvirt FAQ 1.1 General 1.1.1 What is libvirt? 1.1.2 I heard someone say they 'use libvirt'. What do they mean? 1.1.3 How do I know if I am using libvirt? 1.1.4 What is some of the major functionality error: no connection driver available for qemu:///system provided by libvirt? 1.1.5 What hypervisors does libvirt support? 1.1.6 How can I check failed to connect socket to '/var/run/libvirt/virtlogd-sock': no such file or directory my libvirt version? 1.1.7 What are the libvirt mailing lists/IRC? 1.1.8 Where should I report libvirt bugs? 1.1.9 Is libvirt the
Cannot Read Ca Certificate '/etc/pki/ca/cacert.pem': No Such File Or Directory
'lowest common denominator' of hypervisor features? 1.2 Common VM Configuration 1.2.1 What is the 'virsh edit' command and how do I use it? 1.2.2 Where are VM config files stored? How do I edit a https://www.redhat.com/archives/libvirt-users/2013-August/msg00037.html VM's XML config? 1.2.3 If I change the XML of running machine, do the changes take immediate effect? 1.2.4 How do I shutdown my VMs? 1.2.5 Will restarting the libvirt daemon stop my virtual machines? 1.3 Common Errors 1.3.1 My VM doesn't show up with 'virsh list' 1.3.2 Error: Failed to add tap interface 'vnet%d' to bridge 'virbr0' No such file or directory 1.3.3 Error: unable to connect to '/var/run/libvirt/libvirt-sock' 1.3.4 http://wiki.libvirt.org/page/FAQ Why doesn't 'shutdown' seem to work? 1.3.5 Error: domain did not show up 1.3.6 Error: monitor socket did not show up.: Connection refused 1.3.7 My VM fails to start. What should I do? 1.3.8 error: Unknown Failure 1.3.9 internal error: canonical hostname pointed to localhost, but this is not allowed 1.3.10 error: operation failed: migration to '...' failed: migration failed 1.3.11 networking is unavailable in virt-manager / virsh - libvirt's default network fails to start 1.4 Migration 1.4.1 What are the different migration methods? 1.4.2 What setup is required for QEMU/KVM migration? 1.5 QEMU/KVM 1.5.1 Can I connect to the QEMU monitor with libvirt? 1.5.2 What monitor commands does libvirt support? What QEMU/KVM command line flags does libvirt support? 1.5.3 What is the difference between qemu:///system and qemu:///session? Which one should I use? 1.6 Networking 1.6.1 What is libvirt doing with iptables? 1.6.2 How can I make libvirt stop using iptables? 1.6.3 Why doesn't libvirt just auto configure a regular network bridge? 1.6.4 How do I manually configure a network bridge? 1.6.5 How do I get my VM to use an existing network bridge? 1.7 How do I forward incoming connections to a guest that is connected via a NATed virtual network? = 1.8 Developing with libvirt 1.8.1 What is libvir
people Affects Status Importance Assigned to Milestone libvirt (Ubuntu) Edit Fix Released Undecided Unassigned Edit You need to log in https://bugs.launchpad.net/bugs/599910 to change this bug's status. Affecting: libvirt (Ubuntu) Filed here by: Charles Curley When: 2010-06-29 Confirmed: 2010-07-02 Started work: 2010-07-02 Completed: 2010-07-02 Target Distribution Baltix BOSS Juju https://forum.opennebula.org/t/libvirtd-running-as-root-tries-to-access-oneadmin-nfs-mount-error-cant-canonicalize-path/2054 Charms Collection Elbuntu Guadalinex Guadalinex Edu Kiwi Linux nUbuntu PLD Linux Tilix tuXlab Ubuntu Ubuntu Linaro Evaluation Build Ubuntu RTM Package (Find…) Project (Find…) Status Importance Fix no such Released Undecided Assigned to Nobody Me Comment on this change (optional) Email me about changes to this bug report Nominated for Lucid by jdobry Also affects project (?) Also affects distribution/package Nominate for series Bug Description I just upgraded my desktop from Kosmic Koala to Lucid Lynx, and upgraded to the latest. Everything worked no such file fine prior to the upgrade except some unrelated networking issues. I now find that I cannot launch any virtual machines using libvirt/qemu/kvm and libvirt-manager. If I try to launch a VM having only a CD-ROM image for bulk storage, I get: File "/usr/share/virt-manager/virtManager/engine.py", line 588, in run_domain vm.startup() File "/usr/share/virt-manager/virtManager/domain.py", line 150, in startup self._backend.create() File "/usr/lib/python2.6/dist-packages/libvirt.py", line 300, in create if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self) libvirtError: internal error unable to start guest: libvir: QEMU error : cannot set ownership on /var/lib/libvirt/images/finnix-93.0.iso: Permission denied This is a known bug: https://bugzilla.redhat.com/show_bug.cgi?id=517304 (I don't see any comparable bug in launchpad.) If I try to launch a VM with only a virtual hard drive, I get: File "/usr/share/virt-manager/virtManager/engine.py", line 588, in run_domain vm.startup() File "/usr/share/virt-manager/virtManager/domain.py", line 150, in startup self._backend.create() File "/usr/lib/python2.6/dist-packages/libvirt.py", line 300, in create if ret == -1: raise libvirtError ('virDomainCreate() failed', dom=self) libvirtError: internal error unable to start guest: libvir: QEMU error : cannot change to '
to make a VM, it's engaging the libvirtd daemon, which itself runs as root, to create the VM then fails with a "can't canonicalize path" message. Checking further it seems virsh, or some function in it, is trying to access the NFS mount as root. I have squash_root enabled and for security reasons I need to keep it. But then how do I get around it? Should I just point VM creation to the node's existing datastore (ie SAN, DAS) or is there a way around this to allow VM creation on the NFS mount wo/ using no_root_squash? The direct VM creation on the node works without an NFS mounted but for future NFS usage, I would like to resolve it so it can use NFS successfully. I considered running libvirtd as a non-root user but it unsurprisingly asked for root credentials to start up. [oneadmin@mdskvm-p01 ~]$ virsh --connect qemu:///system create /var/lib/one//datastores/0/38/deployment.0error: Failed to create domain from /var/lib/one//datastores/0/38/deployment.0error: can't canonicalize path '/var/lib/one//datastores/0/38/disk.1': Permission denied [oneadmin@mdskvm-p01 ~]$ ps -ef|grep -i libvirtdroot 12564 1 0 00:18 ? 00:00:00 /usr/sbin/libvirtdoneadmin 14853 12479 0 00:23 pts/1 00:00:00 grep --color=auto -i libvirtd[oneadmin@mdskvm-p01 ~]$ As oneadmin, I tested file creation on the NFS and it's working fine as oneadmin. I synced the permissions of the mount point to the remote /var/lib/one from the controller but this didn't help either. Any chance as well to disable canonicalization of paths in libvirtd ? Cheers,TK VURoland (Roland) 2016-04-05 19:14:15 UTC #2 hi TomK, what you've probably missed is allowing oneadmin to control libvirtd on your hosts. We have the exact same setup and made sure that the UID on the NFS host and the opennebula servers is the same (in our case we used 9869 for UID user and UID group) and made him member of the following groups on the virt. servers: id oneadmin uid=9869(oneadmin) gid=9869(oneadmin) groups=9869(oneadmin),27(sudo),113(kvm),114(libvirtd) Then you configure libvirtd to allow oneadmin to control libvirtd as root, locally, on every hypervisor server.(source:http://docs.opennebula.org/4.14/design_and_installation/quick_starts/qs_ubuntu_kvm.html) 2.5. Configure QemuThe oneadmin user must be able to manage libvirt as root:cat << EOT > /etc/libvirt/qemu.confuser = "oneadmin"group = "oneadmin"dynamic_ownership = 0EOT Restart libvirt to capture these changes: # service libvirt-bin restart Like this, we can leave squash_root as NFS option. This is just how we have done it, there's probably many more (prob. even better) ways to do it. Hope this helps you with finding a solution. TomK (Tom