Bug 1734679 - Support on USB cutter devices for ovirt Windows guest
Summary: Support on USB cutter devices for ovirt Windows guest
Keywords:
Status: NEW
Alias: None
Product: ovirt-engine
Classification: oVirt
Component: General
Version: 4.3.5
Hardware: x86_64
OS: All
unspecified
medium vote
Target Milestone: ---
: ---
Assignee: bugs@ovirt.org
QA Contact: Lukas Svaty
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2019-07-31 07:54 UTC by Navneet Kumar Dubey
Modified: 2019-08-26 15:09 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:
oVirt Team: Virt


Attachments (Terms of Use)
The screenshot is from the ovirt manager VM where the host devices are connected (49.93 KB, image/png)
2019-07-31 07:54 UTC, Navneet Kumar Dubey
no flags Details
The setup diagrammatic view is attached (65.75 KB, image/png)
2019-07-31 10:16 UTC, Navneet Kumar Dubey
no flags Details
xml dump from the guest Windows 10 machine (11.50 KB, text/plain)
2019-08-01 05:40 UTC, Navneet Kumar Dubey
no flags Details
screenshot from the Windows device manager (40.27 KB, image/png)
2019-08-01 05:40 UTC, Navneet Kumar Dubey
no flags Details
engine log from ovirt manager node (4.24 MB, text/plain)
2019-08-01 05:41 UTC, Navneet Kumar Dubey
no flags Details
vdsm logs from the host node (320.00 KB, text/plain)
2019-08-01 05:42 UTC, Navneet Kumar Dubey
no flags Details
Latest XML dump after changing to VNC (9.22 KB, text/plain)
2019-08-01 09:18 UTC, Navneet Kumar Dubey
no flags Details
Windows XML (11.75 KB, text/plain)
2019-08-01 13:43 UTC, Navneet Kumar Dubey
no flags Details
options of q35 (112.58 KB, image/png)
2019-08-01 13:45 UTC, Navneet Kumar Dubey
no flags Details
Windows XML dump after repeating comment#10 (10.35 KB, text/plain)
2019-08-01 19:28 UTC, Navneet Kumar Dubey
no flags Details
Device manager USB controller before USB attaching (28.26 KB, image/png)
2019-08-05 11:46 UTC, Navneet Kumar Dubey
no flags Details
Device manager USB controller after USB attaching (28.40 KB, image/png)
2019-08-05 11:55 UTC, Navneet Kumar Dubey
no flags Details
BIOS type of the guest VM (78.40 KB, image/png)
2019-08-05 13:53 UTC, Navneet Kumar Dubey
no flags Details

Description Navneet Kumar Dubey 2019-07-31 07:54:53 UTC
Created attachment 1594933 [details]
The screenshot is from the ovirt manager VM where the host devices are connected

Description of problem: We were using the USB dongle on the Windows guest on ovirt host node and was working fine. We have a situation where we want to use USB cutter device which makes the USB dongle Switching off and on when  required depending on the test cases as radiation makes the over heating of the dongle. 
When we connect the dongle with the USB cutter we are able to discover on the host node. We then added as host_devices as  well to the guest but neither the USB cutter nor the USB dongle connected to it is seen on the guest node. Attached is the snapshot from the VMs host_devices. 

Can this be supported on ovirt managed Windows VM.  The VM is Windows 10 installed with ovirt-guest-tools and usbdk. 


Version-Release number of selected component (if applicable): 4.3.5.3-1.el7

From Host node  : vdsm-4.30.8-9.gitf28e377.el7.x86_64

Output from host node : 

[root@localhost ~]# lsusb
Bus 002 Device 011: ID 04e8:6889 Samsung Electronics Co., Ltd GT-B3730 Composite LTE device (Commercial)
Bus 002 Device 005: ID 0bda:5411 Realtek Semiconductor Corp.
Bus 002 Device 004: ID 0bda:5411 Realtek Semiconductor Corp.
Bus 002 Device 002: ID 8087:8002 Intel Corp.
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 113: ID 0d50:0008 Cleware GmbH
Bus 001 Device 004: ID 046b:ff10 American Megatrends, Inc. Virtual Keyboard and Mouse
Bus 001 Device 003: ID 046b:ff01 American Megatrends, Inc.
Bus 001 Device 002: ID 8087:800a Intel Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

Where, 04e8:6889 Samsung Electronics  is the USB dongle and 0d50:0008 Cleware GmbH is the USB cutter . 

Reference for USB cutter : 
http://www.cleware-shop.de/USB-Cutter/en
http://www.cleware-shop.de/epages/63698188.sf/en_US/?ObjectPath=/Shops/63698188/Categories/USB_Cutter

How reproducible:


Steps to Reproduce:
1. Connected the USB cutter to the host and the USB dongle to the USB cutter. 
2. Checked in host with lsusb and it had discovered. Then added both cutter and dongle to the Host device of the VM. Check the attachment.
3. The USB support is also enabled for the guest with SPICE as the Graphics mode for console. 
4. Powered on the VM but was not able to see the cutter as well as the USB dongle. 

Actual results: USB cutter and USB dongle not being able to detect . Physical Windows PC works with both the USB devices


Expected results: USB cutter and USB dongle should be discovered. 


Additional info: Please let me know if you any other details on priority and I will be able to provide you. I work in IST time zone (GMT +5:30)

Comment 1 Navneet Kumar Dubey 2019-07-31 10:14:51 UTC
I have also attached the diagrammatic representation of our setup. The attached file "setup" has two parts . 
The first part is ovirt setup which is having the issue. The second part is Standalone physical Windows PC on which it works fine.

Comment 2 Navneet Kumar Dubey 2019-07-31 10:16:40 UTC
Created attachment 1595012 [details]
The setup diagrammatic view is attached

Comment 3 Ryan Barry 2019-08-01 01:03:07 UTC
I very much doubt if this has ever been tested with such a device. Is it visible in the Windows device manager anywhere?

Once it's passed through, it should no longer be visible from the host. Can you add the libvirt XML? Available from engine.log or vdsm.log (alternatively, from virsh dumpxml)?

Comment 4 Navneet Kumar Dubey 2019-08-01 05:38:59 UTC
I don't see the device under the Windows device manager. Please check the attached screenshot named as "device_manager.

I have attached the xml file for the Winsows. Additionally I have also attached the vdsm.log from the host and the engine.log from the manager node.

Comment 5 Navneet Kumar Dubey 2019-08-01 05:40:05 UTC
Created attachment 1596863 [details]
xml dump from the guest Windows 10 machine

Comment 6 Navneet Kumar Dubey 2019-08-01 05:40:42 UTC
Created attachment 1596864 [details]
screenshot from the Windows device manager

Comment 7 Navneet Kumar Dubey 2019-08-01 05:41:33 UTC
Created attachment 1596865 [details]
engine log from ovirt manager node

Comment 8 Navneet Kumar Dubey 2019-08-01 05:42:15 UTC
Created attachment 1596866 [details]
vdsm logs from the host node

Comment 9 Navneet Kumar Dubey 2019-08-01 05:43:07 UTC
Hi Ryan,

I have all the required logs to check. 

Regards
Navneet

Comment 10 Michal Skrivanek 2019-08-01 07:52:14 UTC
it's getting mixed up with the SPICE USB redir devices, you could see in xml that your 2 host devs are plugged into ports 1 and 6. But there are also redir devices  in all the other 4 ports. Maybe your devices don't like to be plugged into USB 2 or USB 1 controllers, or maybe even the whole companion controller stuff

Anyway, disable SPICE and use just VNC, that may change things. You may also try creating a new VM definition - or maybe first try removing those host devices, switching to VNC, run VM, shutdown, assign host devices again.
Another alternative is to switch to Q35+seabios since there we use a single USB3 XHCI controller. It's likely going to work better.

Comment 11 Navneet Kumar Dubey 2019-08-01 09:17:28 UTC
Hi Michal,

Thanks for the analysis and the actions. 

I tried removing those host devices, switching to VNC, run VM, shutdown, assign host devices again.

Still no success. 

How I can try switching to Q35+seabios. If you can let me know I can try that too. 

Latest xml file is attached . 

Regards
Navneet

Comment 12 Navneet Kumar Dubey 2019-08-01 09:18:13 UTC
Created attachment 1596891 [details]
Latest XML dump after changing to VNC

Comment 13 Navneet Kumar Dubey 2019-08-01 09:29:38 UTC
Should I change the value in the file /etc/ovirt-engine/osinfo.conf.d/00-defaults.properties. 

As of now it shows as below :

os.other.devices.usb.controller.value = piix3-uhci,q35/qemu-xhci

Shoudl I change the value to something and then restart the engine services

Comment 14 Navneet Kumar Dubey 2019-08-01 11:24:55 UTC
Hi Michal,

I tried to change the BIOS type to q35 from the edit option of the guest then tried to run it but the the VM was not able to come up. 

It has the Below error :

 Exit message: unsupported configuration: IDE controllers are unsupported for this QEMU binary or machine type

Regards
Navneet

Comment 15 Ryan Barry 2019-08-01 12:03:15 UTC
This is due to the cdrom. Also, I'd suggest that Windows is going to be happy with a change in the emulated hardware.

I don't see the USB devices in the new XML. They're passed through as host devices. Still present in the UI?

Comment 16 Navneet Kumar Dubey 2019-08-01 12:23:16 UTC
Hi Ryan,

As per Michal I can try to recreate the Windows guest VM. Could you please let me know with what properties I can go forward creating it. 

Regards
navneet

Comment 17 Ryan Barry 2019-08-01 12:25:18 UTC
The same USB settings as before.

Michal suggested Q35 since the USB configuration is less complex from a virtual hardware level, but the interface is otherwise the same.

Comment 18 Navneet Kumar Dubey 2019-08-01 13:42:13 UTC
Hi Ryan,

I tried on a newly created machine but the machine is not able to start when i use Q35 . Attached are the option that is being listed. We get the below error:
VM 10.58.178.145_win10 is down with error. Exit message: unsupported configuration: IDE controllers are unsupported for this QEMU binary or machine type.

Also, while using the VNC instead of SPICE the VM does not come up saying the below error. 
VM 10.58.178.146_win10 is down with error. Exit message: XML error: requested USB port 6 not present on USB bus 0.

I have attached the latest XML dump of the VM

Comment 19 Navneet Kumar Dubey 2019-08-01 13:43:25 UTC
Created attachment 1597467 [details]
Windows XML

Comment 20 Navneet Kumar Dubey 2019-08-01 13:45:20 UTC
Created attachment 1597468 [details]
options of q35

Comment 21 Ryan Barry 2019-08-01 14:07:50 UTC
This doesn't appear to be Q35 (no xhci usb controller, and the machine type is still i440fx:

  <os>
    <type arch='x86_64' machine='pc-i440fx-rhel7.3.0'>hvm</type>
    <smbios mode='sysinfo'/>
  </os>

Is this actually a new VM?

Please attempt the suggestion in comment#10. Shut down the VM, change the console type to SPICE, remove the USB passthrough from host devices, then re-add them. Please post the XML when finished

Comment 22 Navneet Kumar Dubey 2019-08-01 15:29:42 UTC
1. Machine set to SPICE , removed the the USB passthrough from host devices, then re-add them.
2. Also changed the Custom Emulated Machine to "Q35"
2. Tried to start the machine it throws the error :
VM 10.58.178.145_win10 is down with error. Exit message: unsupported configuration: IDE controllers are unsupported for this QEMU binary or machine type.

How can I make sure when i Change the Custom Emulated Machine to "Q35" then machines then starts normally.

Comment 23 Navneet Kumar Dubey 2019-08-01 16:50:00 UTC
Still Wondering why the VM when set to Custom Emulated Machine to "Q35" or any of the "pc-q35-rhel7.X.X" does not boot. You were telling something the issue related to the cdrom. Could you please let me if we can do something for this.

Comment 24 Navneet Kumar Dubey 2019-08-01 17:01:47 UTC
Is it due to the vdsm and the ovirt version from the host node :

[root@localhost qemu]# rpm -qa | grep -i vdsm
vdsm-hook-fcoe-4.30.8-9.gitf28e377.el7.noarch
vdsm-hook-vmfex-dev-4.30.8-9.gitf28e377.el7.noarch
vdsm-jsonrpc-4.30.8-9.gitf28e377.el7.noarch
vdsm-python-4.30.8-9.gitf28e377.el7.noarch
vdsm-common-4.30.8-9.gitf28e377.el7.noarch
vdsm-network-4.30.8-9.gitf28e377.el7.x86_64
vdsm-hook-openstacknet-4.30.8-9.gitf28e377.el7.noarch
vdsm-http-4.30.8-9.gitf28e377.el7.noarch
vdsm-4.30.8-9.gitf28e377.el7.x86_64
vdsm-api-4.30.8-9.gitf28e377.el7.noarch
vdsm-hook-ethtool-options-4.30.8-9.gitf28e377.el7.noarch
vdsm-yajsonrpc-4.30.8-9.gitf28e377.el7.noarch
vdsm-client-4.30.8-9.gitf28e377.el7.noarch
vdsm-hook-vhostmd-4.30.8-9.gitf28e377.el7.noarch
[root@localhost qemu]# rpm -qa | grep -i ovirt
ovirt-release-master-4.4.0-0.2.master.20190723000137.gitea53f6e.el7.noarch
python2-ovirt-setup-lib-1.2.1-0.0.master.20190108150145.gite04a5af.el7.noarch
cockpit-ovirt-dashboard-0.12.2-0.0.master.20190122.git634e961.el7.noarch
python2-ovirt-host-deploy-1.8.0-0.0.master.20181220124603.git6a3fda8.el7.noarch
ovirt-ansible-engine-setup-1.1.8-0.1.master.20190117095028.el7.noarch
ovirt-provider-ovn-driver-1.2.20-0.20190125152832.git6aec408.el7.noarch
ovirt-engine-cli-3.6.9.3-0.1.20180209.gitad0561a.el7.centos.noarch
ovirt-vmconsole-host-1.0.6-3.el7.noarch
cockpit-machines-ovirt-176-4.el7.centos.noarch
ovirt-host-dependencies-4.3.1-0.0.master.20190115090506.gitc8ad67d.el7.x86_64
ovirt-hosted-engine-setup-2.3.4-0.0.master.20190125093207.git6c233f5.el7.noarch
ovirt-vmconsole-1.0.6-3.el7.noarch
ovirt-imageio-common-1.5.0-0.201901061024.gita4be4ca.el7.x86_64
libgovirt-0.3.4-1.el7.x86_64
ovirt-ansible-repositories-1.1.5-0.1.master.20190125081537.el7.noarch
ovirt-engine-sdk-python-3.6.9.2-0.1.20180209.gite99bbd1.el7.centos.noarch
python-ovirt-engine-sdk4-4.3.0-2.20190116gitf8b704b.el7.x86_64
ovirt-host-4.3.1-0.0.master.20190115090506.gitc8ad67d.el7.x86_64
ovirt-ansible-hosted-engine-setup-1.0.8-0.1.master.20190125145004.el7.noarch
ovirt-host-deploy-common-1.8.0-0.0.master.20181220124603.git6a3fda8.el7.noarch
ovirt-hosted-engine-ha-2.3.2-0.0.master.20190122143022.20190122143015.git7da170e.el7.noarch
ovirt-imageio-daemon-1.5.0-0.201901061024.gita4be4ca.el7.noarch

Comment 25 Ryan Barry 2019-08-01 18:55:21 UTC
Ok, so changing from i440fx to Q35 isn't supported for this reason (the IDE controller) until 4.4. It would need to be a new VM. Please move back to i440fx and attempt comment#10

Comment 26 Navneet Kumar Dubey 2019-08-01 19:27:33 UTC
Changed to pc-i440fx-rhel7.3.0 and then repeated comment 10 : removing those host devices, switching to VNC, run VM, shutdown, assign host devices again.

Still no luck ad the device manager still does not shows the USBs. Attached is the xml file .

Comment 27 Navneet Kumar Dubey 2019-08-01 19:28:21 UTC
Created attachment 1599249 [details]
Windows XML dump after repeating comment#10

Comment 28 Navneet Kumar Dubey 2019-08-02 06:47:22 UTC
Any updates ??

Comment 29 Ryan Barry 2019-08-02 15:13:05 UTC
Ok, so they're present in the XML.

Can you please try:

set DEVMGR_SHOW_DETAILS=1
set DEVMGR_SHOW_NONPRESENT_DEVICES=1
start devmgmt.msc

And see if the devices are present, but hidden?

Comment 30 Navneet Kumar Dubey 2019-08-02 16:11:38 UTC
Tried the steps still not found

Comment 31 Ryan Barry 2019-08-03 00:42:30 UTC
Is it possible to attempt with a Linux guest and the same passthrough settings to see if it appears in lsusb? I can't reproduce your symptoms, but I also don't have a cutter to check with

Comment 32 Navneet Kumar Dubey 2019-08-03 09:12:37 UTC
Yes, I tried on the linux machine and both the cutter and the dongle was discovered 

[root@localhost ~]# lsusb
Bus 001 Device 002: ID 04e8:6889 Samsung Electronics Co., Ltd GT-B3730 Composite LTE device (Commercial)
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 003 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
Bus 002 Device 002: ID 0d50:0008 Cleware GmbH
Bus 002 Device 001: ID 1d6b:0001 Linux Foundation 1.1 root hub
[root@localhost ~]#

Comment 33 Ryan Barry 2019-08-05 00:22:17 UTC
Ok, positive. Is the USB controller visible in Windows?

Comment 34 Navneet Kumar Dubey 2019-08-05 11:45:03 UTC
Yes, they are visible. I have taken the screenshot of the device manager page : one before the USB was attached and the other after attaching the USB

Comment 35 Navneet Kumar Dubey 2019-08-05 11:46:04 UTC
Created attachment 1600636 [details]
Device manager USB controller before USB attaching

Comment 36 Navneet Kumar Dubey 2019-08-05 11:55:04 UTC
Created attachment 1600637 [details]
Device manager USB controller after  USB attaching

Comment 37 Michal Skrivanek 2019-08-05 12:21:04 UTC
(In reply to Ryan Barry from comment #25)
> Ok, so changing from i440fx to Q35 isn't supported for this reason (the IDE controller) until 4.4. It would need to be a new VM. Please move back to i440fx and attempt comment#10

you're not supposed to use custom emulated machine type. that's not the right "thing" to change. Change the "BIOS Type" only.

Comment 38 Navneet Kumar Dubey 2019-08-05 13:52:30 UTC
The BIOS type has not been changed. It is still in "default". Please check the screenshot

Comment 39 Navneet Kumar Dubey 2019-08-05 13:53:15 UTC
Created attachment 1600649 [details]
BIOS type of the guest VM

Comment 40 Navneet Kumar Dubey 2019-08-23 07:26:57 UTC
Hi Team,

Can I have an update on this issue . 

Regards
Navneet

Comment 41 Ryan Barry 2019-08-23 07:39:42 UTC
General take is that, if it works in Linux and not Windows (lsusb vs device manager), I'd suspect Windows in some way. Are the virtio drivers installed?

Comment 42 Navneet Kumar Dubey 2019-08-26 14:00:47 UTC
I have doubt in that case as It was said that the individual Modem when connected to the host was able to get mapped and detected at the guest VM it mean we have all the required drivers installed. 
The issue is only seen when we connect the dongle to the USB cutter and it is the cutter that is not getting detected in the guest VM

Comment 43 Ryan Barry 2019-08-26 15:09:05 UTC
USB device initialization isn't particularly standardized, especially anything which may mode switch. I'm not familiar with the cutter in particular, but I'll try to dig a little in USB sources


Note You need to log in before you can comment on or make changes to this bug.