How to install XRDP on Ubuntu 22.04 or 20.04

In this tutorial, we are going tho show you how to install XRDP on Ubuntu 22.04 or 20.04 server and how to start using it.

XRDP is a free and open source remote desktop protocol server that essentially allows you to connect remotely to your VPS and use its graphical interface.

After XRDP server is configured you will be able to connect to your VPS using RDP(Remote desktop protocol) and experience your VPS in totally different way. It would be like connecting to another computer and using it just like you would use your laptop.

You can browse, you can download things, open files and edit them, watch YouTube… All that thanks to the power of remote desktop protocol technology.

In this guide, we will show you how to install XFCE, which is desktop environment that is very lightweight and efficient and we really recommend it for the best VPS experience.

You can feel free to dig more and install alternative desktop environment, but do keep in mind that most of them are way more resource hungry than XFCE is.

Step 1 – Install XFCE

To get started, lets first run some updates.

sudo apt update

And now, let’s install XFCE on your Ubuntu 22.04 or 20.04 VPS.

sudo apt install xfce4 xfce4-goodies -y

It will take few minutes. In the mean time, feel free to take a look at your Linux VPS offer and if you like it, use SL50OFF code to get your VPS with 50% discount for the first month.

Step 2 – Install XRDP on Ubuntu 22.04 or 20.04

Run the following command.

sudo apt install xrdp -y

XRDP should be running now, but let’s make sure of that.

sudo service xrdp start

And then lets enable it so it would start at the boot.

sudo service enable xrdp

If you are using our Linux VPS, this step is not requirement since XFCE would be the only desktop environment on the server, but in any case it won’t hurt.

It’s basically telling XRDP what desktop environment to use.

echo xfce4-session >~/.xsession

And finally, lets restart the service.

sudo service xrdp restart

Step 3 – Test the connection with your XRDP server

We are using KRDC, which is free remote desktop client.

You can use any RDP client, including Remote Desktop Connection that you get with Windows.

Enter your server IP, username and password and boom, you should be in. It would look something like this.

Note: Username and password are the same as the ones you are using to connect to your server with SSH

how to install xrdp on ubuntu 22.04 or 20.04 XFCE login

But wait, why can’t I open a browser?

By default, your VPS won’t have any browsers installed on it.

So let’s fix that and install Firefox. By the way, you can run this in the graphical interface, hit that terminal icon and type this.

sudo apt install firefox

And now, that browser icon should work. Firefox will be added to your menu as well.

how to install xrdp on ubuntu - firefox install

Looks like its working. Excellent!

And there you have it

All other accounts that you have on your server should be able to use Remote Desktop now and they will all have their own separate sessions.

In this tutorial, you have learned how to install XRDP on Ubuntu 22.04 or 20.04 and how to properly set up XFCE desktop environment. It was easier than you thought, right?

Have fun with your new computer!

Similar Posts