VirtualBox

22 月 前 建立

5 月 前 更新

#21409 new defect

enabling capture with usbattach command always fails

回報者: Alban Browaeys 負責人:
元件: other 版本: VirtualBox-7.0.4
關鍵字: 副本:
Guest type: Windows Host type: other

描述

I was able to reproduce with both virtualbox 6.1.40-154048~Debian~bullseye and 7.0.4-154605~Debian~bullseye.

Host is mostly Debian bullseye with a Gnome from bookworm. Guest is Windows 7 Ultimate with latest updates installed.

$ VBoxManage controlvm "Win7 Ultimate Hermes" usbattach 7d1e5806-5813-4320-b11f-809e116092c5 --capturefile "usb_astrometa_20230103-1"
$ ls usb*
ls: impossible d'accéder à 'usb*': Aucun fichier ou dossier de ce type
$ VBoxManage controlvm "Win7 Ultimate Hermes" usbdetach 7d1e5806-5813-4320-b11f-809e116092c5 --capturefile "usb_astrometa_20230103-1"
VBoxManage: error: USB device with UUID {7d1e5806-5813-4320-b11f-809e116092c5} is not attached to this machine
VBoxManage: error: Details: code NS_ERROR_INVALID_ARG (0x80070057), component ConsoleWrap, interface IConsole, callee nsISupports
VBoxManage: error: Context: "DetachUSBDevice(usbId.raw(), dev.asOutParam())" at line 1451 of file VBoxManageControlVM.cpp

$ VBoxManage controlvm "Win7 Ultimate Hermes" usbattach 7d1e5806-5813-4320-b11f-809e116092c5 --capturefile "usb_astrometa_20230103-1"
VBoxManage: error: Code NS_ERROR_FAILURE (0x80004005) - Operation failed (extended info not available)
VBoxManage: error: Context: "AttachUSBDevice(usbId.raw(), captureFilename.raw())" at line 1447 of file VBoxManageControlVM.cpp

VBox.log extract:

00:07:37.598240 PDMUsb: Failed to attach USB device 'USBProxy' instance 1 to hub 00007fccb84e93b0: VERR_NOT_FOUND
00:07:37.765443 ERROR [COM]: aRC=NS_ERROR_FAILURE (0x80004005) aIID={6ac83d89-6ee7-4e33-8ae6-b257b2e81be8} aComponent={ConsoleWrap} aText={Failed to create a proxy device for the USB device. (Error: VERR_NOT_FOUND)}, preserve=false aResultDetail=-78
00:07:56.597244 ERROR [COM]: aRC=NS_ERROR_INVALID_ARG (0x80070057) aIID={6ac83d89-6ee7-4e33-8ae6-b257b2e81be8} aComponent={ConsoleWrap} aText={USB device with UUID {7d1e5806-5813-4320-b11f-809e116092c5} is not attached to this machine}, preserve=false aResultDetail=0
00:08:05.070747 PDMUsb: Failed to attach USB device 'USBProxy' instance 2 to hub 00007fccb84e93b0: VERR_NOT_FOUND
00:08:05.223122 ERROR [COM]: aRC=NS_ERROR_FAILURE (0x80004005) aIID={6ac83d89-6ee7-4e33-8ae6-b257b2e81be8} aComponent={ConsoleWrap} aText={Failed to create a proxy device for the USB device. (Error: VERR_NOT_FOUND)}, preserve=false aResultDetail=-78

This issue seems to have already been asked in the forum in November 2020 https://forums.virtualbox.org/viewtopic.php?f=7&t=100495

My "VBoxManage list usbhost":

Host USB Devices:

UUID:               d6e93f88-6381-4089-96f7-8abba8cd6718
VendorId:           0x17ef (17EF)
ProductId:          0x608d (608D)
Revision:           1.0 (0100)
Port:               1
USB version/speed:  2/Low
Manufacturer:       PixArt
Product:            Lenovo USB Optical Mouse
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8.2//device:/dev/vboxusb/001/007
Current State:      Busy

UUID:               025e451f-eb3f-4e61-a323-5e317182f509
VendorId:           0x17ef (17EF)
ProductId:          0x608c (608C)
Revision:           1.20 (0120)
Port:               0
USB version/speed:  2/Low
Manufacturer:       LiteOn
Product:            Lenovo Calliope USB Keyboard
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-8/1-8.1//device:/dev/vboxusb/001/005
Current State:      Busy

UUID:               1fbaede8-53a9-4d9f-af86-a4708f66cc9b
VendorId:           0x174c (174C)
ProductId:          0x55aa (55AA)
Revision:           1.0 (0100)
Port:               3
USB version/speed:  3/Super
Manufacturer:       Ugreen
Product:            Ugreen Storage Device
SerialNumber:       021912063F24
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb2/2-4//device:/dev/vboxusb/002/012
Current State:      Busy

UUID:               d3504e3c-c92f-40fa-9107-b63aee699a85
VendorId:           0x174c (174C)
ProductId:          0x55aa (55AA)
Revision:           1.0 (0100)
Port:               2
USB version/speed:  3/Super
Manufacturer:       Ugreen
Product:            Ugreen Storage Device
SerialNumber:       022001030BFA
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb2/2-3//device:/dev/vboxusb/002/011
Current State:      Busy

UUID:               e04d293c-2d4a-4e0d-b32a-f297a68f75e4
VendorId:           0x10c4 (10C4)
ProductId:          0xea60 (EA60)
Revision:           1.0 (0100)
Port:               1
USB version/speed:  2/Full
Manufacturer:       Silicon Labs
Product:            CP2104 USB to UART Bridge Controller
SerialNumber:       00DB1A1E
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5.2//device:/dev/vboxusb/001/013
Current State:      Busy

UUID:               699af1c0-be96-4f48-a254-a50b36888be9
VendorId:           0x0a12 (0A12)
ProductId:          0x0001 (0001)
Revision:           49.100 (49100)
Port:               0
USB version/speed:  2/Full
Manufacturer:       Cambridge Silicon Radio, Ltd
Product:            Bluetooth Dongle (HCI mode)
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-5/1-5.1//device:/dev/vboxusb/001/004
Current State:      Busy

UUID:               7d1e5806-5813-4320-b11f-809e116092c5
VendorId:           0x0781 (0781)
ProductId:          0x5581 (5581)
Revision:           1.0 (0100)
Port:               5
USB version/speed:  3/Super
Manufacturer:       SanDisk
Product:            Ultra
SerialNumber:       4C530001030927114111
Address:            sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb2/2-6//device:/dev/vboxusb/002/013
Current State:      Available

附加檔案 (1)

VBox.log (256.4 KB ) - 22 月 前, 由 Alban Browaeys 新增
VBox log from session with failing usbattach capture to file

下載所有附檔: .zip

更動歷史 (4)

22 月 前Alban Browaeys 編輯

附檔: 新增 VBox.log

VBox log from session with failing usbattach capture to file

comment:1 19 月 前Matthias Pfützner 編輯

I do have the SAME error, any news/updates here?

comment:2 19 月 前Matthias Pfützner 編輯

I do run VBOx on RHEL 8 and the guest is a Windows 10 guest.

And there is a small additional thing, which might only be somewhat "cosmetic":

VBoxManage controlvm <uuid | vmname> usbattach <uuid | address>

[--capturefile=filename]

BUT:

[mpfuetzn@mpfuetzn ~]$ vboxmanage controlvm Win10CSBVM usbattach sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1//device:/dev/vboxusb/001/010 --capturefile=file Oracle VM VirtualBox Command Line Management Interface Version 7.0.6 Copyright (C) 2005-2023 Oracle and/or its affiliates

VBoxManage: error: Wrong number of arguments.

Usage:

VBoxManage controlvm <uuid | vmname> usbattach <uuid | address>

[--capturefile=filename]

[mpfuetzn@mpfuetzn ~]$ vboxmanage controlvm Win10CSBVM usbattach sysfs:/sys/devices/pci0000:00/0000:00:14.0/usb1/1-1//device:/dev/vboxusb/001/010 --capturefile file [mpfuetzn@mpfuetzn ~]$

So, there is NO "=" between --capturefile and the filename

comment:3 5 月 前eddygorsuch 編輯

For anyone still running into this problem, I found the solution ...

VBUSBSniffer uses the file extension to determine what kind of capture to do. So, file extensions

  • "vmx", "vmware", "usbio" are used for VMX USBIO format captures
  • "mon", "usbmon" are used for Linux usbmon ASCII format captures
  • "pcap", "pcapng" are used for PCAP-NG format writer

So, you need to name the capture file with the correct file extension (based on the format you want to capture). Naming my capture file usb-capture.pcap fixed my problem.

I found this by hunting in the source: /VirtualBox-7.0.18/src/VBox/Devices/USB/VUSBSniffer*

eddy

注意: 瀏覽 TracTickets 來幫助您使用待辦事項功能

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette