XRDP Sound Redirection Error in Ubuntu 20.04 VirtualBox Virtual Machine
When installing an Ubuntu 20.04 operating system on a Hyper-V virtual machine and trying to run the command ./xrdp-installer-1.5.2.sh to enable sound redirection, you might encounter an error that states "Skipping unpack". This article aims to provide a detailed explanation of the issue and offer solutions for fixing it.
Understanding XRDP and Sound Redirection
XRDP is an open-source implementation of Microsoft's Remote Desktop Protocol (RDP) that allows users to remotely connect to a Linux system from a Windows or Mac computer. Sound redirection is a feature that enables users to redirect audio from their remote session to their local machine.
Problem: XRDP Sound Redirection Error
When attempting to enable sound redirection in an Ubuntu 20.04 virtual machine using Hyper-V, you might encounter the following error:
Skipping unpack of xrdp-pulseaudio-1.5.2.tar.xz due to error during build: fakechroot build of xrdp-pulseaudio-1.5.2 failed
This error is related to the fact that the sound redirection script is based on an older version of XRDP that doesn't work well with newer versions of Ubuntu. In addition, the use of fakechroot during the build process can cause issues with the installation of dependencies, resulting in the error described above.
Solutions
There are two possible solutions to this issue:
- Manual Installation of XRDP and Sound Redirection: This solution involves manually installing XRDP and sound redirection by following the steps below:
- Update your Ubuntu system using the command
sudo apt update && sudo apt upgrade. - Install XRDP and PulseAudio by running the command
sudo apt install xrdp pulseaudio. - Create a new user account for XRDP using the command
sudo adduser xrdpuser. - Switch to the new user account by running the command
su - xrdpuser. - Create a .xrdp file in the new user's home directory by running the command
nano .xrdpand adding the following lines:
session=startwmx
startup-script=/home/xrdpuser/startup.sh
- Create a startup script for XRDP by running the command
nano startup.shand adding the following lines:
#!/bin/bash
pulseaudio --start
- Make the startup script executable by running the command
chmod +x startup.sh. - Restart XRDP by running the command
sudo service xrdp restart. - Connect to your XRDP session from your local machine using the Remote Desktop Protocol.
- Use an Alternative Remote Desktop Protocol: If the manual installation process fails, you can try using an alternative remote desktop protocol that supports sound redirection. Some popular options include VNC and NX.
References
- xrdp-pulseaudio on GitHub
- XRDP Official Website
- VirtualBox Official Website
- Ubuntu Official Website
- Remote Desktop Clients Comparison
By following the solutions outlined in this article, you should be able to fix the XRDP sound redirection error in Ubuntu 20.04 and enjoy a seamless remote desktop experience with sound support.