Connect headset causes freeze

Discussions related to using VirtualBox on Windows hosts.
morfil
Posts: 1
Joined: 9. Aug 2019, 11:10

Connect headset causes freeze

Post by morfil »

I have:
  • Windows 10 host
  • VirtualBox 6.0.10
  • Ubuntu 19.4 guest
I am facing some cases, which causes VM to freeze totally, even the VirtualBox app freezes until I close (kill) the guest window.
I am using a Bluetooth headset, Samsung Level Over. This headset is connected to the Windows host and I am selecting the output from the host
Case 1
  1. Do not connect headset
  2. Start VM
  3. Play some music on guest (such as spotifty)
  4. Connect the headset
  5. VM freezes
Case 2 (similar to case 1)
  1. Do not connect headset
  2. Start VM
  3. Play some music on guest (such as spotifty)
  4. Pause
  5. Connect the headset
  6. Resume play
  7. VM freezes
Case 3
  1. Connect the headset
  2. Start VM
  3. Play some music on guest
  4. No problem with playback
  5. Pause
  6. Lock your host, and go away, wait about 30 minutes for host to put some light sleep (assuming headset is disconnected while asleep)
  7. Comeback and unlock computer (host & guest)
  8. Resume play
  9. VM freezes
If I play something directly from Windows host, it does not cause any problem.
I have not modified any setting for audio of the guest from VirtualBox panel
chenlevy
Posts: 1
Joined: 28. Feb 2021, 12:46

Re: Connect headset causes freeze

Post by chenlevy »

I see the same issue:

Host Windows 10
Guest Ubuntu 20.04
Virtualbox 6.1.18

Whenever my Bluetooth speaker connects or disconnects form the host, the guest stops responding. I need to kill the guest in order to continue.
zt7tcy5quowlvjyqo3jidgb4
Posts: 1
Joined: 16. Mar 2021, 20:58

Re: Connect headset causes freeze

Post by zt7tcy5quowlvjyqo3jidgb4 »

Confirm this bug:
Host: Windows 10
Guest: Fedora 33
virboxer
Posts: 4
Joined: 21. Apr 2021, 10:54

Re: Connect headset causes freeze

Post by virboxer »

Having the same issue (started 3 weeks ago):

Host system: Windows 10 (2004)
Guest system: Ubuntu 20.04
Virtualbox addons: installed
Version: 6.1.18 r142142 (Qt5.6.2)
Rble
Posts: 1
Joined: 9. May 2021, 21:02

Re: Connect headset causes freeze

Post by Rble »

Similar issue on my machine. I have a USB sound card. Unplugging will cause guest OS Ubuntu Mate 20.04 to freeze, have to close window. Host OS is Windows 10 1909 (old, but that's what the IT dept. likes...) Virtual Box 6.1.22.

No audio playback required, just unplug the sound card.
vboxNice
Posts: 1
Joined: 10. May 2021, 21:52

Re: Connect headset causes freeze

Post by vboxNice »

I think I'm seeing this too. Win10 Host and Win10 Guest. I use a Tronsmart Bluetooth headset on and off. I have dealt with a few freezes, using a hard shutdown ending up with VM state Aborted. The tail of the log has looked like this:

00:03:00.862693 VMMDev: Guest Log: VBoxDispIfResizeDisplayWin7: VBoxTray:(WDDM) pfnSetDisplayConfig Failed to SET, winEr 87.
00:03:00.869773 Display::i_handleDisplayResize: uScreenId=1 pvVRAM=0000000010818000 w=1280 h=960 bpp=32 cbLine=0x1400 flags=0x1 origin=1920,0
00:03:00.890744 GUI: UIMachineLogic: Guest-screen count changed
00:03:01.104831 GUI: UIMediumEnumerator: Medium-enumeration finished!
00:03:01.191301 GUI: UIMachineView::sltPerformGuestResize: Sending guest size-hint to screen 1 as 1280x960 if necessary
00:03:01.224825 GUI: UIMachineView::sltPerformGuestResize: Sending guest size-hint to screen 1 as 1280x960 if necessary
00:03:02.883703 GUI: UIMachineView::sltPerformGuestResize: Sending guest size-hint to screen 1 as 1920x975 if necessary
00:03:02.892655 VMMDev: SetVideoModeHint: Got a video mode hint (1920x975x32)@(0x0),(1;0) at 1
00:03:02.892934 VMMDev: Guest Log: Got multi resize request 1 displays
00:03:02.892984 VMMDev: Guest Log: [0]: 1 0x38 0,0 1920x975 32
00:03:02.915621 GUI: UIMediumEnumerator: Medium-enumeration finished!
00:03:03.386808 Display::i_handleDisplayResize: uScreenId=1 pvVRAM=0000000010818000 w=1920 h=975 bpp=32 cbLine=0x1E00 flags=0x1 origin=1920,0
00:03:39.000386 GUI: UIMediumEnumerator: Medium-enumeration started...
00:03:40.243293 GUI: UIMediumEnumerator: Medium-enumeration finished!
00:03:53.134432 VMMDev: Guest Log: VBOXNP: DLL unloaded.
00:03:53.135772 VMMDev: Guest Log: VBOXNP: DLL loaded.
00:04:49.199804 VMMDev: Guest Log: VBOXNP: DLL loaded.
00:07:44.768841 Audio: Device configuration of driver 'DSoundAudio' has changed
00:07:45.000681 Audio: Device configuration of driver 'DSoundAudio' has changed
00:07:46.668770 Audio: Device configuration of driver 'DSoundAudio' has changed
00:11:25.842455 AHCI#0: Port 2 reset
00:11:25.843539 VD#2: Cancelling all active requests
00:11:25.844650 AHCI#0: Port 0 reset
00:11:25.845726 VD#0: Cancelling all active requests
00:16:14.458720 VMMDev: Guest Log: VBOXNP: DLL loaded.
00:16:29.313632 VMMDev: Guest Log: VBOXNP: DLL unloaded.
00:34:11.740421 Audio: Device configuration of driver 'DSoundAudio' has changed
00:34:11.950189 Audio: Device configuration of driver 'DSoundAudio' has changed
00:34:12.104371 Audio: Found 6 devices for driver 'DSoundAudio'
00:34:12.104390 Audio: Device 'Primary Sound Driver':
00:34:12.104397 Audio: Usage = Output
00:34:12.104403 Audio: Flags = DEFAULT
00:34:12.104409 Audio: Input channels = 0
00:34:12.104415 Audio: Output channels = 2
00:34:12.104421 Audio: Device 'Speakers (Conexant ISST Audio)':
00:34:12.104427 Audio: Usage = Output
00:34:12.104433 Audio: Flags = NONE
00:34:12.104438 Audio: Input channels = 0
00:34:12.104444 Audio: Output channels = 2
00:34:12.104449 Audio: Device 'DELL U2410 (NVIDIA High Definition Audio)':
00:34:12.104455 Audio: Usage = Output
00:34:12.104464 Audio: Flags = NONE
00:34:12.104472 Audio: Input channels = 0
00:34:12.104477 Audio: Output channels = 2
00:34:12.104483 Audio: Device 'Primary Sound Capture Driver':
00:34:12.104489 Audio: Usage = Input
00:34:12.104494 Audio: Flags = NONE
00:34:12.104500 Audio: Input channels = 2
00:34:12.104506 Audio: Output channels = 0
00:34:12.104512 Audio: Device 'Internal Microphone (Conexant ISST Audio)':
00:34:12.104517 Audio: Usage = Input
00:34:12.104523 Audio: Flags = NONE
00:34:12.104528 Audio: Input channels = 2
00:34:12.104533 Audio: Output channels = 0
00:34:12.104539 Audio: Device 'Headset (Tronsmart Encore S6 Hands-Free AG Audio)':
00:34:12.104545 Audio: Usage = Input
00:34:12.104550 Audio: Flags = NONE
00:34:12.104556 Audio: Input channels = 2
00:34:12.104561 Audio: Output channels = 0
00:37:05.741280 GUI: UIMediumEnumerator: Medium-enumeration finished!
00:37:22.230699 GUI: UICommon::sltHandleCommitDataRequest: Emergency shutdown initiated
00:37:22.230699 GUI: Request for close-action to save VM state.
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

All my Ubuntu guests freezes randomly as well:
  • Random Ubuntu guest freezes.
  • Heavy latency in order of seconds when playing a video with VLC Ubuntu guests.
  • Heavy audio stuttering by playing a wide range of audio formats.
The problems started around February 2021. My hardware setup did not change and the problem still exists after a full Windows host and Guest re-installations.
I think about an incompatible Windows / VirtualBox update as my system worked stable for a year.

Host
  • AMD Ryzen 7 3700X 8-Core Processor, 32GB RAM.
  • Gigabyte X570 Aorus Elite, latest BIOS version F30, Virtualization enabled in BIOS.
  • Windows 10 host, all updates installed from today, default installation without Hyper-V.
  • Virtualbox: 6.1.20 r143896 (Qt5.6.2), No extensions installed (also tried with VirtualBox 6.1.20 Oracle VM VirtualBox Extension Pack).
  • Windows Power & Sleep | Additional power settings | AMD Ryzen Balanced: Configured max power did not help.
  • Latest Gigabyte MB audio drivers installed.
Guest
  • Clean Ubuntu 18.04 -> Random freeze
  • Clean Ubuntu 20.04.2 -> Random freeze
  • Clean Ubuntu 21.04 -> Random freeze
  • All updates installed, including Guest additions.
  • 6GB RAM, 8 cores, 128MB video memory.
  • No difference between enable/disable PAE/NX or Nested VT-x/AMD-V settings.
  • Less audio hick-ups with Intel HD Audio compared with the default ICH AC97, but system freezes randomly.
What I already tried last weeks:
  • Reinstalled Windows 10 host
  • Reinstalled VirtualBox
  • Updated all Windows drivers + all Windows updates
  • Updated BIOS firmware to latest version
  • Tried re-installation of several Ubuntu guests and none of them fixed it.
Critical problems:
  • When I keep the system running for around 30 minutes an come back, the Ubuntu guest may randomly freeze.
  • Same when connecting/disconnecting a Sennheiser SC260 or turning on my Fireface RME 802 audio interface freezes most of the times, but not always.
I've no further ideas for more research and this forum is my last resort as I cannot longer do business with this unstable system.

Please find attached the detailed logs when turning on the USB 2.0 Fireface 802 audio interface. Can someone please advise how to proceed?

Code: Select all

00:00:50.670827 Audio: Device '{0.0.0.00000000}.{343fa0e4-1993-4eb2-90c2-33b7486f8027}' has changed state to 'unplugged'
00:00:50.670860 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:50.672676 Audio: Default output device has been changed to '{0.0.0.00000000}.{f8cb4b38-fe24-4f0d-8b28-b8cbe23ddadf}'
00:00:50.672699 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:50.672890 Audio: Default output device has been changed to '{0.0.0.00000000}.{f8cb4b38-fe24-4f0d-8b28-b8cbe23ddadf}'
00:00:50.672899 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:50.762151 Audio: Device '{0.0.1.00000000}.{3ca4232e-59a7-4720-ae7d-9018e2d4c6d6}' has changed state to 'disabled'
00:00:50.762170 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:50.837542 Audio: Device '{0.0.0.00000000}.{9564b13b-a5c6-4ced-b65a-a0053fb36f9c}' has changed state to 'unplugged'
00:00:50.837574 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:50.837775 Audio: Default output device has been changed to '{0.0.0.00000000}.{72cee3b3-ae8c-47da-b974-d68ff0756d92}'
00:00:50.837787 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:56.838841 Audio: Default output device has been changed to '{0.0.0.00000000}.{148433d0-46b0-4876-9dd6-c017cc9ec5eb}'
00:00:56.838866 Audio: Device configuration of driver 'DSoundAudio' has changed
00:00:56.839086 Audio: Default output device has been changed to '{0.0.0.00000000}.{148433d0-46b0-4876-9dd6-c017cc9ec5eb}'
00:00:56.839104 Audio: Device configuration of driver 'DSoundAudio' has changed
00:01:12.671435 DSound: DirectSound playback is currently unavailable
00:01:12.675353 DSound: DirectSound playback is currently unavailable
00:01:12.678233 DSound: DirectSound playback is currently unavailable
00:01:12.682025 DSound: DirectSound playback is currently unavailable
00:01:12.684758 DSound: DirectSound playback is currently unavailable
00:01:12.688493 DSound: DirectSound playback is currently unavailable
00:01:12.711877 DSound: DirectSound playback is currently unavailable
00:01:12.717213 DSound: DirectSound playback is currently unavailable
00:01:17.926116 Audio: Device '{0.0.1.00000000}.{964f05d0-5fa9-45ca-babe-eee2769c1c24}' has changed state to 'active'
00:01:17.926154 Audio: Device configuration of driver 'DSoundAudio' has changed
00:01:18.026540 Audio: Device '{0.0.0.00000000}.{5e851de5-f155-48e8-8d6b-412533aec36a}' has changed state to 'active'
00:01:18.026555 Audio: Device configuration of driver 'DSoundAudio' has changed
00:01:18.026766 Audio: Default output device has been changed to '{0.0.0.00000000}.{5e851de5-f155-48e8-8d6b-412533aec36a}'
00:01:18.026781 Audio: Device configuration of driver 'DSoundAudio' has changed
00:01:18.079630 Audio: Found 7 devices for driver 'DSoundAudio'
00:01:18.079646 Audio: Device 'Primary Sound Driver':
00:01:18.079649 Audio:   Usage           = Output
00:01:18.079652 Audio:   Flags           = DEFAULT
00:01:18.079654 Audio:   Input channels  = 0
00:01:18.079657 Audio:   Output channels = 2
00:01:18.079659 Audio: Device 'C34H89x (NVIDIA High Definition Audio)':
00:01:18.079662 Audio:   Usage           = Output
00:01:18.079664 Audio:   Flags           = NONE
00:01:18.079667 Audio:   Input channels  = 0
00:01:18.079669 Audio:   Output channels = 2
00:01:18.079672 Audio: Device 'Realtek Digital Output (Realtek(R) Audio)':
00:01:18.079674 Audio:   Usage           = Output
00:01:18.079677 Audio:   Flags           = NONE
00:01:18.079679 Audio:   Input channels  = 0
00:01:18.079681 Audio:   Output channels = 2
00:01:18.079684 Audio: Device 'Speakers (Sennheiser SC260)':
00:01:18.079686 Audio:   Usage           = Output
00:01:18.079688 Audio:   Flags           = NONE
00:01:18.079691 Audio:   Input channels  = 0
00:01:18.079693 Audio:   Output channels = 2
00:01:18.079695 Audio: Device 'Primary Sound Capture Driver':
00:01:18.079698 Audio:   Usage           = Input
00:01:18.079700 Audio:   Flags           = NONE
00:01:18.079702 Audio:   Input channels  = 2
00:01:18.079707 Audio:   Output channels = 0
00:01:18.079712 Audio: Device 'Microphone (Sennheiser SC260)':
00:01:18.079714 Audio:   Usage           = Input
00:01:18.079717 Audio:   Flags           = NONE
00:01:18.079719 Audio:   Input channels  = 2
00:01:18.079721 Audio:   Output channels = 0
00:01:18.079724 Audio: Device 'Analog (1+2) (RME Fireface 802)':
00:01:18.079726 Audio:   Usage           = Input
00:01:18.079729 Audio:   Flags           = NONE
00:01:18.079731 Audio:   Input channels  = 2
00:01:18.079733 Audio:   Output channels = 0
00:01:18.148453 Audio: Device '{0.0.1.00000000}.{3dbbcb84-a2ae-4a11-b770-3d788b7794db}' has changed state to 'active'

<== Here the Ubuntu guest GUI freezes! No way to restore, no response with resizing the guest. The only way to continue is by terminating the guest and restarting it.
Attachments
VirtualBoxFreezeLog.zip
(41.21 KiB) Downloaded 10 times
Last edited by bertje on 12. May 2021, 20:05, edited 1 time in total.
scottgus1
Site Moderator
Posts: 20965
Joined: 30. Dec 2009, 20:14
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: Windows, Linux

Re: Connect headset causes freeze

Post by scottgus1 »

Just to let you all know, we're not actively ignoring this topic. We just need someone who knows how to fix it to come along. Personally I don't run audio and video in my VMs or USB/Bluetooth headphones on the host, so I would have no ideas to fix this myself.

I have seen logs from folks having audio glitches showing a re-enumeration of audio devices during the run of the VM. Could mean plugging/connecting or the reverse of USB or Bluetooth devices is not stable. Old-school TRS wired headphones seem to not cause problems.

Try posting on the Bugtracker if no one comes along in a month or so. Post a log of the VM showing the problem happening on the Bugtracker ticket.

On Windows hosts, checking if Hyper-V is active may help. Please right-click the VM in the main Virtualbox window's VM list, choose Show Log. Search the far left tab's log for this text:

Attempting fall back to NEM

If you find it, Hyper-V is enabled and needs to be disabled. See HMR3Init: Attempting fall back to NEM (Hyper-V is active).

bertje, your log does not show this text, so no Hyper-V troubles for you.
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

@scottgus1 Thanks for your fast reply. In my case, the system freezes randomly after a while as well without reconnecting/disconnecting USB audio. Maybe it is related to audio in my case, but I'm not sure.

The string "Attempting fall back to NEM" is not found in my logs as you suggested.

Another way of checking if Hyper-V is enabled is to run the following command in Powershell as Administrator:

Code: Select all

PS C:\WINDOWS\system32> Get-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V

FeatureName      : Microsoft-Hyper-V
DisplayName      : Hyper-V Platform
Description      : Provides the services that you can use to create and manage virtual machines and their resources.
RestartRequired  : Possible
State            : Disabled
CustomProperties :
I'll check the bugtracker as you suggested.

The attached log was created directly after boot -> turn-on RME fireface 802 interface -> Ubuntu guest immediate freezes. I can post a screen capture when needed.
Please notice that the USB audio is connected to the Windows 10 host and USB is not routed to the Ubuntu guest as there is no Extension installed.
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

With every guest freeze I loose data and is the most critical issue for me. After 16 years using VirtualBox I'm now evaluating VMWare Workstation 16 as I cannot wait for a bugfix. I already noticed much better performance improvements in startup and graphic with Ubuntu 21.04 guest. VMware audio and video works out of the box without stuttering or high latency. I have to test VMware stability and audio upcoming days. Then I can judge if VirtualBox is broken or it has a different root cause and purchase a license.

Can someone report this freeze bug in the VirtualBox bugtracking system? I don't know how to easily do this.
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

Here is a screencapture of the freeze problem:

https://i.ibb.co/xFbd60J/Freeze-Virtual ... -Audio.gif

Random Ubuntu guest freezes also occurs after around >30 minutes not using the Windows 10 host, no audio changes. Then all unsaved data in the guest is lost as a hard reset of the guest is required. This happens multiple times a day which makes VirtualBox no longer useful.
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

Please find logs attached after a complete Ubuntu 21.04 guest freeze randomly at boot time, VirtualBox 6.1.20. Ubuntu logo is displayed and no longer responding, even when pressing the escape key.

Code: Select all

00:00:13.854679 VMMDev: vmmDevHeartbeatFlatlinedTimer: Guest seems to be unresponsive. Last heartbeat received 4 seconds ago

=> Then tried to generate a "graceful" ACPI shutdown which failed. Only hard power off works.
Attachments
Ubuntu21.04BootFreezeLogs.zip
(56.21 KiB) Downloaded 10 times
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Connect headset causes freeze

Post by fth0 »

bertje wrote:The problems started around February 2021. My hardware setup did not change
When did you buy your Samsung CH89 display? ;)

Can you try to reproduce your problem without it?
bertje
Posts: 58
Joined: 4. Nov 2010, 09:49
Primary OS: MS Windows 10
VBox Version: OSE other
Guest OSses: Ubuntu/MATE/Server 16.04, 18.04, 20.04, 21.04, 22.04, 23.10, Windows XP/7/10/11

Re: Connect headset causes freeze

Post by bertje »

@fth0, good question: I bought my Samsung LC34H890WJU monitor at 12 October 2020. It is connected via Displayport. VirtualBox worked for several months with this monitor.

I'll try with an old 1920x1080 Ilyama via HDMI instead and let you know the results.
fth0
Volunteer
Posts: 5668
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: Connect headset causes freeze

Post by fth0 »

In case you're wondering:

In Ubuntu21.04BootFreezeLogs.zip, the last log messages (at the crucial time) were about audio via DP.
Post Reply