Streaming audio across RDP From linux to windows on Ubuntu Studio

I am on the latest version of Ubuntu Studio that is installed on a seperate computer. On another computer is Windows 11 Pro.

I can use RDP from Windows to my linux machine just fine. On my linux machine I installed xRDP.

How do I get audio to work from linux machine to my windows? I just use the native RDP client in windows. I have looked around, and it seems fairly complicated. While I am proficient with computer, I am still learning linux. I am not a pro more like a competent beginner.

Moved to the Support and Help category.

1 Like

What have you tried on your Windows machine? What have you tried on your Linux machine? I ask because Google AI tells me this:

Yes, xrdp allows audio streaming from Linux to Windows by redirecting the sound through the standard Remote Desktop Protocol (RDP) virtual channel. [1]

However, because sound support is not always enabled by default, you may need to install or compile an additional module on the Linux machine to bridge your sound server (such as PulseAudio or PipeWire) with xrdp. [1, 2, 3]

How to set it up:

1. Configure Windows Remote Desktop
When initiating the connection on your Windows machine, ensure you allow remote audio playback: [1, 2]

  • Press Win + R and type mstsc to open Remote Desktop Connection.
  • Click Show Options and navigate to the Local Resources tab.
  • Under the Remote audio section, click Settings…
  • Select Play on this computer and hit OK. [1, 2, 3]

2. Enable Sound Redirection on Linux
Linux distributions use different sound servers, which determines how you enable xrdp audio: [1]

  • For PulseAudio Systems: You may need to compile and install the pulseaudio-module-xrdp package. Many users rely on automated installer scripts (such as the C-nergy xRDP Installer) to automatically configure and build the sound modules.
  • For PipeWire Systems: Many modern Linux distributions use PipeWire by default. You will need to compile the pipewire-module-xrdp package from source. Step-by-step compilation guides for Pipewire integration can be found on C-nergy xRDP Module Guide. [1, 2, 3]

Once the appropriate module is compiled and installed on the Linux server, your sound settings will automatically detect the xrdp-sink and stream the audio back to your Windows speakers,

Have you read the README from here?

Location on github of xdrp

It has a link called: How to setup audio redirection.

Regards

What app are you playing audio using? I suspect there is a sleeker solution here

Thanks everyone for the help. I use Clementine for my music player. I was testing about 15 or different music players for Linux, and wanted to stream the audio. Some music players I have tested in the past, when playing audio, it was staticy and unclear. But the project is now finished. I may set this up later. But for now I do not need it. Thanks again.

You could mount a windows file share using CIFS to a local directory then have the audio application play the files from there. Why would you need RDP for this?

So I installed KRDP and that works allot better than xRDP.

I have looked around, and it does not seem possible to do audio streaming over KRDP. Is that true?

I think that’s not a good use of bandwidth, because, IIUC, Clementine outputs a raw PCM audio stream for your sound card to convert to analog and drive your speakers or headphone. There’s a reason for audio compression like MP3 and it’s precisely so one doesn’t waste bandwidth. Why does it have to be over RDP, anyway? If all you want is to control a live stream through Clementine, let’s see if there isn’t some ICECast plugin for it. The idea is to use ICEcast as an output plugin, which sends a standard web audio stream to the PC over the internet; that should not be transferred in raw form over RDP or whatever. All you need RDP for, is to control Clementine.

But seeing that Clementine doesn’t seem to figure in that table, how about MPD? It can run as a headless service and there are multiple GUI frontend applications to control it, even Web Clients(!) or you could even do that over the network. I have run such a setup in the past; my own web radio, in a manner of speaking.

But why…? You want to stream audio, not the desktop session.

I regularly stream audio over a LAN by using an ssh connection. This works fine with 2 Linux machines (one being the server), but I haven’t tried streaming from Windows to Linux player. You would have to test that.

Note: streaming a playlist of files over ssh does not work if the player is containerized. I use audacious .deb installed from Ubuntu repository, not flatpak or snap.

This topic was automatically closed after 29 days. New replies are no longer allowed.