Guest's audio stops - "reset" it without restarting the VM?

Discussions related to using VirtualBox on Windows hosts.
Post Reply
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

I'm often having an audio problem with some of my VMs (Win10 64 host, various Windows guests).
While I'm listening/watching multimedia stuff inside the VM, the audio suddenly stops, with no error messages at all, neither from VBox nor from the involved OSes (guest and host).
Everything is reported to work fine, the audio level meters regularly move, but no more sound is heard.
To have the audio back I must shutdown (or close saving state) the VM and restart it (from scratch or restoring the saved state); this... workaround is always successful (maybe because something gets re-initialized?), but it is obviously quite uncomfortable.

I've never been able to spot the cause of those audio failures; I'm afraid it could lie in my audio card 64 bit driver, which is quite old and can not be updated, so I'm not "blaming" VBox for that.
I'm opening this topic just because I'd like to know whether the audio of a VM can somehow be "reset" (restarted, re-initialized...) without having to close and reopen the whole VM every time. In other words, I'd like to know if there is a way to obtain, without closing and reopening a VM, the same "audio repair" effect I get when I close and reopen.

Thanks in advance for any help or advice.


Update: I saw in the forum that other users, also with older VBox releases, have reported quite similar behaviours (guest audio stopping after a while and coming back after restart), so perhaps VBox may have some... guilt too. Anyway, any hints or suggestions are welcome. :)
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

As your search has shown, audio has been having its share of problems, and the reason is quite simple actually; timing, deterministic timing. This is something that a VM is not good at, because it doesn't have access to the hardware that a host has, and the timing/synchronization is in ... the ballpark.

And you may never notice a glitch in the timing when doing Network, I/O or CPU heavy tasks, but you will definitely notice even a few ms of delay in an audio/video application.

It's the human perception that's wrong, not the VM! :D
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

I understand your point and I thank you for your technical explanation.
Sadly the problems I'm referring to don't involve time glitches, delays and so on, all of which assume the audio to be "on", working, hearable. I'm talking about the audio just disappearing, suddenly, with no apparent reason, totally and also definitely (until the VM gets restarted).
I tried all I could think of, but I never found a way to revive it apart from closing and restarting the VM (which is obvious and hardly classifiable as a "remedy").

So I thought (hoped): there must be, technically, a way to make (just) the VM audio engine to somehow reset itself, some kind of workaround to get over the silence without closing and restarting. Especially if these audio problems are a kind of known... weakness of VMs. Something like the way I found out to momentarily bypass the VBox6 problem with shared folders sometimes getting lost (I edit the shared folder definition, while keeping the VM alive).
Maybe I just didn't find out the right method yet, or maybe something can be done with the command line.
Just an illusory hope of mine?
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

We need to see a complete VBox.log, from a complete VM run, where the problem occurs:
  • Start the VM from cold-boot (not from a paused or saved state) / Observe problem / Shutdown the VM (force close it if you have to).
  • With the VM completely shut down (not paused or saved), right-click on the VM in the VirtualBox Manager and select "Show Log".
  • Save only the first "VBox.log", ZIP it and attach it to your response. See the "Upload attachment" tab below the reply form.
And an explanation on what you were doing, just to see if it's reproducible or not, don't just dump a log without any context..

One thing I can think of, and I'm not sure if it's going to work or not, would be to go to the VM Settings » Audio » Enable Audio Input/Output, toggle those. Or from the status bar, the audio icon Image.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

Thanks for your answer.
I'll try to provide what you asked for as soon as I can.
As to enabling/disabling the audio I/O from the VM status bar (or menu), sadly it's a move I have already tried, without success. :]
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

I followed your instructions.
Once inside the VM I watched some mp4 files with vlc (portable) player; then I closed vlc and started Firefox, trying to watch a Youtube video, which was played without audio.
I closed the browser and started vlc again, trying to watch the same mp4 files as before, but they were played without audio as well. The audio was gone.
That's exactly what usually happens, not only in this particular VM but also in others. Besides, often the audio "stop" occurs while using just vlc (without launching other programs), when switching from a video file to another or even when jumping from a point to another inside the same video file.
As always, when I started the VM again (after saving the log file) the audio was back.

UPDATE (09 apr.): as a further experiment, I tried a similar procedure focusing more on audio, with another VM (Win8 x64) and two different programs (the Windows built-in media player and a simple midi sequencer with built-in synth and universal asio driver). As expected, something quite similar happened. Immediately after starting the VM (from scratch) I tried to playback a wav file with the media player: the sound was there. Then I launched the other program but, despite all graphic meters (both the program's ones and the OS ones) showing normal activity, no sound could be heard. After closing that program, also Windows media player had become mute. As with the other VM, no error messages or warnings whatsoever, neither from VBox, nor from Windows, nor from the involved applications.
Attachments
W8-log.zip
(29.4 KiB) Downloaded 25 times
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

Nothing in the log, absolutely nothing! You might want to take a look at the Investigating audio problems how-to...
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

Well, that's both good and bad news...
I really hoped something useful could lie in the log :)

Maybe it's a useless information, but I found, in the log of the second VM I referred to, a few occurrences of lines like these:

Code: Select all

...
00:00:10.706427 AIOMgr: Async flushes not supported
00:00:24.130776 RTC: period=0x20 (32) 1024 Hz
00:00:29.731366 DSound: Guest source 'Line In' is using host recording device with GUID '{A0BAD4DB-0EC9-44D0-97B4-84E1FF6C3AB9}'
00:00:29.744954 HDA: Set recording source for 'Line In' to 'DirectSound audio driver'
00:01:21.128198 Audio: Disabling input for driver 'DSoundAudio'
00:01:21.143210 Audio: Enabling input for driver 'DSoundAudio'
00:01:21.143602 HDA: Set recording source for 'Line In' to 'DirectSound audio driver'
00:02:13.234237 RTC: period=0x200 (512) 64 Hz
...
Can those have some relevance?

In any case, I thank you for your help. I'll surely go through the "how-to" you suggested.

Anyway, apart from possible audio problems and going back to my very first question, shall we conclude that there is absolutely no way in VBox to "reset" a VM audio without restarting the VM?
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

Armando wrote:in the log of the second VM I referred to, a few occurrences of lines like these:
Normal messages, nothing serious or important, normal workflow...
Armando wrote:shall we conclude that there is absolutely no way in VBox to "reset" a VM audio without restarting the VM?
Already told you the only known option to affect the audio from the host side; enable/disable output, but that does absolutely nothing to the guest.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Armando
Posts: 101
Joined: 26. May 2012, 06:50

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Armando »

socratis wrote:Already told you the only known option to affect the audio from the host side; enable/disable output ...
I well remember that and, as I said, I had already tried that option.
I hoped there was some way, maybe complicated but anyway faster than closing/restarting, to act from the guest side.

As these "audio off until restart" episodes do occur only when I'm using a VM (they never occur while using other applications in the host) I was led to think they had to be somehow related to VBox and the way it manages the host<>guest audio interface. That was the main reason for my above mentioned (vain) hope.
In the end it seems I'll have to live with this unsolved problem, at least hoping that some future VBox release incidentally "solve" it somehow.
It would not be the first time, with computers, that an apparently mysterious problem seems to... mysteriously solve itself. :)
Thanks anyway for your help.
William Ruppel
Posts: 2
Joined: 8. Nov 2014, 22:06
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: OL 7.6

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by William Ruppel »

Socratis,

I am having what appears to be the same issue. I entered a bug in BugDB for this back in Feb, but there's been absolutely no action. Does the VB team not look at or use BugDB?

In any event, please look at bug 29324472, I have additional detail there. Please let me know what else you or the team needs.

Thanks,

- Bill
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

William Ruppel wrote:I am having what appears to be the same issue
What issue would that be? Audio stopping? Audio resetting? Please explain...
William Ruppel wrote:I entered a bug in BugDB for this back in Feb, but there's been absolutely no action
Under what username? Can't seem to recall something, although I could be wrong, there are more audio tickets than I would care to count.

The only ticket that I can find under your name ("William Ruppel") is ticket #18569: Operation Not Permitted Copying Files from Linux Guest to Windows Host via Shared Folder, opened just yesterday on 2019-04-17 14:38:19 UTC.
William Ruppel wrote:In any event, please look at bug 29324472, I have additional detail there
I'm afraid that there's no bug/ticket 29324472 in VirtualBox, the maximum as of this writing is #18575. Are you referring to something else, a different BugDB altogether?
William Ruppel wrote:Does the VB team not look at or use BugDB?
Yes, as long as the is real, tangible, well documented, with a reproducible scenario, yes, absolutely! The vague ones like "HELP! IT CRASHES!" tend to be ignored...
William Ruppel wrote:Please let me know what else you or the team needs.
How about 1) the correct ticket, 2) a detailed explanation of what's really going on (in complete details), instead of a "me too"...

BTW, you too are part of the "team", we're all in this together... ;)
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
William Ruppel
Posts: 2
Joined: 8. Nov 2014, 22:06
Primary OS: MS Windows 10
VBox Version: PUEL
Guest OSses: OL 7.6

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by William Ruppel »

I was referring to an issue I entered in the Oracle BugDB system. i.e. I'm an Oracle employee.

If no-one is monitoring BugDB for issues, then I'll go ahead and enter the same in the bug tracker here.

Thanks.
socratis
Site Moderator
Posts: 27329
Joined: 22. Oct 2010, 11:03
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Win(*>98), Linux*, OSX>10.5
Location: Greece

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by socratis »

William Ruppel wrote:I was referring to an issue I entered in the Oracle BugDB system. i.e. I'm an Oracle employee.
Ah! You should have mentioned that, we're not Oracle employees here (except a select a few), and we can't possibly have access to that DB.
William Ruppel wrote:I'll go ahead and enter the same in the bug tracker here.
Make sure that you search the bugtracker first, there's a ton of audio related tickets open, one is bound to cover your case. No need for yet another duplicate.
Do NOT send me Personal Messages (PMs) for troubleshooting, they are simply deleted.
Do NOT reply with the "QUOTE" button, please use the "POST REPLY", at the bottom of the form.
If you obfuscate any information requested, I will obfuscate my response. These are virtual UUIDs, not real ones.
Teobaldo
Posts: 1
Joined: 16. Mar 2021, 17:04

Re: Guest's audio stops - "reset" it without restarting the VM?

Post by Teobaldo »

I know isn't a definitive solution, but try to restart "Audiosrv" service on Windows x64 and sound should return.
Last edited by scottgus1 on 16. Mar 2021, 23:55, edited 1 time in total.
Reason: removed full quote of previous message
Post Reply