The easiest way to control a Linux computer remotely is via SSH. However, this approach does not work if the remote computer has a desktop environment and a GUI must be operated from the remote location. Under Windows, the Remote Desktop Protocol (RDP) is often used, but other protocols such as Virtual Network Computing (VNC) also exist. The advantage of RDP over others is that for most operating systems the remote desktop client is already installed like RDP under Windows or Remmina under Ubuntu. Unfortunately, I was not able to successfully install the xserver on my host system by following the installation steps found online. After entering the username and password in the Xorg session, a black screen appeared. This article briefly describes the installation of xrdp under Xubuntu 18.04 with the Xfce desktop environment.
Installing xrdp (the successfull way)
First, the Xorg X server core package is installed on the host computer that we want to access remotely. We can do so by typing the following commands in the terminal.
sudo apt-get update sudo apt-get install xserver-xorg-core
As we can see in the output of this command, it removes the package
xserver-xorg-hwe-18.04. This package is necessary to locally work with the mouse and keyboard. For the moment we accept and continue.
We then reinstall the previous uninstalled package with the follwoing command.
sudo apt-get -y install xserver-xorg-input-all
Finally, we can install the actual xrdp package. As the output shows, no dependency is missing.
sudo apt-get install xrdp
We can check if the xrdp service is running with the following command.
sudo systemctl status xrdp
Connecting to the Remote Computer
Now we can connect to the remote Linux host with any default installed RDP client.
On Windows we use the standard RDP program to connect to the Xubuntu host computer.
On Ubuntu we use Remmina to connect to the Xubuntu host computer.
With the steps described in this post, xrdp can be successfully installed on a Linux computer and accessed remotely via appropriate RDP clients. This enables the interaction with GUIs installed on the remote system. In addition, the RDP protocol allows a convenient operation even over slower connections, such as access via a hotspot and VPN.