[libvirt-users] File permissions on VNC unix sockets
by Landon Gilbert-Bland
I am using kvm libvirt/qemu, and am trying to get VNC working with unix
sockets. I'm using the following in my XML:
<graphics type='vnc' socket='/tmp/kvmtest'/>
This works, it creates the unix socket and I can use it for VNC. But it
creates the socket with 755 permissions, and owned by libvirt-qemu:kvm.
Ideally, I would like it to be 770 root:libvirtd, but could also work
with 775 libvirt-qemu:kvm.
Basically, I would like the group to be read/write/execute, so that
anyone in this group can use virt-manager (or whatever) to get into the
vm with vnc. I haven't found a way to change this in the settins. It
doesn't seem to be honoring the unix socket settings in
/etc/libvirt/libvirdd.conf (it looks like those are only for
libvirt-sock and libvirt-sock-ro), and I haven't been able to find any
documentation about changing these permissions in the XML.
I can manually chmod/chown the socket after it is created (manually or
with a cron), but that is far from an ideal solution. I don't suppose
anyone has run across a configuration option for this that I have missed?
I have only tested this in ubuntu 14.04.1 and debian testing, for what
it's worth.
Thanks,
--landon
10 years, 3 months
[libvirt-users] [help] Does "virsh blockpull" works on live virtual machine
by chenyanqiu@keytonecloud.com
Hi all,
I have a kvm virtual machine running (qemu version 2.0), and I had took several external snapshots of the disk( using "virsh snapshot-create-as"). Now, the existed disk files relationship look like: base <- snap1 <-snap2 <- current using disk file. Now I want to remove snap1 and snap2, and let current disk using the base image file as back file directly. Unfortunately, for some reason, I can not shutdown the vm, and exectue the "virsh blockpull" command. Can I execute the "virsh blockpull" while the vm is power on, and the application in the vm is not affected?
Thanks very much!
Daniel
10 years, 3 months
[libvirt-users] possible to dynamically set/add network domain name?
by Rich Megginson
trying to use virsh net-update to add a domain name
libvirt-1.1.3.5-2.fc20.x86_64
sudo virsh net-update default add domain "<domain name='test'/>" --live
--config
error: this function is not supported by the connection driver: can't
update 'domain' section of network 'default'
is it possible to add a domain using net-update?
10 years, 3 months
[libvirt-users] username and passwd after create VM from XML dump
by Yuanzhen Gu
Good afternoon guys,
I created the VM from XML dump,
# virsh create vm4.xml
and # virsh list I can see the VM running,
and I know the ip address for the VM,
but how can I know the username and password to login the running VM, which
is created from XML dump? is there any place to edit and add the username
and password in guest domain XML ? thanks a lot!!
Best,
Yuanzhen
10 years, 3 months
[libvirt-users] Ubuntu Trusty: failed to create VM due to permission denied
by Jianfeng Tang
>
Hi, libvirt experts,
I used libvirt to create a VM and used backing store to a local file. It
works fine until I installed my box to Unbuntu Trusty (14.04). I got the
following errors when I tried to start the VM:
Could not open backing file: Could not open <path to my backing file>:
Permission denied
However, if I moved my image file (not base image) to default location
/var/lib/libvirt/images. It works.
It seems something related to selinux. However, my box seems not have
selinux installed at all.
Anyone knows how to fix this?
Thanks,
~Frank
>
10 years, 3 months
[libvirt-users] error configuring a public bridge --> uvt-kvm: error: libvirt domain 'newtest' has no NIC MACs available.
by Jordi Arjona
Hi all,
First at all, excuse if this is not the right place for sending this email.
I'm using ubuntu 14.04 server edition and i'm trying to deploy some virtual
machines in a server in such a way that they are visible in the same
network that the host machine.
The tools I'm using are the uvtool package and libvirt.
The error I'm getting is the following:
"uvt-kvm: error: libvirt domain 'newtest' has no NIC MACs available."
Here I'm providing the quickest way (I think) of reproducing my problem.
The steps to follow would be:
1) Creating a bridge. This is my /etc/network/interfaces
# This file describes the network interfaces available on your system
# and how to activate them. For more information, see interfaces(5).
# The loopback network interface
auto lo
iface lo inet loopback
auto em1
iface em1 inet manual
auto br0
iface br0 inet static
address 9.109.124.62
network 9.109.124.0
netmask 255.255.255.0
broadcast 9.109.124.255
gateway 9.109.124.1
#iface br0 inet dhcp
bridge_ports em1
bridge_stp off
bridge_fd 0
bridge_maxwait 0
dns-search xx.xx.xx.xx
dns-nameservers 192.168.122.1 9.0.146.50 9.0.148.50
2) downloading a trusty tahr cloud image and run it
uvt-simplestreams-libvirt sync release=precise arch=amd64
uvt-kvm create test release=trusty
3) duplicate the xml generated when running the machine in order to modify
the network interface by the bridge one. In the XML I also remove the uuid
and change the VM name.
sudo mv /etc/libvirt/qemu/test.xml /etc/libvirt/qemu/test2.xml
In test 2 the most relevant change is replacing
<interface type='network'>
<mac address='52:54:00:86:7a:31'/>
<source network='default'/>
<model type='virtio'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x03'
function='0x0'/>
</interface>
by
<interface type='bridge'>
<source bridge='br0'/>
<model type='virtio'/>
</interface>
4) Once I have my new XML, I define and start the new machine
uvt-kvm destroy test
virsh undefine test
sudo virsh define /etc/libvirt/qemu/test2.xml
virsh start newtest (newtest is the name provided in test2.xml)
5) Up to this point everything seems to be fine, but if i run a wait
command i get the error
uvt-kvm wait newtest --insecure
uvt-kvm: error: libvirt domain 'newtest' has no NIC MACs available.
I have checked the xml generated when defining newtest and there is a MAC
in there, so it is not a problem generating a MAC address. Also the
interface br0 is visible for virsh:
virsh iface-list
Name State MAC Address
---------------------------------------------------
br0 active xx:xx:xx:xx:xx:xx
lo active 00:00:00:00:00:00
I have been googling for a while and couldn't find anything but this:
http://pastebin.com/em0hmy4t
That tries something similar and falls in the same error.
Any help will be very much appreciated. It is the first time i send
anything to one of this mail lists, so, please, if you need me to provide
any other info, tell me.
Thanks!
Jordi
10 years, 3 months
[libvirt-users] How to import libvirt library in Java
by Restituto Marcus Arevalo
Hi, I am trying to get the CPU/Memory usage of the VMs in KVM using Java. But before I get to start coding, I have no idea where to get the libvirt library and how to import it in Java. Does anyone know where I can get it and how I'll be able to use its library? Thanks
regards,
Marco
10 years, 3 months
Re: [libvirt-users] [libvirt] help
by Michal Privoznik
[Dropping libvirt-announce list]
On 05.08.2014 11:47, Himanshu Sharma wrote:
> Dear Team,
> Greetings!!
>
> I'm testing libvirt with VMware ESXi. I'm able to connect to VMware ESXi with libvirt driver but not able to connect it through "Virtual Machine manager" GUI also not able to run virt-clone command inturn to clone ESXi VM. Can you please guide me how to do so?
>
The virt-manager does not support ESX yet. It merely supports QEMU/KVM,
XEN and LXC. And for the virt-clone issue:
1) "computer broken" is usually not much descriptive. Is there any error
message you are seeing? What behavior are you experiencing?
2) virt tools have a separate mailing list:
http://www.redhat.com/mailman/listinfo/virt-tools-list
Try asking there.
Usually it's considered bad practice to repeat your question every 5
minutes, crosspost it over several mailing lists (even libvirt-announce
which is not user support channel but a low traffic list for
announcements as it name suggests) or forward the e-mail that is
irrelevant (Welcome to the list).
Michal
10 years, 3 months