Transform your Linux desktop into a professional multi-output audio setup in seconds!
Play the same audio through multiple devices simultaneously – perfect for streaming, presentations, multi-speaker systems, or sending sound to both headphones and HDMI outputs at once.
This isn't just another audio script – it's your personal audio engineer that creates rock-solid, persistent multi-output configurations across any modern Linux distribution. Whether you're running Arch, Fedora, Ubuntu, or Alpine, this script delivers a perfectly configured dual audio setup.
- 🎯 Universal Linux Support: Works on 10+ Linux distributions and families
- 🔄 Persistent Configuration: Survives reboots with automatic recovery
- 🛠️ Interactive Selection: Choose exactly which devices to combine
- 📊 Smart Monitoring: Auto-detects and recovers from device changes
- ⚡ Zero Hassle: Safe backups, colorful logging, and error recovery
- 🔧 SystemD Integration: Optional auto-start monitoring service
# Download the script
curl -O https://raw.githubusercontent.com/xi-Rick/dualaudio/main/dualaudio.sh
chmod +x dualaudio.sh
# Run with defaults (recommended)
./dualaudio.sh
That's it! Your multi-output audio is configured and ready to use.
Plus any distribution with PipeWire or PulseAudio (pactl-compatible)
# Quick setup with defaults (recommended for first-time setup)
./dualaudio.sh
# Interactive mode
./dualaudio.sh --interactive
# Custom sink name
./dualaudio.sh --sink-name MyAudioMix
# Test your audio after setup
./dualaudio.sh --interactive --test-audio
# Enable volume normalization
./dualaudio.sh --volume-normalize# Monitor device changes in real-time
./dualaudio.sh --monitor
# Install as a systemd user service
./dualaudio.sh --install-service
# Reset everything and restore defaults
./dualaudio.sh --reset
# Check for script updates
./dualaudio.sh --check-updates
# Custom config directory
./dualaudio.sh --config-dir ~/.config/custom-audio| Option | Description |
|---|---|
--interactive |
Choose specific sinks to combine |
--sink-name NAME |
Custom name for combined sink (default: DualAudio) |
--config-dir DIR |
Custom config directory |
--monitor |
Monitor and auto-recover device changes |
--install-service |
Install systemd monitoring service |
--reset |
Remove combined sink and restore defaults |
--test-audio |
Play test sound after setup |
--volume-normalize |
Enable volume normalization |
--check-updates |
Check for script updates |
--help |
Show help information |
--version |
Show version information |
./dualaudio.sh --interactive --volume-normalize
# Select: Headphones + Virtual Audio Cable for OBSPerfect for streamers who need to monitor audio while capturing to streaming software.
./dualaudio.sh --interactive
# Select: Laptop Speakers + HDMI ProjectorPresent with confidence – audio plays through both your laptop and the projector.
./dualaudio.sh --interactive --test-audio
# Select: USB DAC + Bluetooth SpeakersCreate a surround-sound-like experience with multiple speaker systems.
./dualaudio.sh --interactive --monitor --install-service
# Select: Gaming Headset + Virtual Audio for RecordingGame with high-quality audio while recording to a separate device.
DualAudio leverages the power of PipeWire's (or PulseAudio's) module-combine-sink to create a virtual audio device that mirrors output to multiple physical devices.
┌─────────────────┐
│ Audio Source │
│ (Music, Games) │
└────────┬────────┘
│
▼
┌─────────────────┐
│ DualAudio Sink │
│ (Virtual Dev) │
└────┬────────┬───┘
│ │
▼ ▼
┌─────────┐ ┌──────────┐
│Headphone│ │ HDMI │
│ │ │ Output │
└─────────┘ └──────────┘
Key behaviors:
- Creates a persistent combined sink configuration
- Sets the combined sink as your default audio output
- Monitors device changes and auto-recreates if needed
- Works with both PipeWire and PulseAudio backends
- Safely backs up existing configurations
- PipeWire (preferred) or PulseAudio (with pactl)
pactlcommand (from pipewire-pulse or pulseaudio-utils)systemctl(for service management, optional)
jq- For robust JSON parsingcurl- For update checkingpaplay/aplay/speaker-test- For audio testing
🔷 Arch / Manjaro / EndeavourOS / CachyOS
sudo pacman -S pipewire pipewire-pulse wireplumber pulseaudio-utils pavucontrol jq🔷 Fedora / RHEL / CentOS / AlmaLinux / Rocky
sudo dnf install pipewire pipewire-pulse wireplumber pulseaudio-utils pavucontrol jq🔷 Debian / Ubuntu / Pop!_OS / Linux Mint
sudo apt update
sudo apt install pipewire pipewire-pulse wireplumber pulseaudio-utils pavucontrol jq🔷 openSUSE / SLES
sudo zypper install pipewire pipewire-pulse wireplumber pulseaudio-utils pavucontrol jq🔷 Alpine Linux
sudo apk add pipewire pipewire-pulse wireplumber alsa-utils pulseaudio-utils pavucontrol jq🔷 Gentoo
sudo emerge --ask media-video/pipewire media-sound/pulseaudio pulseaudio-utils pavucontrol app-arch/jqContributions are welcome! Here's how you can help:
- r/linuxaudio - Reddit community
- Linux Audio Users - Mailing list
- PipeWire IRC - #pipewire on OFTC
- EasyEffects - Audio effects for PipeWire
- Helvum - PipeWire patchbay
- qpwgraph - PipeWire graph manager
This project is open source and available under the MIT License.
If DualAudio helped you create the perfect multi-output audio setup:
- ⭐ Star this repository
- 🐛 Report bugs and suggest features
- 🔀 Fork and contribute improvements
- 📣 Share with the Linux audio community
🎧 Ready to Experience Multi-Output Audio Paradise? 🎧
curl -O https://raw.githubusercontent.com/xi-Rick/dualaudio/main/dualaudio.sh
chmod +x dualaudio.sh
./dualaudio.shTransform your Linux audio setup today!
Made with 🎵 for the Linux audio community
