VirtualBox

Opened 3 years ago

Last modified 3 years ago

#20330 new defect

Pipewire audio server unusable

Reported by: Promet Owned by:
Component: audio Version: VirtualBox 6.1.20
Keywords: Cc:
Guest type: Linux Host type: Linux

Description

GNOME 40 introduces a new sound server, Pipewire, to replace pulseaudio to control sound under Linux.

Fedora 34 makes Pipewire as default, while it has a pulseaudio module to maintain compatibility, VirtualBox can't play sound with Pipewire, and it affects video playback as well.

Under GNOME settings, there is a testing option under sound preferences, no sound is available in the test.

If there is a video in a web page, like YouTube, sometimes sound can play 2-3 seconds but then the video will be muted, and frames are freezed as well, not only sound is unavailable but the video is affcted as well.

I tried to remove Pipewire and install Pulseaudio, everything is ok and back to normal again.

As Pipewire introduces many new features and better integration in future Linux development, it would be important to fix this issue before pulseaudio is completely phased out (it may take 2-3 years though...).

Change History (2)

comment:1 by Christian Hesse, 3 years ago

I had similar issue with "Intel HD Audio" emulated inside the VM. Looks like switching to "ICH AC97" does the trick for me.

comment:2 by gkamathh, 3 years ago

Until virtualbox support pipewire directly, one workaround would be to see if it can use the pulseaudio/alsa bridges.

If a user is

  • logged into GDM/GUI as unprivileged user
  • started a terminal window, in which, a sudo root shell is started
  • and from the root shell a root process VirtualBox Manager is started

Then one might need to set XDG_RUNTIME_DIR environment variable for the root Virtualbox manager process and its child processes to access pipewire-pulse sound bridge server.

I heard/got sound from inside VM only once among serveral reboots, with intel-HDA, so not sure if that is sufficient.

That said F35 still in beta, not exactly sure if there are chinks to be fixed.

[root@sirius gana]# pw-play /usr/share/sounds/alsa/Front_Left.wav
error: pw_context_connect() failed: Host is down

[root@sirius gana]# pipewire-pulse
[E][02591.905542] mod.protocol-pulse | [         utils.c:   66 get_runtime_dir()] could not find a suitable runtime directory in$PULSE_RUNTIME_PATH and $XDG_RUNTIME_DIR
[W][02591.905660] mod.protocol-pulse | [        server.c:  955 servers_create_and_start()] pulse-server 0x55fe0cee7160: failed to parse address 'unix:native': No such file or directory
[E][02591.905676] mod.protocol-pulse | [  pulse-server.c: 5102 pw_protocol_pulse_new()] 0x55fe0cee7160: no servers could be started: No such file or directory
[E][02591.905762] pw.conf      | [          conf.c:  412 load_module()] 0x55fe0cecc400: could not load mandatory module "libpipewire-module-protocol-pulse": Nosuch file or directory
[E][02591.905943] default      | [      pipewire.c:  123 main()] failed to create context: No such file or directory

[root@sirius gana]# ( export XDG_RUNTIME_DIR=/run/user/1000 ; VirtualBox ) &
[gana@sirius ~]$ uname -a
Linux sirius 5.15.0-0.rc3.20211001git4de593fb965f.30.fc35.x86_64 #1 SMP Mon Oct25 00:33:19 IST 2021 x86_64 x86_64 x86_64 GNU/Linux

[gana@sirius ~]$ cat /etc/system-release
Fedora release 35 (Thirty Five)

[gana@sirius ~]$ rpm -qa | grep -Ei "pipewire|wirep|pulse|alsa" | sort
alsa-lib-1.2.5.1-3.fc35.x86_64
alsa-sof-firmware-1.9-1.fc35.noarch
alsa-tools-1.2.5-2.fc35.x86_64
alsa-ucm-1.2.5.1-3.fc35.noarch
alsa-utils-1.2.5.1-2.fc35.x86_64
gvncpulse-1.2.0-3.fc35.x86_64
pipewire0.2-libs-0.2.7-6.fc35.x86_64
pipewire-0.3.38-1.fc35.x86_64
pipewire-alsa-0.3.38-1.fc35.x86_64
pipewire-gstreamer-0.3.38-1.fc35.x86_64
pipewire-jack-audio-connection-kit-0.3.38-1.fc35.x86_64
pipewire-libs-0.3.38-1.fc35.x86_64
pipewire-pulseaudio-0.3.38-1.fc35.x86_64
pipewire-utils-0.3.38-1.fc35.x86_64
pulseaudio-libs-15.0-2.fc35.x86_64
pulseaudio-libs-glib2-15.0-2.fc35.x86_64
pulseaudio-utils-15.0-2.fc35.x86_64
python3-alsa-1.1.6-17.fc35.x86_64
qemu-audio-alsa-6.1.0-9.fc35.x86_64
wireplumber-0.4.3-3.fc35.x86_64
wireplumber-libs-0.4.3-3.fc35.x86_64
Note: See TracTickets for help on using tickets.

© 2023 Oracle
ContactPrivacy policyTerms of Use