PowerADM.com / Linux / Ubuntu / Installing xRDP (Remote Desktop) on Ubuntu Server
We’ll take a look at how to enable Remote Desktop access to Ubuntu Server using xRDP.
XRDP allows you to remotely connect to the graphical desktop of computers using the Microsoft Remote Desktop Protocol (RDP). XRDP accepts connections from various RDP clients: FreeRDP, RDesktop, NeutrinoRDP, and Microsoft Remote Desktop Client (for Windows, macOS, iOS, and Android).
Typically, Linux servers don’t have a graphical desktop interface. Therefore, you first need to install X11 and a lightweight desktop environment that will act as the engine for xRDP.
There are several desktop environments in the Ubuntu repository. In our case, we will be using Xfce. It is a fast, stable, and lightweight desktop environment for Linux.
Update packages to the latest version:
sudo apt update && apt -y dist-upgrade
Install Xfce:
$ sudo apt -y install xfce4 xfce4-goodies xorg dbus-x11 x11-xserver-utils
Install xRDP:
$ sudo apt -y install xrdp
Check that the xRDP daemon is installed and running:
run xrdp on ubuntu server$ sudo systemctl status xrdp
Add your user to the SSL-CERT group:
$ sudo adduser xrdp ssl-cert
By default, xRDP uses the /etc/ssl/private/ssl-cert-snakeoil.key file, which is readable only by members of the SSL-CERT group.
The xRDP settings are specified in the xrdp.ini configuration file:
$ sudo nano /etc/xrdp/xrdp.ini
Add the following line to the end of the file:
exec startxfce4
And restart XRDP:
$ sudo systemctl restart xrdp
Remember to open port 3389 in the Linux firewall. The following command allows RDP connections to the server from the specified network:
$ sudo ufw allow from 192.168.1.0/24 to any port 3389
Remote Desktop -- blue screen after login
You can check version of Ubuntu by running following command.
$ lib_release -sd
If your running Ubuntu 18.04.3, there is a known issue with Xrdp package provided by Canonical. The Xrdp package cannot install xorgxrdp package because of failed dependencies. That is why you cannot connect remotely to your Ubuntu.
Best option - Install the new xorgxrdp-hwe-18.04 package by issuing the following command.
$ sudo apt-get install xorgxrdp-hwe-18.04
This should fix your issue.
Also, you can use VNC to connect to your Ubuntu desktop.
No comments:
Post a Comment