MX 23 Going back to pulseaudio (step-by-step tutorial)
Posted: Sun Aug 06, 2023 8:36 am
As described in this thread ( viewtopic.php?t=76364 ) I'm not super-happy about the switch to pipewire. It usually runs fine, but if you're used to pulseaudio and have no need for pipewire's features, it might be a reasonable choice to go back to pulseaudio. Debian 12 decided to put pipewire as default. An interesting detail about that decision is that this is only the case for GNOME. Debian KDE for example will still use pulseaudio by the choice of the Debian KDE maintainers.
I read that the pulseaudio daemon gets spawned any time an application calls for audio and if it isn't running yet, so I figured that there shouldn't be much configuration to do. So I decided to just try to do the switch back to pulse and it worked flawlessly.
So in case anyone who's suffering from audio issues might find this info useful, I documented the steps I did. Be aware that all output is in German as this is my system's language.
Disclaimer: I do not know how easy/difficult it is to revert back to pipewire in case pulseaudio doesn't work for you. There is the package pipewire-setup-mx which should reinstall and reconfigure pipewire, but I did not do this.
Do this on your own risk!
1. Let's get an overview what's on the system. So we query all packages that contain "wire".
We basically want to get rid of all except the two wireless packages that have nothing to do with pipewire.
2. After tinkering with apt --dry-run a bit I found this to be the cleanest command.
apt automatically recognizes what you want to do and replaces pipewire with pulseaudio. dpkg then sorts out some dependencies and apt configures needed systemd links even if you're booted with SysVinit (which I am).
3. Get rid of orphan pipewire packages with a regular autoremove.
4. (optional) Check for orphan configurations and get rid of those with a purge ~c.
EDIT: Performance improvements.
In step 2 apt recommends to install the package rtkit. This is a daemon that helps pulseaudio to gain a higher priority on the system to avoid cracking or other audio glitches. It will start automatically after installation.
DONE! Now the only thing we have left to do is reboot the system and pulseaudio will take over the audio system.
BONUS: One might notice that libpipewire-0.3-0 did not get removed.
That is the because apparently it's a dependency to A LOT of important other packages. DO NOT REMOVE THIS PACKAGE AS THIS WILL BREAK PARTS OF YOUR SYSTEM. It's a situation that looks a little like Linus Tech Tips' faux-pas to uninstall the desktop environment due to a dependency error in case you know about that.
ONLY RUN THIS COMMAND WITH --DRY-RUN to check its output.
I read that the pulseaudio daemon gets spawned any time an application calls for audio and if it isn't running yet, so I figured that there shouldn't be much configuration to do. So I decided to just try to do the switch back to pulse and it worked flawlessly.
So in case anyone who's suffering from audio issues might find this info useful, I documented the steps I did. Be aware that all output is in German as this is my system's language.
Disclaimer: I do not know how easy/difficult it is to revert back to pipewire in case pulseaudio doesn't work for you. There is the package pipewire-setup-mx which should reinstall and reconfigure pipewire, but I did not do this.
Do this on your own risk!
1. Let's get an overview what's on the system. So we query all packages that contain "wire".
Code: Select all
$ apt list --installed | grep wire
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
gstreamer1.0-pipewire/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
libpipewire-0.3-0/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
libpipewire-0.3-modules/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
libwireplumber-0.4-0/stable,now 0.4.13-1 amd64 [Installiert,automatisch]
pipewire-alsa/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
pipewire-bin/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
pipewire-jack/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
pipewire-pulse/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
pipewire-setup-mx/mx,mx,now 23.05.10 all [installiert]
pipewire/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
wireless-regdb/stable,stable,now 2022.06.06-1 all [installiert]
wireless-tools/stable,now 30~pre9-14 amd64 [installiert]
wireplumber/stable,now 0.4.13-1 amd64 [Installiert,automatisch]
2. After tinkering with apt --dry-run a bit I found this to be the cleanest command.
Code: Select all
$ sudo apt remove pipewire
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut… Fertig
Statusinformationen werden eingelesen… Fertig
Die folgenden Pakete wurden automatisch installiert und werden nicht mehr benötigt:
liblc3-0 libldacbt-abr2 libpipewire-0.3-modules libspa-0.2-bluetooth libspa-0.2-jack libwireplumber-0.4-0 pipewire-bin
Verwenden Sie »sudo apt autoremove«, um sie zu entfernen.
Die folgenden zusätzlichen Pakete werden installiert:
pulseaudio
Vorgeschlagene Pakete:
pavumeter paprefs
Empfohlene Pakete:
rtkit
Die folgenden Pakete werden ENTFERNT:
gstreamer1.0-pipewire pipewire pipewire-alsa pipewire-jack pipewire-pulse pipewire-setup-mx wireplumber
Die folgenden NEUEN Pakete werden installiert:
pulseaudio
0 aktualisiert, 1 neu installiert, 7 zu entfernen und 0 nicht aktualisiert.
Es müssen 1.174 kB an Archiven heruntergeladen werden.
Nach dieser Operation werden 5.000 kB Plattenplatz zusätzlich benutzt.
Möchten Sie fortfahren? [J/n]
Holen:1 http://deb.debian.org/debian bookworm/main amd64 pulseaudio amd64 16.1+dfsg1-2+b1 [1.174 kB]
Es wurden 1.174 kB in 1 s geholt (1.969 kB/s).
(Lese Datenbank ... 345260 Dateien und Verzeichnisse sind derzeit installiert.)
Entfernen von pipewire-setup-mx (23.05.10) ...
Entfernen von gstreamer1.0-pipewire:amd64 (0.3.65-3) ...
Entfernen von wireplumber (0.4.13-1) ...
Entfernen von pipewire-alsa:amd64 (0.3.65-3) ...
Vormals nicht ausgewähltes Paket pulseaudio wird gewählt.
(Lese Datenbank ... 345126 Dateien und Verzeichnisse sind derzeit installiert.)
Vorbereitung zum Entpacken von .../pulseaudio_16.1+dfsg1-2+b1_amd64.deb ...
Entpacken von pulseaudio (16.1+dfsg1-2+b1) ...
(Lese Datenbank ... 345367 Dateien und Verzeichnisse sind derzeit installiert.)
Entfernen von pipewire-jack:amd64 (0.3.65-3) ...
dpkg: pipewire-pulse: Abhängigkeitsprobleme, wird aber wie gefordert dennoch entfernt:
libcanberra-pulse:amd64 hängt ab von pulseaudio | pipewire-pulse; aber:
Paket pulseaudio ist noch nicht konfiguriert.
Paket pipewire-pulse soll entfernt werden.
Entfernen von pipewire-pulse (0.3.65-3) ...
dpkg: pipewire:amd64: Abhängigkeitsprobleme, wird aber wie gefordert dennoch entfernt:
firefox hängt ab von pulseaudio | apulse | pipewire; aber:
Paket pulseaudio ist noch nicht konfiguriert.
Paket apulse ist nicht installiert.
Paket pipewire:amd64 soll entfernt werden.
Entfernen von pipewire:amd64 (0.3.65-3) ...
pulseaudio (16.1+dfsg1-2+b1) wird eingerichtet ...
Created symlink /etc/systemd/user/default.target.wants/pulseaudio.service → /usr/lib/systemd/user/pulseaudio.service.
Created symlink /etc/systemd/user/sockets.target.wants/pulseaudio.socket → /usr/lib/systemd/user/pulseaudio.socket.
Trigger für man-db (2.11.2-2) werden verarbeitet ...
Trigger für dbus (1.14.8-2~deb12u1) werden verarbeitet ...
3. Get rid of orphan pipewire packages with a regular autoremove.
Code: Select all
$ sudo apt autoremove
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut… Fertig
Statusinformationen werden eingelesen… Fertig
Die folgenden Pakete werden ENTFERNT:
liblc3-0 libldacbt-abr2 libpipewire-0.3-modules libspa-0.2-bluetooth libspa-0.2-jack libwireplumber-0.4-0 pipewire-bin
0 aktualisiert, 0 neu installiert, 7 zu entfernen und 0 nicht aktualisiert.
Nach dieser Operation werden 7.477 kB Plattenplatz freigegeben.
Möchten Sie fortfahren? [J/n]
(Lese Datenbank ... 345334 Dateien und Verzeichnisse sind derzeit installiert.)
Entfernen von libspa-0.2-bluetooth:amd64 (0.3.65-3) ...
Entfernen von liblc3-0:amd64 (1.0.1-1+b1) ...
Entfernen von libldacbt-abr2:amd64 (2.0.2.3+git20200429+ed310a0-4) ...
Entfernen von pipewire-bin (0.3.65-3) ...
Entfernen von libpipewire-0.3-modules:amd64 (0.3.65-3) ...
Entfernen von libspa-0.2-jack:amd64 (0.3.65-3) ...
Entfernen von libwireplumber-0.4-0:amd64 (0.4.13-1) ...
Trigger für man-db (2.11.2-2) werden verarbeitet ...
Trigger für libc-bin (2.36-9+deb12u1) werden verarbeitet ...
4. (optional) Check for orphan configurations and get rid of those with a purge ~c.
Code: Select all
$ apt list ~c
Auflistung… Fertig
pipewire-bin/stable,now 0.3.65-3 amd64 [Konfiguration-verbleibend]
pipewire-pulse/stable,now 0.3.65-3 amd64 [Konfiguration-verbleibend]
pipewire-setup-mx/mx,mx,now 23.05.10 all [Konfiguration-verbleibend]
pipewire/stable,now 0.3.65-3 amd64 [Konfiguration-verbleibend]
wireplumber/stable,now 0.4.13-1 amd64 [Konfiguration-verbleibend]
Code: Select all
$ sudo apt purge ~c
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut… Fertig
Statusinformationen werden eingelesen… Fertig
Die folgenden Pakete werden ENTFERNT:
pipewire* pipewire-bin* pipewire-pulse* pipewire-setup-mx* wireplumber*
0 aktualisiert, 0 neu installiert, 5 zu entfernen und 0 nicht aktualisiert.
Nach dieser Operation werden 0 B Plattenplatz zusätzlich benutzt.
Möchten Sie fortfahren? [J/n]
(Lese Datenbank ... 345124 Dateien und Verzeichnisse sind derzeit installiert.)
Löschen der Konfigurationsdateien von pipewire-setup-mx (23.05.10) ...
Löschen der Konfigurationsdateien von pipewire-bin (0.3.65-3) ...
Löschen der Konfigurationsdateien von wireplumber (0.4.13-1) ...
Löschen der Konfigurationsdateien von pipewire-pulse (0.3.65-3) ...
Löschen der Konfigurationsdateien von pipewire:amd64 (0.3.65-3) ...
EDIT: Performance improvements.
In step 2 apt recommends to install the package rtkit. This is a daemon that helps pulseaudio to gain a higher priority on the system to avoid cracking or other audio glitches. It will start automatically after installation.
Code: Select all
sudo apt install rtkit
BONUS: One might notice that libpipewire-0.3-0 did not get removed.
Code: Select all
$ apt list --installed | grep wire
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
libpipewire-0.3-0/stable,now 0.3.65-3 amd64 [Installiert,automatisch]
wireless-regdb/stable,stable,now 2022.06.06-1 all [installiert]
wireless-tools/stable,now 30~pre9-14 amd64 [installiert]
ONLY RUN THIS COMMAND WITH --DRY-RUN to check its output.
Code: Select all
$ sudo apt remove libpipewire-0.3-0 --dry-run
Paketlisten werden gelesen… Fertig
Abhängigkeitsbaum wird aufgebaut… Fertig
Statusinformationen werden eingelesen… Fertig
Die folgenden Pakete wurden automatisch installiert und werden nicht mehr benötigt:
flatpak fonts-open-sans libappstream4 libavkys9 libmalcontent-0-0 libmujs2 libostree-1-1 libqt5qmlworkerscript5 libqt5quickcontrols2-5
libqt5quicktemplates2-5 libqt6widgets6 libqt6xml6 libsixel1 libspa-0.2-modules libstemmer0d libuvc0 libxmlb2 qml-module-qt-labs-folderlistmodel
qml-module-qt-labs-platform qml-module-qt-labs-settings qml-module-qtgraphicaleffects qml-module-qtqml qml-module-qtqml-models2
qml-module-qtquick-controls qml-module-qtquick-controls2 qml-module-qtquick-dialogs qml-module-qtquick-extras qml-module-qtquick-layouts
qml-module-qtquick-privatewidgets qml-module-qtquick-templates2 qml-module-qtquick-window2 qml-module-qtquick2 socat webcamoid-data
Verwenden Sie »sudo apt autoremove«, um sie zu entfernen.
Die folgenden zusätzlichen Pakete werden installiert:
libenca0 libvorbisidec1 mplayer
Vorgeschlagene Pakete:
mplayer-doc
Die folgenden Pakete werden ENTFERNT:
libpipewire-0.3-0 mpv mx-apps mx-packageinstaller mx-packageinstaller-pkglist qpwgraph smplayer smplayer-l10n smplayer-themes webcamoid
webcamoid-plugins xdg-desktop-portal xdg-desktop-portal-gtk
Die folgenden NEUEN Pakete werden installiert:
libenca0 libvorbisidec1 mplayer
0 aktualisiert, 3 neu installiert, 13 zu entfernen und 0 nicht aktualisiert.
Remv mx-apps [23.07.02mx23]
Remv mx-packageinstaller [23.7.02] [mx-packageinstaller-pkglist:amd64 ]
Remv mx-packageinstaller-pkglist [23.08.04mx23]
Remv xdg-desktop-portal-gtk [1.14.1-1]
Remv xdg-desktop-portal [1.16.0-2]
Remv webcamoid [9.0.0-6]
Remv webcamoid-plugins [9.0.0-6]
Remv libpipewire-0.3-0 [0.3.65-3] [mpv:amd64 qpwgraph:amd64 ]
Remv smplayer-themes [1:20.11.0-1] [smplayer:amd64 mpv:amd64 qpwgraph:amd64 ]
Remv smplayer [23.6.0-0.1~mx23+1] [mpv:amd64 qpwgraph:amd64 smplayer-l10n:amd64 ]
Remv smplayer-l10n [23.6.0-0.1~mx23+1] [mpv:amd64 qpwgraph:amd64 ]
Remv mpv [0.35.1-4] [qpwgraph:amd64 ]
Remv qpwgraph [0.3.9-1]
Inst libenca0 (1.19-1.1 Debian:12.1/stable [amd64])
Inst libvorbisidec1 (1.2.1+git20180316-7 Debian:12.1/stable [amd64])
Inst mplayer (2:1.5+svn38408-1 Debian:12.1/stable [amd64])
Conf libenca0 (1.19-1.1 Debian:12.1/stable [amd64])
Conf libvorbisidec1 (1.2.1+git20180316-7 Debian:12.1/stable [amd64])
Conf mplayer (2:1.5+svn38408-1 Debian:12.1/stable [amd64])