FreeBSD FBSD_13 13.0-CURRENT FreeBSD 13.0-CURRENT #3 r340586: Sun Nov 18 14:13:13 EST 2018 root@FBSD_13:/usr/obj/usr/src/amd64.amd64/sys/MYKERNEL amd64 1300003 virtualbox-ose-5.2.22 General-purpose full virtualizer for x86 hardware virtualbox-ose-kmod-5.2.22 VirtualBox kernel module for FreeBSD I had several virtual machines running on 12-current and all were working perfectly. Now on 13-current there seems to be issues with multimedia. Specifically videos do not play correctly. Steps to repeat: open Firefox 63.0.3 in a VM go to youtube try to play any video Does it play successfully? On the physical host I am able to successfully play any video with sound in Firefox.
I see a similar issue with virtualbox guests on FreeBSD 12 at the moment. As well as youtube videos not playing correctly for me I also don't have any audio. I'd like to listen to spotify using a virtual machine guest but can't at the moment. If anyone has any suggestions on what to try to fix this issue I'd be really appreciative. Thanks.
I too have this problem on FreeBSD 12.0-RELEASE-p2. Virtualbox-ose-5.2.22_2 installed from pkg does not play sound inside any guests. Driver OSS is selected for the guest and sound works normally on the host itself, but will not produce any sound from inside the guests.
I have similar problem too. I think that workaround to it is to install virtualbox from port and to use different sound server. Virtualbox-ose-5.2.26_1 with pulseaudio configuration works fine on my FreeBSD box (12.0-Release / amd64).
Created attachment 203632 [details] Screenshot of YouTube with KDE, Manjaro Linux
Created attachment 203633 [details] Screenshot of Vimeo with Lubuntu and with GhostBSD Looking For Something on Vimeo <https://vimeo.com/265045525>
Comment on attachment 203632 [details] Screenshot of YouTube with KDE, Manjaro Linux First Image of a Black Hole! - YouTube <https://www.youtube.com/watch?v=S_GVbuddri8> Playback ceases before the advertisement ends; the main video does not begin.
(In reply to Eijiro Shibusawa from comment #3) > … I think that workaround to it is to install virtualbox > from port and to use different sound server. … pulseaudio … How might I do this with poudriere? I experimented with a couple of lines in /usr/local/poudriere/ports/default/emulators/virtualbox-ose/Makefile.local but I guess that my lines were wrong, because the end result is still bugged by stalling after a moment's playback. ---- grahamperrin@momh167-gjp4-8570p:~ % date ; uname -v Sat 13 Apr 2019 11:23:39 BST FreeBSD 13.0-CURRENT r346108 GENERIC-NODEBUG grahamperrin@momh167-gjp4-8570p:~ % poudriere jail -i -j head | grep -i version Jail version: 13.0-CURRENT 1300018 grahamperrin@momh167-gjp4-8570p:~ %
Sorry, ignore my previous comment. I had forgotten to switch from OSS Audio Driver to PulseAudio in host driver preferences for the guest. The end result _is_ good. Here's my Makefile.local, two lines: PULSEAUDIO_CONFIGURE_OFF= BUILD_DEPENDS+= pulseaudio:audio/pulseaudio
I am experiencing this too, so I found this page and turned on the audio debugging it mentions: https://www.virtualbox.org/wiki/AudioDebug and in the logs, everything seems to be working, until it shows this: 00:00:18.694520 Audio: Stream '[OSSAudio] Output' could not be created in backend because of missing hardware / drivers which seems to be from line 3110 of src/VBox/Devices/Audio/DrvAudio.cpp. This is because VERR_AUDIO_STREAM_COULD_NOT_CREATE is getting returned by ossStreamOpen in src/VBox/Devices/Audio/DrvHostOSSAudio.cpp, which sets rc = VERR_AUDIO_STREAM_COULD_NOT_CREATE at the top. This looks like a logic error. Setting rc = VINF_SUCCESS at the top of ossStreamOpen allows further progress. But still there's no sound, it looks like we're hitting this assert: AssertMsgReturn(pCfgAcq->Backend.cfPreBuf <= pCfgAcq->Backend.cfBufferSize, ("Acquired pre-buffering size must be smaller or as big as the buffer size\n"), VERR_INVALID_PARAMETER); in src/VBox/Devices/Audio/DrvAudio.cpp. I think there's some sort of buffering issue which I don't fully understand. If you play around with the buffer sizes in s_OSSConf in src/VBox/Devices/Audio/DrvHostOSSAudio.cpp you can get sound, but it's choppy and stops working, reporting lots of buffering issues and eventually stops. And that's as far as I've gotten right now. Perhaps someone else can pick it up and find what's going on or perhaps I'll come back to it at another time. I'll post the patch for now.
Created attachment 205654 [details] patch which fixes logic error in DrvHostOSSAudio.cpp/ossStreamOpen Here's the logic error patch.
Created attachment 205683 [details] VBox DrvHostOSSAudio.cpp changes since 5.2.16 Hi there, I've just dug a bit for changes in VBox releases related to the src/VBox/Devices/Audio/DrvAudio.cpp, looks pretty interesting.
(In reply to Sergey A. Osokin from comment #11) Hey, thanks. It seems like those were part of some major changes of the audio stuff. I wonder if we should consider reverting upstream revs r73370 r73529 r73689 r73695 r73696 r73838 and r76553 and see what happens.
(In reply to Steve Wills from comment #12) Hey Steve, in a case to revert those revisions the patch looks smaller. Are there anybody can try it and report? Thanks in advance.
Created attachment 205706 [details] Reverting upstream revs r73370 r73529 r73689 r73695 r73696 r73838 and r76553
(In reply to Sergey A. Osokin from comment #14) /tmp/ports/usr/ports/emulators/virtualbox-ose/work/VirtualBox-5.2.32/src/VBox/Devices/Audio/DrvHostOSSAudio.cpp:160:21: error: no member named 'cBits' in 'PDMAUDIOPCMPROPS' pProps->cBits = 8; ~~~~~~ ^
In log file: 00:00:07.070098 OSS: Failed to open /dev/dsp: Operation not supported (45) 00:00:07.070110 Audio: Creating stream '[OSSAudio] Line-In' returned an invalid backend configuration, skipping 00:00:07.070127 OSS: Failed to open /dev/dsp: Operation not supported (45) 00:00:07.070130 Audio: Creating stream '[OSSAudio] Mic-In' returned an invalid backend configuration, skipping 00:00:07.073913 AC97: Reset
Alsa 00:00:06.989808 ALSA: Using output device "default" 00:00:07.004405 ALSA: Failed to set period size 2400 (Invalid argument) 00:00:07.004472 ALSA: Using input device "default" 00:00:07.007188 ALSA: Failed to open "default" as input device: Operation not supported 00:00:07.007242 ALSA: Using input device "default" 00:00:07.010024 ALSA: Failed to open "default" as input device: Operation not supported 00:00:07.014107 AC97: Reset (default snd device - HDMI out, so input err should ok)
I'd really like to see this fixed too. For various reasons I'd rather not have to pull in Pulseaudio and maintain local builds of Virtualbox. If there's anything I can do to keep it moving along.
Created attachment 214798 [details] Patch for testing audio in guest OS This patch solves the problem for me. Can somebody test it?
I confirm that this patch works! 13.0-CURRENT FreeBSD 13.0-CURRENT #1 r360882 virtualbox-ose-5.2.42 Using OSS.
(In reply to Andrey Russev from comment #19) Hi, The patch solves the problem. I built patched virtualbox-ose-5.2.34_4 by using poudriere. For applying the patch in jail I used hook that is described the following page. https://dan.langille.org/2019/08/10/poudriere-hooks/(In reply to Andrey Russev from comment #19)
Adding my "works for me" comment. Even the microphone is picked up; now I can use Gotomeeting in FreeBSD from my Win10 VM!
Created attachment 216400 [details] Port patch to fix OSS audio support Just tested on 12_Stable and the patched version works. It's probably unrelated, but I an getting what sounds like static clicks or pops from a vinyl disk. Still, the audio is listenable and it has not been for some time. I have attached a port patch for this that may be applied to the port in the standard fashion.
The patch works also for resolving the (probably duplicate) bug #237472. See me comments there. -- Martin
Why wasn't this patch added to the virtualbox-ose-5.2.44 port? I had no sound in the FreeBSD 12.1 guest system. When I added this patch and recompiled the port, the sound appeared. My host system FreeBSD 12.1 RELEASE-p7 amd64. I wish this patch was added to the virtualbox-ose-5.2.44 port. This patch is working.
I'm confused, how was this 'overcome by events'? Re: https://wiki.freebsd.org/Sound#Advanced I'm using virtual_oss and (for example) with Firefox 81 on the host computer media.cubeb.backend set to oss, I do get sound with OSS. However … … no sound from the VirtualBox guests that are set to OSS Audio Driver. The misbehaviour is as observed when this bug was open; AV content will not play. grahamperrin@momh167-gjp4-8570p:~ % date ; uname -v Tue 22 Sep 2020 05:59:29 BST FreeBSD 13.0-CURRENT #64 r365364: Sun Sep 6 01:38:18 BST 2020 root@momh167-gjp4-8570p:/usr/obj/usr/src/amd64.amd64/sys/GENERIC-NODEBU grahamperrin@momh167-gjp4-8570p:~ % pkg info -x virtualbox virtualbox-ose-5.2.44_1 virtualbox-ose-kmod-5.2.44_1 grahamperrin@momh167-gjp4-8570p:~ % pkg query '%o %v %R' virtualbox-ose virtualbox-ose-kmod emulators/virtualbox-ose 5.2.44_1 FreeBSD emulators/virtualbox-ose-kmod 5.2.44_1 poudriere grahamperrin@momh167-gjp4-8570p:~ %
Make sure that patch-src_VBox_Devices_Audio_DrvHostOSSAudio.cpp is in emulators/virtualbox-ose/files before compiling the port.
(In reply to Graham Perrin from comment #26) > I'm confused, how was this 'overcome by events'? I guess, this makes more sense if I view the symptoms i.e. comment 1 as resulting from more recent bug 237472 with this older bug 233301 as a _duplicate_ of 237472
patch-src_VBox_Devices_Audio_DrvHostOSSAudio.cpp is unusable with % uname -a FreeBSD flash2.usenet-fr.net 12.1-RELEASE-p6 FreeBSD 12.1-RELEASE-p6 GENERIC amd64 and up-to-date port tree. % grep ^PORTVERSION /usr/ports/emulators/virtualbox-ose/Makefile PORTVERSION= 5.2.44 I have no audio in my FreeBSD virtualbox :(
(In reply to Jean-Claude MICHOT from comment #29) bug 237472