[libvirt-users] some problem with snapshot by libvirt
by xingxing gao
Hi,all,i am using libvirt to manage my vm,in these days i am testing
the libvirt snapshot ,but meet some problem:
the snapshot was created from this command:
snapshot-create-as win7 --disk-only --diskspec
vda,snapshot=external --diskspec hda,snapshot=no
but when i tried to revert from the snapshot which created from the
above command ,i got error below:
virsh # snapshot-revert win7 1338041515 --force
error: unsupported configuration: revert to external disk snapshot not
supported yet
version:
virsh # version
Compiled against library: libvir 0.9.4
Using library: libvir 0.9.4
Using API: QEMU 0.9.4
Running hypervisor: QEMU 1.0.93
10 years
[libvirt-users] virsh list not working with xen 4
by Rogério Vinhal Nunes
Hi, I'm having some trouble to get libvirt to show the correct power state
of my virtual machines. I'm using Ubuntu 10.04 + Xen 4.1.1 + libvirt 0.8.8.
virsh list --all only shows turned off machines registered in xend. If I
turn them on, they just "disappear", and when I start machines directly from
xml, they just doesn't appear at all.
Libvirt is correctly connecting to xen as I can use the other commands fine,
just the list option doesn't seem to work at all. What can I do to change
that?
# virsh version
Compiled against library: libvir 0.8.8
Using library: libvir 0.8.8
Using API: Xen 3.0.1
Running hypervisor: Xen 4.1.0
12 years, 2 months
[libvirt-users] qemu-kvm fails on RHEL6
by sumit sengupta
Hi,
When I'm trying to run qemu-kvm command on RHEL6(linux kernel 2.6.32) then I get following errors which I think related to tap devices in my setup. Any idea why is that?
bash$ LC_ALL=C PATH=/sbin:/usr/sbin:/bin:/usr/bin QEMU_AUDIO_DRV=none /usr/libexec/qemu-kvm -S -M rhel6.2.0 -enable-kvm -m 512 -smp 1,sockets=1,cores=1,threads=1 -name instance-00000027 -uuid a93aeed9-15f7-4ded-b6b3-34c8d2c101a8 -nodefconfig -nodefaults -chardev socket,id=charmonitor,path=/var/lib/libvirt/qemu/instance-00000027.monitor,server,nowait -mon chardev=charmonitor,id=monitor,mode=control -rtc base=utc -no-shutdown -kernel /home/sumitsen/openstack/nova/instances/instance-00000027/kernel -initrd /home/sumitsen/openstack/nova/instances/instance-00000027/ramdisk -append root=/dev/vda console=ttyS0 -drive file=/home/sumitsen/openstack/nova/instances/instance-00000027/disk,if=none,id=drive-virtio-disk0,format=qcow2,cache=none -device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk0,id=virtio-disk0 -netdev tap,fd=26,id=hostnet0 -device rtl8139,netdev=hostnet0,id=net0,mac=fa:16:3e:15:84:3e,bus=pci.0,addr=0x3 -chardev
file,id=charserial0,path=/home/sumitsen/openstack/nova/instances/instance-00000027/console.log -device isa-serial,chardev=charserial0,id=serial0 -chardev pty,id=charserial1 -device isa-serial,chardev=charserial1,id=serial1 -usb -device usb-tablet,id=input0 -vnc 127.0.0.1:0 -k en-us -vga cirrus -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x5
char device redirected to /dev/pts/1
qemu-kvm: -netdev tap,fd=26,id=hostnet0: TUNGETIFF ioctl() failed: Bad file descriptor
TUNSETOFFLOAD ioctl() failed: Bad file descriptor
qemu-kvm: -append root=/dev/vda: could not open disk image console=ttyS0: No such file or directory
[sumitsen@sorrygate-dr ~]$ rpm -qa qemu-kvm
qemu-kvm-0.12.1.2-2.209.el6.x86_64
Let me know if you need any other info.
Thanks,
Sumit
12 years, 4 months
[libvirt-users] [Fwd: error: this function is not supported by the connection driver : virConnectNumOfStoragePool]
by Onkar
Hello All,
Any idea on this issue ?
Regards,
Onkar
-------- Forwarded Message --------
From: Onkar <kernzap(a)gmail.com>
To: libvir-list <libvir-list(a)redhat.com>
Subject: error: this function is not supported by the connection
driver : virConnectNumOfStoragePool
Date: Wed, 30 May 2012 21:29:42 +0530
Hello,
I configured libvirt like this
./configure --prefix=/ --exec-prefix=/usr/ --libdir=/usr/lib64/
--with-storage-dir --with-storage-dir --with-storage-dir
--with-storage-dir --with-storage-dir --with-storage-dir
--with-storage-dir --with-storage-dir --with-qemu --with-libvirtd
--with-selinux --with-network --with-libblkid
and then,
make -j4
make install
and then
# virsh list --all
Id Name State
----------------------------------------------------
- vm1 shut off
# virsh pool-list --all
error: Failed to list active pools
error: this function is not supported by the connection driver:
virConnectNumOfStoragePools
getting this error , any clues on why is this error ?
Regards,
Onkar
12 years, 5 months
[libvirt-users] converting save/dump output into physical memory image
by Andrew Tappert
A lot of people in the security community, myself included, are
interested in memory forensics these days. Virtualization is a natural
fit with memory forensics because it allows one to get access to a
guest's memory without having to introduce any extra software into the
guest or otherwise interfere with it. Incident responders are
particularly interested in getting memory dumps from systems they're
investigating.
Virsh has "save" and "dump" commands for storing the state of a guest to
a file on disk, but memory of KVM guests doesn't get saved in the
"standard" input format for memory forensics tools, which is a raw
physical memory image. (This is what you'd get via the classical "dd
/dev/mem" approach or the contemporary equivalent using the crash
driver; and VMware Server and Workstation produce .vmem files, which are
such raw physical memory images, when a guest is paused or snapshotted.)
In order to analyze the memory of Libvirt/KVM guests with my Linux
memory forensics software, Second Look, I've created a tool for
converting Libvirt-QEMU-save files (output of virsh save command) or
QEMU-savevm files (output of virsh dump command) to raw physical memory
images.
I've got a basic working capability, though I'm still tracking down some
problems with a guest allocated 8GB RAM--not all the memory seems to be
present in the save or dump file. And I haven't tested very extensively
yet, version support is limited to what I myself am currently running, etc.
I'd like to know if this is a capability that others are interested in.
Is this something that would be of interest to the Libvirt project if I
were to contribute the code, or to the KVM project, or do you think it
best exists as a separate project?
I've also got a proof-of-concept tool for converting hibernate images to
raw physical memory images. Perhaps a collection of tools for
converting various memory dump formats would be a good project. Anyone
else interested in this kind of stuff? As an author of commercial
memory forensics software I've got a vested interest in availability of
good memory acquisition capabilities. But there are a number of people
working on FOSS Linux memory analysis tools, too...
Andrew
12 years, 5 months
[libvirt-users] NPIV setup?
by Jason Price
I'm missing something.
The purpose of NPIV (as I understand it) is to give a guest OS an HBA that
it can scan, play with new luns, etc all without making changes to the
physical server(s) the guest is living in currently.
However, I can't find a way to either have the guest's XML config create
the HBA or for the physical server to successfully GIVE the HBA to the
guest. I can give disks all day long, but I can't give the HBA to the
guest.
It seems like libvirt and virsh can only create the vHBA on the physical
box, which defeats the purpose of working with NPIV then... I can just
present the same luns to the REAL WWPNs of the physical boxes that need
access, setup multipathd to give /dev/mapper names in a consistent manner,
and give the raw disks to the guests.
I really want to get the physical KVM servers out of the 'storage
management' game aside from the basic OSes of the guests. How can I do
that?
(or am I missing something?)
--Jason
12 years, 5 months
[libvirt-users] win-xp guest after reboot: could not open disk image /dev/sr0: mo medium found and extreme sluggisch
by Ekkard Gerlach
Hi,
win-xp won't boot after installation. The CD is needed to boot from. How can I
convince win-xp to boot?
That's what I did:
==================
I installed win-xp guest on debian squeeze:
# virt-install --connect qemu:///system --name winxp-prof --ram 1024 \
--disk path=/dev/vg-levo/winxp-kvm,size=10 \
--network bridge:br0 --vnc --os-variant winxp --cdrom /dev/sr0
/dev/vg-levo/winxp-kvm is a lvm (logical volume, 10GB)
Installation worked, but was extrem slow. Machine: Lenovo B560, core i3, 6 GB RAM.
WinXP made a normal reboot after installation, I ejected install cd, then:
virt-manager output:
Error starting domain: internal error Process exited while reading console log output:
chard device redirected to /dev/pts/2
qemu: could not open disk image /dev/sr0: mo medium found
So I inserted the CD and a black blanc screen appeared. Windows didn't boot.
I deleted installation configuration: # virsh undefine winxp-prof
I invoked virt-install (see above) once again ... and win-xp is booting ... what
a surprise, without installing again after undefine .. ! The reason: the lvm partition
was not deleted.
WinXP now always needs a CD to boot and is extreme sluggisch. Right mouse click lasts about
one minute!
tia
Ekkard
12 years, 5 months
[libvirt-users] Virtual Machines Stay Off If Rebooted
by Andrew Martin
Hello,
I am using libvirt on Ubuntu 10.04 Server and the following versions of these packages:
libvirt-bin, libvirt0, python-libvirt - 0.7.5-5ubuntu27.22
qemu-kvm 0.12.3+noroms-0ubuntu9.18
Recently, when restarting a VM (either by issuing "sudo reboot" on a Linux guest or choosing "Restart" from the Start Menu on a Windows guest) the VM shuts down and remains off rather than simply restarting. I cannot test "virsh restart <domain>" on this server as the version of libvirt does not appear to support restarting - see https://bugs.launchpad.net/ubuntu/+source/libvirt/+bug/368962
I do not receive any errors in /var/log when the shutdown occurs. Powering the VM back on works, however I would prefer to have hot restart working so VMs that are automatically rebooted to install updates will come back up automatically. Do you have any suggestions on how to debug this behavior?
Thanks,
Andrew
12 years, 5 months
[libvirt-users] How to configure cpu frequency of guest
by hongming
Hi Experts
I want to know how to configure cpu frequency of guest. Why it always
display "cpu MHz : 3092.974" , If it needs to offer user a KVM guest
with 1 GHz cpu using libvirt , How to do it ? Thanks a lot in advance.
Hongming
12 years, 5 months
[libvirt-users] how to store an internal disk snapshot by use
by Rujie Xu
Hello everyone,
I am trying to find a way to store an internal disk snapshot and
supposed to restore later.
Here is the problems I met:
1) when I use SnapshotCreateXML() to create a disk_only snapshot while
the domain is inactive, there is an error happened:
disk snapshot of inactive domains not implemented yet.
I am wondering is there and way I can save the disk_only snapshot when
the domain is inactive right now?
2) also use snapshotCreateXML() to create a disk_only snapshot while
the domain is active, and use the xml to set the <disk name="hda"
snapshot="internal"> there is also an error happened:
unsupported configuration: active qemu domains require external disk
snapshot; disk hda requested internal
3) when I use snapshotCreateXML() to create a disk_only snapshot using
external file, it could be done, but when I try to use revertToSnapshot()
to revert this snapshot there is another error happened:
revert to external snapshot not supported yet.
Is there anyone can help me about this, or we just can't use libvirt to
managed the disk snapshot right now?
Thanks very much!
--
Best Regards,
Roger Xu
12 years, 5 months