[libvirt-users] HostDevev SCSI Devices
by Fl@sh
http://libvirt.org/formatdomain.html#elementsHostDevSubsys
At this description used "drive"-typed address for SCSI.
But when i get xml-description of scsi-devices by
<code>
unsigned int flags =
VIR_CONNECT_LIST_NODE_DEVICES_CAP_SCSI_HOST ;
int ret = virConnectListAllNodeDevices
(currWorkConnect, &nodeDevices, flags);
then get by virNodeDeviceGetXMLDesc(nodeDevices[i], 0));
</code>
i have same:
<device>
<name>scsi_host2</name>
<path>/sys/devices/pci0000:00/0000:00:1f.2/ata3/host2</path>
<parent>pci_0000_00_1f_2</parent>
<capability type='scsi_host'>
<host>2</host>
<unique_id>3</unique_id>
</capability>
</device>
.
I understand that this device description contains a
"pci"-typed addresses. Then where to get the "scsi"-typed
address?
--
Fl@sh
10 years, 1 month
[libvirt-users] drive-backup command permission denied.. and need some clarification
by Jd
Hi
* Trying to get drive-backup command, getting permission denied. :(
sudo virsh qemu-monitor-command --hmp my-instance --cmd
drive_backup drive-virtio-disk0 /tmp/foo.vda.img
Looks like apparmor issue. What can I modify to make this work ?
* Couple of other questions
drive-backup :
* The doc seems to claim that it gives a point in time copy
of the drive. So I assume that no need to take any snapshot etc.. and
merge back in.
* does it internally use snapshot ? Does this hook in to
doing fsfreeze and unfreeze using guest agent and does it automagically
? I do not see any options here.
* Suppose I have base <-- sn1 --<-- sn2 (QEMU active) . does
it take data from sn2 only ? or base+sn1+sn2 .. full drive and creates
a new qcow2 sparse file.
Thanks
/Jd
10 years, 1 month
[libvirt-users] Fwd: Hotadd memory and hotplug cpu
by ra va
Hello,
Does KVM support hotadd memory and hot-plug cpu?
I checked it using the virsh command but I can only increase the memory to
the maximum memory that is initially set
But setmaxmem command is failing. Which means this require a reboot of the
guest
# virsh setmaxmem 4 1048576
error: Unable to change MaxMemorySize
error: Requested operation is not valid: cannot resize the maximum memory
on an active domain
#virsh setvcpus 4 4
error: internal error: unable to execute QEMU command 'cpu-add': Not
supported
Thanks
ravargs
10 years, 1 month
[libvirt-users] VGA as vfio-pci and vnc server's blank/black display
by lejeczek
hi,
I'm having a Radeon as vfio-pci, which seems to work
perfectly fine, but...
Qemu's model type='vga' gets "exlaimed" in win2k8's Device
Manager with:
"
Windows has stopped this device because it has reported
problems. (Code 43)
"
Now, that does not bother me that much as all I need on
regular basis is RDP but VNC connection gets me nowhere.
I get blank/black screen, it connects without
errors/problems but nothing more.
I know you would say VGA passthrough is only supported for
very few VGA adapters but is the situation I describe
normal/expected?
regards
10 years, 1 month
Re: [libvirt-users] passthrough of PCI-device
by Weis, Michael (DWIE)
Good morning,
there is a typo in my description;
the line
<address domain='0x0' bus='0x1' slot='0x00' function='0x0'/>
should be
<address domain='0x0' bus='0x2' slot='0x00' function='0x0'/>
That was correct in my xml-file.
Isn't there anybody how can help me with that?
Regards
Michael Weis
Von: Weis, Michael (DWIE)
Gesendet: Dienstag, 7. Oktober 2014 11:45
An: 'libvirt-users(a)redhat.com'
Betreff: passthrough of PCI-device
Hello,
I try to passthrough a PCI-card to a VM named testvm
I want to do that with an xml-file named hga.xml including the following content:
<hostdev mode='subsystem' type='pci' managed='yes'>
<source>
<address domain='0x0' bus='0x1' slot='0x00' function='0x0'/>
</source>
</hostdev>
When I execute
virsh attach-device testvm hga.xml
I get the following error:
Fehler: Fehler beim Anhängen des Geräts von hga.xml
(error: error while attaching device from hga.xml)
Fehler: Interner Fehler: Kann Qemu-Befehl 'device_add' nicht ausführen: Device initialization failed.
(error: internal error: cannot execute 'device_add':
In the syslog of the host I get the following errors:
Oct 7 11:32:34 artemis2 journal: Interner Fehler: Kann Qemu-Befehl 'device_add' nicht ausführen: Device initialization failed.
Oct 7 11:32:53 artemis2 kernel: ffff880220fadd10 ffffffff810f924a ffff880220fadd28 0000000000000246
Oct 7 11:32:53 artemis2 kernel: ffff8800bd07a400 000000007265756d ffffffffa0866ee0 0000000000000000
Oct 7 11:32:53 artemis2 kernel: Call Trace:
Oct 7 11:32:53 artemis2 kernel: [<ffffffff815e237b>] dump_stack+0x19/0x1b
Oct 7 11:32:53 artemis2 kernel: [<ffffffff810f924a>] __setup_irq+0x54a/0x570
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa0866ee0>] ? virqfd_wakeup+0xc0/0xc0 [vfio_pci]
Oct 7 11:32:53 artemis2 kernel: [<ffffffff810f93cc>] request_threaded_irq+0xcc/0x170
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa0866b8a>] vfio_intx_set_signal+0x10a/0x1f0 [vfio_pci]
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa08670e8>] vfio_pci_set_intx_trigger+0xc8/0x1b0 [vfio_pci]
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa086799b>] vfio_pci_set_irqs_ioctl+0x7b/0x100 [vfio_pci]
Oct 7 11:32:53 artemis2 kernel: [<ffffffff8115d352>] ? memdup_user+0x42/0x70
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa0865e74>] vfio_pci_ioctl+0x314/0xa00 [vfio_pci]
Oct 7 11:32:53 artemis2 kernel: [<ffffffff81194b6a>] ? kmem_cache_alloc+0x1ba/0x1d0
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811b156c>] ? get_empty_filp+0x5c/0x190
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811f1891>] ? fsnotify+0x251/0x350
Oct 7 11:32:53 artemis2 kernel: [<ffffffff81251806>] ? security_file_alloc+0x16/0x20
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811b15a0>] ? get_empty_filp+0x90/0x190
Oct 7 11:32:53 artemis2 kernel: [<ffffffffa084f163>] vfio_device_fops_unl_ioctl+0x23/0x30 [vfio]
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811c2af5>] do_vfs_ioctl+0x2e5/0x4c0
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811af780>] ? vfs_write+0x160/0x1e0
Oct 7 11:32:53 artemis2 kernel: [<ffffffff811c2d71>] SyS_ioctl+0xa1/0xc0
Oct 7 11:32:53 artemis2 kernel: [<ffffffff815f2a59>] system_call_fastpath+0x16/0x1b
Oct 7 11:32:53 artemis2 journal: Interner Fehler: Kann Qemu-Befehl 'device_add' nicht ausführen: Device initialization failed.
My version-information:
OS: CentOS Linux release 7.0.1406 (Core)
Kernel: Linux artemis2 3.10.0-123.8.1.el7.x86_64
libvirt-daemon-driver-secret-1.2.8-1.el7.centos.x86_64
libvirt-1.2.8-1.el7.centos.x86_64
libvirt-daemon-kvm-1.2.8-1.el7.centos.x86_64
libvirt-client-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-qemu-1.2.8-1.el7.centos.x86_64
libvirt-daemon-config-network-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-interface-1.2.8-1.el7.centos.x86_64
libvirt-daemon-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-nodedev-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-storage-1.2.8-1.el7.centos.x86_64
libvirt-daemon-config-nwfilter-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-network-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-lxc-1.2.8-1.el7.centos.x86_64
libvirt-daemon-driver-nwfilter-1.2.8-1.el7.centos.x86_64
The PCI-Card I want to passthrough:
02:00.0 Ethernet controller: PLX Technology, Inc. Device 235e
Subsystem: PLX Technology, Inc. Device 235e
Control: I/O- Mem- BusMaster- SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx-
Status: Cap+ 66MHz- UDF- FastB2B+ ParErr- DEVSEL=medium >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
Interrupt: pin A routed to IRQ 16
Region 0: Memory at f0810000 (32-bit, non-prefetchable) [disabled] [size=256]
Region 1: I/O ports at e000 [disabled] [size=256]
Region 2: Memory at e0000000 (32-bit, non-prefetchable) [disabled] [size=256M]
Region 3: Memory at f0000000 (32-bit, non-prefetchable) [disabled] [size=8M]
Expansion ROM at f0800000 [disabled] [size=64K]
Capabilities: [40] Power Management version 1
Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
Capabilities: [48] CompactPCI hot-swap <?>
Capabilities: [4c] Vital Product Data
Unknown large resource type 35, will not decode more.
Kernel driver in use: vfio-pci
Please help.
Best regards
Michael Weis
PROPRIETARY: This e-mail contains proprietary information some or all of which may be legally privileged. It is intended for the recipient only. If an addressing or transmission error has misdirected this e-mail, please notify the authority by replying to this e-mail. If you are not the intended recipient you must not use, disclose, distribute, copy, print, or rely on this e-mail.
10 years, 1 month
[libvirt-users] Fixed Public IP to VM Guest
by Joel A Divekar
Hi All
We have setup a Centos7 host server with KVM and have created multiple VM running Ubuntu 14.04 using virt-manager. All VMs are having forward mode as "NAT" and using internal DHCP IP address 192.168.122.x series and we gave them fixed ips based on their mac address. Now all these VMs are able to access Internet and able to run update on all these guest OS. But these VMs are web and API servers and they are required to be accessible from Internet.
We have pool of public IPs and have assigned host with one public IP for example, we have pool like 192.168.111.1 to 192.168.111.25. We have assigned 192.168.111.2 to Host server and would like to assign 192.168.111.3 to Webserver and 192.168.111.4 to API server. So we changed our virsh network settings from default to routed as <forward mode='route' dev='em1'> and struggling to configure fixed IPs for our VMs. We would like to do exactly as mentioned in this link https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/...
We have been struggling with this for last 3 days and no luck. Please can anybody guide us.
Regards
Joel Divekar
10 years, 1 month
[libvirt-users] live migration to localhost with lvm based storage
by Vasiliy Tolstov
I have lvm based (thin pool) storage on local disks. I need to move
vps from one vg on one disk to another. Does it possible to migrate to
localhost with blockcopy migration to another vg?
I'm understand that i can move lv from one vg to another, but i don't need that.
--
Vasiliy Tolstov,
e-mail: v.tolstov(a)selfip.ru
jabber: vase(a)selfip.ru
10 years, 1 month
[libvirt-users] is memoryBacking support 'share' and 'mem-path' parameter
by Linhaifeng
Hi,
I want to use this qemu command '-object memory-backend-file,id=mem,size=2048M,mem-path=/mnt/huge,share=on' with libvirt but i can't find the 'mem-path' and 'share' in the documentation.
because the vhost-user backend based on 'share=on' parameter and libvirt support vhostuser i guess there maybe another way to support this parameter?
this is my xml:
<cpu>
<numa>
<cell id='0' cpus='0' memory='1048576' memAccess='shared'/>
<cell id='1' cpus='1' memory='1048576' memAccess='shared'/>
</numa>
</cpu>
<memoryBacking>
<hugepages>
<page size="2" unit="M" nodeset="0,1"/>
</hugepages>
<!--nosharepages/-->
<!--locked/-->
</memoryBacking>
<interface type='vhostuser'>
<mac address='52:54:00:3b:83:1a'/>
<source type='unix' path='/path/port1' mode='client'/>
<model type='virtio'/>
</interface>
<interface type='vhostuser'>
<mac address='52:54:00:3b:83:1b'/>
<source type='unix' path='/path/port2' mode='client'/>
<model type='virtio'/>
</interface>
when i create the VM the qemu command is like this without 'share=on' parameter:
-object memory-backend-file,prealloc=yes,mem-path=/dev/hugepages/libvirt/qemu,size=1024M,id=ram-node0 -numa node,nodeid=0,cpus=0,memdev=ram-node0
-object memory-backend-file,prealloc=yes,mem-path=/dev/hugepages/libvirt/qemu,size=1024M,id=ram-node1 -numa node,nodeid=1,cpus=1,memdev=ram-node1
10 years, 1 month
[libvirt-users] Question about vnc connection password set to empty
by Wei Zhang
Hello, everybody
here I have a question about graphical buffers for rhel7. Thanks so much in advance who can give me some suggestions about that.
When I try to do regression for bug859317(https://bugzilla.redhat.com/show_bug.cgi?id=859317) on RHEL7, I found that guest could be connected success with virt-viewer when set/update the graphics passwd to empty.
But according to comment 2 in this bug, libvirt will blocks all access to the VNC server when set a password to empty.
So could you please help us check is it acceptable on RHEL7?
Below is my test steps on RHEL7:
Version-Release number of selected component (if applicable):
libvirt-1.2.8-3.el7.x86_64
qemu-kvm-rhev-2.1.0-5.el7.x86_64
kernel-3.10.0-150.el7.x86_64
How reproducible:
100%
Steps to Reproduce:
1. Define guest with a graphics device like:
.........................................
<graphics type='vnc' port='-1' autoport='yes' passwd=""/>
.........................................
2. Connecting with vncviewer or virt-viewer .
# virsh start dom2
# virsh dumpxml dom2 --security-info |grep graphics
<graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' passwd=''>
</graphics>
# virt-viewer dom2
connect the guest success with empty password
3. The problem can be reproduced when changed the graphics passwd from an non-empty to an empty
# virsh dumpxml dom2 --security-info |grep graphics
<graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' passwd='123'>
</graphics>
# cat change-passwd.xml
<graphics type='vnc' port='-1' autoport='yes' listen='127.0.0.1' passwd=''/>
# virsh update-device dom2 change-passwd.xml
# virsh dumpxml dom2 --security-info |grep graphics
<graphics type='vnc' port='5900' autoport='yes' listen='127.0.0.1' passwd=''>
</graphics>
login the guest with virt-viewer command
# virt-viewer testks
also can connect the guest dom2 success with empty password
4. I produce the same steps on RHEL6.6 libvirt-0.10.2-46.el6.x86_64, the guest can not be connected when set graphics vnc password to empty, the same result with bug 859317.
Actual results:
we can login the guest when set the graphics passwd empty
Expected results:
I am not sure what is the right behaviour for RHEL7?
thank
10 years, 1 month