The following tutorial will explain how to setup client/server remote desktop sharing on Ubuntu 18.04 Bionic Beaver.
Operating System and Software Versions
- Operating System: – Ubuntu 18.04 Bionic Beaver
Privileged access to your Ubuntu System as root or via
sudo command is required.
- # – requires given linux commands to be executed with root privileges either directly as a root user or by use of
- $ – requires given linux commands to be executed as a regular non-privileged user
Other Versions of this Tutorial
Enable Remote Desktop Sharing
To begin, we first need to make sure that remote desktop sharing is installed on the target Ubuntu system:
$ sudo apt update && sudo apt install -y vino
Next, step is to enable remote sharing:
Once the Ubuntu’s remote desktop feature is enabled you can optionally confirm that your system is now listening on the port
Open up terminal and enter:
$ ss -lnt State Recv-Q Send-Q Local Address:Port Peer Address:Port LISTEN 0 128 0.0.0.0:22 0.0.0.0:* LISTEN 0 5 127.0.0.1:631 0.0.0.0:* LISTEN 0 128 127.0.0.1:6010 0.0.0.0:* LISTEN 0 128 0.0.0.0:38299 0.0.0.0:* LISTEN 0 5 0.0.0.0:5900 0.0.0.0:* LISTEN 0 128 [::]:22 [::]:* LISTEN 0 5 [::1]:631 [::]:* LISTEN 0 128 [::1]:6010 [::]:* LISTEN 0 128 [::]:39717 [::]:* LISTEN 0 5 [::]:5900 [::]:*
In case you have the UFW firewall enabled, open the port
5900 for incoming connections:
$ sudo ufw allow from any to any port 5900 proto tcp Rule added Rule added (v6)
If you wish to make your firewall rules more strict visit our How to Open/Allow incoming firewall port guide for more information.
Establish Remote Desktop Connection
At this stage we are ready to turn our attention to a client system from which we will be establishing connection to a remote Ubuntu desktop.
Remina Desktop Client
The first remote desktop client we are going to use to create a remote desktop connection is Remmina.
Remmina remote desktop client should already be installed on your Ubuntu 18.04 system. In case you need to install it execute:
$ sudo apt install remmina
activities menu to search and start the Remmina remote desktop client or run the command:
VNC Remote Desktop Client
Yet, another alternative to connect to a Ubuntu remote desktop sharing is by use of VNC client. First, install VNC on your client Ubuntu system:
$ sudo apt install tigervnc-viewer
Unlike the above Remina remote client the VNC client does not support encryption. Any attempt to connect to a Remote desktop sharing server will result in
No matching security types error.
From this reason we first need to disable encryption on remote Vino desktop sharing server. Execute the following linux command to disable the remote server to require an encryption for connecting VNC clients:
$ gsettings set org.gnome.Vino require-encryption false
Confirm that the encryption on your remote server is disabled:
$ gsettings list-recursively org.gnome.Vino | grep encrypt org.gnome.Vino require-encryption false
Given that the encryption is now disabled, to add some level of privacy you may optionally first create SSH tunnel to your remote desktop for your VNC client on port
5900 before making VNC connection.
We should now be able to connect to a remote desktop using
$ vncviewer ubuntu-remote-desktop