No sound in Linux Mint guest

Discussions about using Linux guests in VirtualBox.
Post Reply
SanderA
Posts: 2
Joined: 4. Jan 2021, 15:27

No sound in Linux Mint guest

Post by SanderA »

I have multiple VirtualBox machines running Linux Mint 19 (as guest), and Linux Mint 20 as host.

I used to have that YouTube sometimes would only play about 0.2 seconds and then stop. I then rebooted my machine a couple of times, sometimes changed the audio controller, and then it worked again for some time.

I recently messed something up and installed Linux Mint again on the host. Now I have this problem mostly, if I change the settings the sound will work at 1 of the 20 tries. I also noticed that when I run play from the command line I get a lot of play WARN alsa: under-run messages.

I found (a site which I'm not allowed to post yet) which suggested to look for intel8x0_measure_ac97_clock messages in dmesg, which I found. I added options snd-intel8x0 ac97_clock=48000 at the end of /etc/modprobe.d/alsa-base.conf which removed the messages from dmesg, but did not solve the problem.

I played around with the settings.
- When I disable the sound controller I can play YoutTube videos fine, but have no sound
- When I change the sound controller to Soundblaster 16 I can play YoutTube videos fine, but have no sound
- Both ICH AC97 and Intel HD Audio give problems
- I tried switching the Host Audio Driver to PulseAudio and Alsa Audio driver, both give problems
- I tried enabling and disabling Audio Input, both give problems
- I tried switching the Motherboard Chipset to PIIX3 and ICH9, both give problems
- I tried disabling PAE/NX and Nested VT-x/AMD-V, which did not help
- I tried disabling Nested Paging, which did not help
- I tried to use Paravirtualization Interface Default and KVM, which did not help
- I tried upgrading the guest to Linux Mint 20, which did not help
- I tried adding options snd_hda_intel index=1,0 and options snd_hda_intel index=0 to /etc/modprobe.d/alsa-base.conf (as two tries, not at the same time), which did not help
- And lastly, I created a file /etc/asound.conf and added the lines below to it, this also did not help

Code: Select all

defaults.ctl.card     1
defaults.pcm.card     1
defaults.timer.card   1
So now I don't know what else I can try.

I installed VirtualBox from the official VirtualBox repo, not the one from Linux Mint. And the guest has the Guest Addons from the Devices menu of VirtualBox, so it is not installed using apt.
vbox-log.txt
VirtualBox logging
(95.51 KiB) Downloaded 17 times
dmesg-log.txt
Dmesg output
(36.98 KiB) Downloaded 15 times
fth0
Volunteer
Posts: 5677
Joined: 14. Feb 2019, 03:06
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Linux, Windows 10, ...
Location: Germany

Re: No sound in Linux Mint guest

Post by fth0 »

First of all, you've been starting the VM from a saved state. That's usually no good strategy when investigating problems, because the guest OS doesn't initialize the (virtual) hardware then. Please shut down the VM from within the guest OS and also reboot the host OS before executing further tests.
vbox-log.txt wrote:
00:00:02.717763 AC97: Using codec 'STAC9700'
00:00:02.718330 Audio: Initializing PulseAudio driver
00:00:02.720238 PulseAudio: Using v13.99.0
00:00:02.720775 PulseAudio: Failed to connect to server: Connection refused
00:00:02.720824 PulseAudio: Retrieving server information ...
00:00:02.720829 PulseAudio: Server information not available, skipping enumeration
If you're still seeing those log messages, you'll have to investigate inside the host OS why the PulseAudio server is refusing the connection.
SanderA
Posts: 2
Joined: 4. Jan 2021, 15:27

Re: No sound in Linux Mint guest

Post by SanderA »

Yes, that pointed me to the right direction. Thank you very much, I have been stuck with this problem for so long.

The following solved it for me.

Add the following to /etc/pulse/default.pa: load-module module-native-protocol-tcp auth-ip-acl=127.0.0.1 auth-anonymous=1

And create ~/.pulse/client.conf and add: default-server = 127.0.0.1
Post Reply