[libvirt-users] Question, how to coorelate snapshot ID's to the files that they represent?
by vonNieda, Adam (USMS)
Hi folks, first post :)
I'm running Redhat 6 x64 with ibvirt-0.10.2-18 and qemu-img-rhev-0.12.1.2-2.355
My question is, if I do something like the following..
[root@testbox ~]# virsh snapshot-list STIGtest
Name Creation Time State
------------------------------------------------------------
1369421485 2013-05-24 13:51:25 -0500 disk-snapshot
1369768781 2013-05-28 14:19:41 -0500 disk-snapshot
1369920434 2013-05-30 08:27:14 -0500 disk-snapshot
1369920574 2013-05-30 08:29:34 -0500 disk-snapshot
1369920859 2013-05-30 08:34:19 -0500 disk-snapshot
1369920888 2013-05-30 08:34:48 -0500 disk-snapshot
1369921298 2013-05-30 08:41:38 -0500 disk-snapshot
Is there another command I can issue to get the OS snapshot file that one of those snapshot names represents?
Thanks very much!
-Adam
--
Adam vonNieda
JMIS technical support
Capgemini Government Solutions
JPATS Kansas City
Desk 816-467-1935
11 years, 7 months
[libvirt-users] Virsh with CPU features on XML file not working!
by Antonio Colín
Hello,
Does anyone have masked their CPU flags with Libvirt?? It's because
I have done so with Libvirt and Virsh compare / baseline. But when
I boot the DomU I see the same flags as if I hadn't declare de <cpu>
tag containing the features just as is described in:
http://libvirt.org/formatdomain.html#elementsCPU
I posted here my XML file definition: http://pastebin.com/ze5wvSZt
I would be really grateful if someone shared your domain XML definition
with me or tell me the syntax. I've been struggling for hours, just
you know, following the documentation available but there is no
functionality for me yet.
Thank you a lot!
Antonio Colín.
11 years, 7 months
[libvirt-users] “Unable to connect to libvirt” (xen, xl toolstack, and virt-manager)
by Gizmo Chicken
I get “Unable to connect to libvirt” when using virt-manager in combination
with the XL toolstack and Xen 4.2.1. (No problems when using virt-manager
in combination with the XM toolstack.) More details of the situation can
be found in a bug-report that I filed on launchpad. Please see:
https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/1180281
Judging from the information that I provided in the above referenced
bug-report (some of which is copied below), does this appear to be an
actual bug? Or have I failed to configure something properly?
Thanks for any help with this!
Best regards,
GizmoChicken
P.S. Here is more of the error that I get when attempting to start
virt-manager:
Unable to connect to libvirt.
unable to connect to 'localhost:8000': Connection refused
Verify that:
- A Xen host kernel was booted
- The Xen service has been started
Libvirt URI is: xen:///
Traceback (most recent call last):
File "/usr/share/virt-manager/virtManager/connection.py", line 1027, in
_open_thread
self.vmm = self._try_open()
File "/usr/share/virt-manager/virtManager/connection.py", line 1009, in
_try_open
flags)
File "/usr/lib/python2.7/dist-packages/libvirt.py", line 102, in openAuth
if ret is None:raise libvirtError('virConnectOpenAuth() failed')
libvirtError: unable to connect to 'localhost:8000': Connection refused
And here the output from var/log/libvirt/libvirtd.log
2013-05-18 05:44:47.614+0000: 1304: info : libvirt version: 1.0.5
2013-05-18 05:44:47.614+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.615+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.617+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.618+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.618+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.619+0000: 1304: error : xenHypervisorDoV2Sys:1006 :
Unable to issue hypervisor ioctl 3166208: Permission denied
2013-05-18 05:44:47.635+0000: 1304: error : do_connect:103 : internal error
failed to connect to xend
2013-05-18 05:44:47.636+0000: 1304: error : xenDaemonOpen_tcp:700 : unable
to connect to 'localhost:8000': Connection refused
2013-05-18 05:45:13.647+0000: 1289: error : virNetSocketReadWire:1362 :
Cannot recv data: Connection reset by peer
11 years, 7 months
[libvirt-users] Trouble running LXC through libvirt
by Shashank Sahni
Hi everyone,
I followed the instructions here to create ubuntu lxc containers.
https://help.ubuntu.com/12.04/serverguide/lxc.html#lxc-admin
I then copied the rootfs to /var/lib/libvirt/images/precise and booted it
as an "operating system container" through virt-manager. Here are the
incidents.
- It immediately showed on console "init: unable to create /dev/kmsg"
but after a while it booted.
- I had modified the image to allow static password for user ubuntu and
I logged in. But to my surprise I wasn't able to use sudo. The error was
"sudo: setuid is not set"
I've tried this image on lxc and it works like a charm. But there seems to
be some issue with libvirt. Some help would be greatly appreciated.
--
Shashank Sahni
11 years, 7 months
[libvirt-users] Help needed regarding "virsh cpu-stats test_vm"
by Anusha Rayani
Hi,
We are implementing feature called CPU separation in the platform. So,
guest VMs will have dedicated cores allocated using cgroups (cgroups
hierachy related VMs managed by libvirt).
virsh cpu-stats command is not working in our platform :
virsh # cpu-stats test_vm
error: Failed to virDomainGetCPUStats()
error: Requested operation is not valid: cgroup CPUACCT controller is not
mounted
It should show info like this.
$ virsh cpu-stats test_vm
CPU0:
cpu_time 0.025812184 seconds
vcpu_time 0.025812184 seconds
CPU1:
cpu_time 4.893484927 seconds
vcpu_time 4.893484927 seconds
Total:
cpu_time 4.924620941 seconds
user_time 1.060000000 seconds
system_time 3.050000000 seconds
We are suspecting some issue in virsh when it is trying to find to where
that cgroups is mounted in a system (default in ubuntu is
/sys/fs/cgroup/cpuset/libvirt/, but in our platform uses /dev/cgroup_xxx).
Find /proc/cgroups and /proc/mounts log below:
==================================
# cat /proc/cgroups
#subsys_name hierarchy num_cgroups enabled
cpuset 0 1 1
ns 0 1 1
cpu 1 3 1
cpuacct 0 1 1
memory 2 1 1
freezer 0 1 1
net_cls 0 1 1
blkio 0 1 1
# cat /proc/mounts
cpu /dev/cgroup_cpu cgroup rw,relatime,cpu 0 0
memory /dev/cgroup_mem cgroup rw,relatime,memory 0 0
Can you please help us in this regard to enable this command in our
platform,
Thanks in advance !!!
Regards,
Anusha
11 years, 7 months
[libvirt-users] Usual number of guests on a host
by Parakkal, Navin S
Hi,
Can someone tell us what is the usual number of guests on a typical host in a production environment ? Has someone tested this ? What number does it scale to ? We have around 150 per host running fine.
Regards,
Navin
11 years, 7 months
[libvirt-users] hangs in libvirt function virLogMessage
by Parakkal, Navin S
Hi,
We are hitting a deadlock on libvirt on 0.9.4 version. Can someone help us ?
1) Is there any way to specify timeout for all the calls made by libvirt especially virConnectOpenReadOnly
2) Does virCommandRunAsync always fork a new process ?
gdb) bt
#0 0x00007fc17b53ce6e in __lll_lock_wait_private () from /lib64/libc.so.6
#1 0x00007fc17b4e3f2d in _L_lock_2164 () from /lib64/libc.so.6
#2 0x00007fc17b4e3ce7 in __tz_convert () from /lib64/libc.so.6
#3 0x00007fc16e4bfdab in virLogMessage () from /usr/lib64/libvirt.so.0
#4 0x00007fc16e4b092e in ?? () from /usr/lib64/libvirt.so.0
#5 0x00007fc16e4b2836 in ?? () from /usr/lib64/libvirt.so.0
#6 0x00007fc16e4b318c in virCommandRunAsync () from /usr/lib64/libvirt.so.0
#7 0x00007fc16e570705 in ?? () from /usr/lib64/libvirt.so.0
#8 0x00007fc16e56a1f8 in ?? () from /usr/lib64/libvirt.so.0
#9 0x00007fc16e55c3d2 in ?? () from /usr/lib64/libvirt.so.0
#10 0x00007fc16e55db10 in ?? () from /usr/lib64/libvirt.so.0
#11 0x00007fc16e52ed95 in ?? () from /usr/lib64/libvirt.so.0
#12 0x00007fc16e52f957 in virConnectOpenReadOnly () from /usr/lib64/libvirt.so.0
#13 0x00007fc153cdb858 in OalibvirtCollectionManager::libvirtColJobImpl::Run (this=0x7fc13182a610)
at ../libvirtColJobImpl.cpp:348
#14 0x00007fc153cd6e83 in OalibvirtCollectionManager::libvirtColJob::Run (this=<value optimized out>)
at ../libvirtColJob.cpp:36
#15 0x00007fc17cc8ee36 in OAScheduler::ScheduleWorker::Run (this=0x7fc15dd9ede0,
myThread=<value optimized out>)
at /svn-share2/BLR.ovpa.11.12.i/linx64/hpsw-oa/AgentFramework/cpp/src/Scheduler/ScheduleWorker.cpp:32
#16 0x00007fc17c04a418 in OvXplThread::ThreadInfo_t::Run() () from /opt/OV/lib64/libOvXpl.so
#17 0x00007fc17c04a6a5 in runThread () from /opt/OV/lib64/libOvXpl.so
#18 0x00007fc17b22f7f1 in start_thread () from /lib64/libpthread.so.0
[root@martellvm6 ~]# virsh version
Compiled against library: libvir 0.9.4
Using library: libvir 0.9.4
Using API: QEMU 0.9.4
error: failed to get the hypervisor version
error: internal error Cannot find suitable emulator for x86_64
[root@martellvm6 ~]# cat /etc/issue
CentOS release 6.2 (Final)
Kernel \r on an \m
11 years, 7 months
[libvirt-users] Help: Using Pre-created tap interfaces with Libvirt+Xen
by Raghu Nallamothu
Hi All.,
I am not sure if this is possible in xen via Libvirt, but what I
am trying to do is, I want libvirt to launch a VM and attach a pre-created
tap interface to that VM ( I do not want XEN to create one, as I am running
a lot of custom scripts on my tap interface). I also dont want xen to
attach this tap interface to a bridge.
For example, lets say I have created a tap interface with name "tap123456"
when libvirt launches my VM in xen, I want the VM to read its networking
info from this tap interface.
But I wasn't so successful in doing this when ever I am trying to do this,
I am seeing the following error message "VmError: Device 0 (vif) could not
be connected. Hotplug scripts not working." and "error: POST operation
failed: xend_post: error from xen daemon: (xend.err 'Device 0 (vif) could
not be connected. Cannot rename interface vif4.0. An interface with name
tap12345 already exists.')". But I dont want xen to create another
interface and rename it, rather want xen to use the existing one
=== output of lsmod ===
bash-4.1# lsmod | grep xen
xen_acpi_processor 4465 0
xen_netback 25455 0 [permanent]
xen_gntdev 9504 2
xen_evtchn 4899 3
xenfs 2943 1
xen_privcmd 4972 19 xenfs
==== end of output ====
My Configuration : Centos 6.2 with Xen 4.2.5 along with Libvirt
Libvirt Configuration file,
<domain type='xen'>
<name>raghu_12345</name>
<uuid>12113325-d948-4a1b-b673-888a16b90726</uuid>
<memory>1048576</memory>
<vcpu>1</vcpu>
<os>
<type>hvm</type>
<loader>/usr/lib/xen/boot/hvmloader</loader>
<boot dev='hd'/>
</os>
<on_poweroff>destroy</on_poweroff>
<on_reboot>restart</on_reboot>
<on_crash>restart</on_crash>
<features>
<pae/>
<acpi/>
<apic/>
</features>
<devices>
<emulator>/usr/lib/xen/bin/qemu-dm</emulator>
<interface type="ethernet">
<mac address='00:25:90:3f:25:91'/> <!-- I want this mac to be mac address
of a vm -->
<target dev='tap123456'/>
</interface>
<disk type='file' device='disk'>
<source file='~/tmp/lucid.img'/>
<target dev='hda'/>
</disk>
<console type='pty'>
<target port='0'/>
</console>
<graphics port='-1' type='vnc' autoport='yes' listen='0.0.0.0'/>
</devices>
</domain>
I have a pre-created tap interface with name 'tap123456' with all the
networking setup with dhcp and dns running.
Thanks for your time and help.
Regards
Raghu
11 years, 7 months