How to Install and Configure PipeWire in Linux

Pipewire Studio

Since it came to the scene in 2017, PipeWire saw itself as a powerful contender to replace PulseAudio, but it still had a lot of kinks to work out with its stability. Now that it has gained a strong reputation as a more established audio service for Linux many years later, users are now getting curious on whether the upgrade to PipeWire is really worth it. In this article, we’ll give you the most updated information on PipeWire’s merits versus PulseAudio and show you how to install it properly in your system should you choose to do so.

What Is PipeWire?

Audio on Linux has always followed a layered structure: You install a driver, it makes the device work, but applications still want to talk to it in their own ways. For this, a server acts as an intermediary in the user space to “talk” to the kernel, which then talks to the computer’s hardware.

Pipewire Control

The Advanced Linux Sound Architecture (ALSA) serves as a good, simple intermediary between your applications and your kernel, but if you want more sophistication, you need something called an audio server.

Pipewire Alsamixer

Both PulseAudio and PipeWire add a layer on top of what your kernel does to introduce a number of features. They allow multiple applications to stream audio, provide detailed mixer control capabilities, and even allow for the post-processing of audio streams on the fly in ways that rival or even surpass the capabilities of the suite of applications that commercial operating systems will provide.

The difference between the two is that PipeWire’s layer adds other features like managing video streaming while also getting rid of some of the issues that made PulseAudio unpleasant for newer users to work with.

Since its introduction in 2017, PipeWire’s stability issues have steadily disappeared. It is now a default sound server for various distros including Fedora, Arch-based Manjaro, EndeavourOS, Garuda, and even saw introduction into Ubuntu 22.10.

Pipewire Eq

For most people, the change was so seamless that they have only felt it as their capability to use audio expanded on their systems, which is a testament to its established reputation as a powerful service that serves as a direct upgrade to the aging PulseAudio framework.

Although it’s easy to think that upgrading to PipeWire is a no-brainer, we should step back for a second and explore the nuance behind the decision so you can get a clearer picture of what you’re signing up for if you take that step:

Pros

  • PipeWire contains an enormous range of support for various Bluetooth audio devices that previously didn’t fully work under PulseAudio. If your Bluetooth hardware isn’t working properly with your distro, making the move might help.
  • A good number of distros have already begun including PipeWire as a default audio service, enjoying a great amount of support in the official repositories of basically anything you’d encounter.
  • PipeWire handles latency far more efficiently when streaming audio to multiple devices at the same time.
  • Post-processors like EasyEffects (previously PulseEffects) have dropped support for PulseAudio in their releases or plan to do so soon, making it necessary to move to PipeWire to keep the flexibility that those applications offer you.
  • The features are more friendly to people who want to get into more professional audio setups and applications.
  • It supports pipelining for video streams, letting screen-sharing applications enjoy a more robust and secure environment.
  • PipeWire’s service suite comes with pipewire-pulse, extending support for applications that use PulseAudio’s API and audio management.
  • It’s less prone to crackling under high CPU load.

Cons

  • Configurations don’t always translate directly over from PulseAudio. You’ll have to learn a completely new configuration scheme.
  • PipeWire doesn’t have any intuitive connection logic, which means that it requires another service that will listen for audio output and route them properly. This isn’t necessarily a disadvantage but could be annoying because it requires that you also learn how to configure the session manager to do advanced tuning.
  • Although this is changing as this article is being written, documentation and support from communities is still not as widespread for PipeWire as it is for PulseAudio.

Tip: Find out how you can cast audio to another device with PulseAudio.

How to Install PipeWire

If you want to take the plunge and install PipeWire on your system, you first have to make sure you’re not already running it!

Type pactl info into a terminal and see what it gives you under “Server Name.” If it gives you “on PipeWire” in parentheses, you’re already running PipeWire.

Pipewire Servercheck

If the terminal only shows you “PulseAudio” without anything following it, your system isn’t running PipeWire.

1. Back up Your System

Pipewire Backup

Make sure you have a way back if something goes wrong! If you haven’t created a backup of your system, do so now before going any further. The easiest way to do this is to use Timeshift, but you’re free to use any other utility you’re familiar with that creates a full backup of your system files.

2. Installing The Service

Every PipeWire installation starts with the base service. There’s a chance this may have already been installed with your distro, but just in case it isn’t, you can install it with the following commands.

On Arch-based systems:

sudo pacman -S pipewire pipewire-alsa

On Ubuntu/Debian-based systems:

sudo apt install pipewire

Good to know: Learn all you need to know about the APT commands.

3. Installing The Session Manager

PipeWire doesn’t have its own connection logic, so you have to install a session manager. WirePlumber is one that offers more granular configuration as well as extra plugins that can enhance your experience:

On Arch-based systems:

sudo pacman -S wireplumber

On Ubuntu/Debian-based systems:

sudo apt install wireplumber

If you prefer a simpler version or your distro’s official repositories don’t have WirePlumber, you can simply install PipeWire Media Session:

On Arch-based systems:

sudo pacman -S pipewire-media-session

On Ubuntu/Debian-based systems:

sudo apt install pipewire-media-session

4. Installing The PulseAudio Daemon

Since a large proportion of your system’s applications still send out calls to PulseAudio, if you want your audio to work properly, you’ll have to install PipeWire’s daemon that listens for PulseAudio stuff.

On Arch-based systems:

sudo pacman -S pipewire-pulse

On Ubuntu/Debian-based systems:

sudo apt install pipewire-pulse

5. Removing Traces of PulseAudio

If you had to confirm the removal of PulseAudio because of a conflict with something else you were installing during this process (usually pipewire-pulse), then you can skip this step.

Otherwise, it’s important now to remove PulseAudio from your system so that it doesn’t try to query it.

On Arch-based systems:

sudo pacman -Rns pulseaudio

On Ubuntu/Debian-based systems:

sudo apt remove pulseaudio

6. Getting Services Ready

With all the packages you’ve installed and uninstalled, it is time to get PipeWire up and running.

First, remove remnants of pulseaudio’s services:

systemctl --user --now disable pulseaudio.service pulseaudio.socket
systemctl --user mask pulseaudio

Enable PipeWire’s services. If you installed WirePlumber:

systemctl --user --now enable pipewire pipewire-pulse wireplumber

If you installed PipeWire Media Session, use:

systemctl --user --now enable pipewire pipewire-pulse pipewire-media-session

PipeWire should now work perfectly after you reboot your system!

Tip: If you are having a no sound issue in your Linux system, here is how you can fix it.

Frequently Asked Questions

Can I just use ALSA?

You can definitely get away with just running ALSA on your system (especially if you use a window manager instead of a desktop environment), but you probably won’t enjoy it. ALSA can only play one stream of audio at a time. While this doesn’t sound bad, this means that your system might behave unpredictably when a notification sound tries to play while you’re watching a video. Using a sound server on top of ALSA is more convenient, but definitely involves a small bit of memory overhead.

Can PipeWire be installed in Linux Mint Cinnamon?

Absolutely! Cinnamon has a bit of a scary moment where it doesn’t show you the audio widget when you complete a proper PipeWire installation, but it will reappear the moment you restart if you followed these instructions to the letter. Just make sure you remove remnants of PulseAudio like we outlined in the instructions and you’ll be golden!

How do I solve audio problems after sleep?

If your computer’s audio stops working when you wake it up from sleep, it’s likely because ALSA failed to initialize properly, which will occasionally happen. For situations like these, just manually give ALSA a kick with: alsactl init

Once that’s done, all your audio woes should disappear!

Image credit: pxhere

Is this post useful?
Subscribe to our newsletter!

Our latest tutorials delivered straight to your inbox

Miguel Leiva-Gomez
Miguel Leiva-Gomez - Staff Writer

Miguel has been a business growth and technology expert for more than a decade and has written software for even longer. From his little castle in Romania, he presents cold and analytical perspectives to things that affect the tech world.