Dave Heinemann

Broken Audio in Fedora 35 with Wireplumber 0.4.10

I must be unlucky because I've encountered my second breakage on Fedora 35 in just a couple of weeks! Other than this, Fedora has been the most stable and hassle-free Linux distros I've ever used, so I'm sure these are just outliers. In fact, this one is partially my own fault. Maybe you're in the same boat as me?

A couple of days ago I upgraded Wireplumber to 0.4.10-1 on my Fedora 35 desktop. After restarting, Gnome no longer detected my audio devices (speakers/microphone) and I was unable to play or record audio.

Screnshot of Gnome Settings showing that the list of Output Devices is empty
The list of available Output Devices in Gnome Settings is empty

Despite this, systemctl shows that the relevant PipeWire services are all running. pipewire-pulse shows a 'pactl' error, but I don't think it's related.

[david@Abraxas ~]$ systemctl --user status pipewire*
● pipewire.socket - PipeWire Multimedia System Socket
     Loaded: loaded (/usr/lib/systemd/user/pipewire.socket; enabled; vendor preset: enabled)
     Active: active (running) since Mon 2022-05-16 20:43:44 AEST; 2min 51s ago
   Triggers: ● pipewire.service
     Listen: /run/user/1000/pipewire-0 (Stream)
     CGroup: /user.slice/user-1000.slice/user@1000.service/app.slice/pipewire.socket

May 16 20:43:44 Abraxas systemd[2251]: Listening on PipeWire Multimedia System Socket.

● pipewire-pulse.service - PipeWire PulseAudio
     Loaded: loaded (/usr/lib/systemd/user/pipewire-pulse.service; disabled; vendor preset: disabled)
     Active: active (running) since Mon 2022-05-16 20:43:44 AEST; 2min 51s ago
TriggeredBy: ● pipewire-pulse.socket
   Main PID: 12427 (pipewire-pulse)
      Tasks: 2 (limit: 38220)
     Memory: 1.5M
        CPU: 9ms
     CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/pipewire-pulse.service
             └─12427 /usr/bin/pipewire-pulse

May 16 20:43:44 Abraxas systemd[2251]: Started PipeWire PulseAudio.
May 16 20:43:44 Abraxas pipewire-pulse[12442]: pw.conf: execvp error 'pactl': No such file or directory

● pipewire.service - PipeWire Multimedia Service
     Loaded: loaded (/usr/lib/systemd/user/pipewire.service; disabled; vendor preset: disabled)
    Drop-In: /usr/lib/systemd/user/pipewire.service.d
             └─00-uresourced.conf
     Active: active (running) since Mon 2022-05-16 20:43:44 AEST; 2min 51s ago
TriggeredBy: ● pipewire.socket
   Main PID: 12425 (pipewire)
      Tasks: 2 (limit: 38220)
     Memory: 1.7M
        CPU: 12ms
     CGroup: /user.slice/user-1000.slice/user@1000.service/session.slice/pipewire.service
             └─12425 /usr/bin/pipewire

May 16 20:43:44 Abraxas systemd[2251]: Started PipeWire Multimedia Service.

● pipewire-pulse.socket - PipeWire PulseAudio
     Loaded: loaded (/usr/lib/systemd/user/pipewire-pulse.socket; enabled; vendor preset: enabled)
     Active: active (running) since Mon 2022-05-16 20:43:44 AEST; 2min 51s ago
   Triggers: ● pipewire-pulse.service
     Listen: /run/user/1000/pulse/native (Stream)
     CGroup: /user.slice/user-1000.slice/user@1000.service/app.slice/pipewire-pulse.socket

May 16 20:43:44 Abraxas systemd[2251]: Listening on PipeWire PulseAudio.

Workaround

I tried downgrading Wireplumber to 0.4.4-2, then restarting the PipeWire services:

sudo dnf downgrade wireplumber
systemctl --user restart pipewire*

Sure enough, this fixed the issue and audio worked again. But that's not a permanent solution. Why did this occur in the first place?

The Problem

The issue seems to be that Wireplumber 0.4.10 includes important config changes that are required for audio to work. However, if you have manually modified your Wireplumber configs at any point, you won't receive these config changes automatically! I assume this is a distro feature to prevent users' customisations from being overwritten by package upgrades. In my case, I had modified /etc/wireplumber/main.lua.d/50-alsa-config.lua to fix an audio pop issue1.

The Solution

To restore audio, you must update your Wireplumber configs, and then restart your PipeWire services to apply them. There are two options.

Option 1: Manually Copy the Required Changes

To preserve your Wireplumber customisations, you can manually copy the necessary changes into your existing Wireplumber configs in /etc/wireplumber/main.lua.d/ . A full list of required changes in each file can be found in this Wireplumber commit.

In my case, I had to add this line to the start of /etc/wireplumber/main.lua.d/50-alsa-config.lua:

alsa_monitor.enabled = true

After making your changes, restart the PipeWire services:

systemctl --user restart pipewire*

Option 2: Restore Wireplumber Defaults

If you're unsure what changes to apply or where, you can simply restore your Wireplumber configs to their defaults. Copy the default configs from /usr/share/wireplumber/main.lua.d/ to /etc/wireplumber/main.lua.d/ . Don't forget to take a backup first!

After making your changes, restart the PipeWire services:

systemctl --user restart pipewire*

Thanks to grumpey0 for highlighting the issue and resolution on the Fedora bug tracker! You made this really easy for me to troubleshoot and fix.

Further Information

Do you have any thoughts or feedback? Let me know via email!
  1. I should probably find a way to do this in my home directory's configs instead, but that's a job for another day.↩

#Fedora #Linux