Linux VPS Guide to Remote Ubuntu Desktop & VNC: Easy Instructions

These are easy step-by-step instructions on running the graphical GUI of Ubuntu Desktop remotely on a Virtual Private Server (VPS); connected with VNC.

This guide was made for 16.04 version of Ubuntu Desktop; also beneficial for users of other versions but some steps may differ. No prior Linux experience required!

Linux Ubuntu VPS

Included are the complete steps to:

Note: This post is part of the HitLeap Linux Guide (The leading website traffic exchange program) with some notes included. You can safely ignore them.

Deploying Linux Server (Ubuntu VPS)

For this Linux VPS Guide I’ve selected VPSServer Hosting because of their:

  • fast SSD storage & unique IP addresses;
  • multiple VPS locations around the world;
  • more resources than it’s competitors for the same low price;
  • 14-day free trial.

So let’s get right to it!

Linux Ubuntu VPS: Step 1

First; click here to register yourself an account.

Linux Ubuntu VPS: Step 2

Proceed to the Dashboard and Add Server from the list of locations.

Available servers are: Miami (US), London (UK), New York (US), Frankfurt (Germany), Amsterdam (Holland), Chicago (US), Dallas (US), Silicon Valley (US).

Linux Ubuntu VPS: Step 3

Select (1) Ubuntu OS (2) the version number with 16.04 being the latest (3) choose between 64bit or 32bit architecture (x86 is 32-bit and x64 is 64-bit).

Alternatively available operating systems are: Centos, Fedora, Debian, OpenSuse, Windows, Centoo, ArchLinux, ScientificLinux, ClearOS, Mageia, CloudLinux, OpenFiler & Forex — however in this guide I will focus on Ubuntu.

Hitleap note: You will need a 64bit system & 16.04 recommended!

Linux Ubuntu VPS: Step 4

Then select the size of the VPS you want to start with (can be upgraded later).

Linux Ubuntu VPS: Step 5

Make sure all selections are correct and proceed to create server. Set Server Hostname as anything; you will be using your unique IP address to connect to the VPS.

Linux Ubuntu VPS: Step 6

To complete the deployment; all that’s needed is a $0.01 charge that will be made from your credit card to start the 14-day fee trial.

Linux Ubuntu VPS: Step 7

Please, wait for a moment for the server to become available and select Manage.

Installing Desktop Interface & VNC Server

These are all the most basic steps needed to get Ubuntu up and running.

Linux Ubuntu VPS: Step 8

The manage window panel looks like this with all the necessary information about the server. We need to go to the Linux command line to set up everything.

Please, select the Console icon.

Linux Ubuntu VPS: Step 10

Prompted with a login — see the top of window for your login & password.

Now you are inside the system. First type in the following command to fetch and install all the necessary packages for the graphical desktop environment & remote VNC server.

apt-get -y update; apt-get -y install ubuntu-desktop x11vnc

Note! If you see a blank window, it’s in screen saver mode — just hit any key to view the screen. Also during the installation the screen can go black if left unattended.

Linux Ubuntu VPS: Step 11

You will need to create a separate user account for the desktop. For this use the following command, enter a password & keep pressing the enter key until finished.

adduser user

Note: you can give any username instead of [user]

Linux Ubuntu VPS: Step 12

Not mandatory but recommended step is to create a swap file which will make Ubuntu faster; especially if you have selected a package with little RAM memory.

fallocate -l 1G /swapfile; chmod 600 /swapfile; mkswap /swapfile; swapon /swapfile

You will then need to make this permanent so it’s active after a reboot.

echo '/swapfile none swap sw 0 0' | sudo tee -a /etc/fstab

Linux Ubuntu VPS: Step 13

The last step is to set up the VNC server so that it automatically starts on every boot and enable it. So that you can remotely connect to the VPS.

First create a password for the remote server connection:

x11vnc -storepasswd

Then you will need a x11vnc.service file in /lib/systemd/system directory; I’m providing a ready configured file for easy install (you can see it here).

cd /lib/systemd/system; wget www.webhostwhat.com/archive/x11vnc.service

Finally just enable the service:

systemctl enable x11vnc.service

Last but not least; press the Ctrl+Alt+Del button at the top to reboot (or alternatively just type in the command ‘reboot’).

Connecting to Desktop on Mac OS

Now all you need to do is connect. For windows instructions; see below.

Connect Linux VPS with VNC: Mac OS Step 01

Search for and open the ready installed Screen Sharing app.

Connect Linux VPS with VNC: Mac OS Step 02

Enter the server IP address to connect to; and the password you set for the VNC server in a previous step.

Connecting to Desktop on Windows

Windows has no built-in VNC software; the most popular free, light-weight client that I’ve used is TightVNC — see website for installation files.

Connect Linux VPS with VNC: Windows Step 01

When installing; make sure to include only the TightVNC Viewer in the custom setup if you are only planning to connect to the Linux VPS from your computer.

Connect Linux VPS with VNC: Windows Step 02

Add the Server IP address as Remote Host and enter the VNC password you set in the previous steps above.

Ubuntu VNC User Login Screen

The GUI version of the Ubuntu Desktop login prompt will look like this.

Ubuntu Desktop on VNC

And there we have a fully working; operational remote Linux VPS!

Troubleshooting

In this part I will add solution to some of the common problems of running Linux operating systems in a desktop VPS environment. Questions welcome!

If you find yourself in trouble that you cannot get out from. Simply go to the server dashboard and select Reboot. If you followed all the steps above correctly; the system will fully restore itself after the boot.

Click here to find out more about VPSServer Hosting.

VPSServer offers hosting for these Ubuntu distributions: 16.04 x86, 16.04 x64, 15.04 x64, 14.10 x86, 14.10 x64, 14.04 x86, 14.04 x64, 13.10 x86, 13.10 x64, 13.04 x64, 12.10 x86 & 12.10 x64 — starting from 5/month for 768MB of memory, 2 CPUs, 50GB SSD disk storage, 1TB traffic and 24 hour live chat support. Server locations are 8 in total, 5 in North America and 3 in Europe (Netherlands, Germany, United Kingdom).

 

Any questions, suggestions, comments? Please, go ahead! Thanks!

Monetary notice: Certain links on this page may track sales with cookies made on third-party websites. This does not influence my opinion on the associated companies, or the (already low) cost of service. Huge thanks for your kind support.

Twitter Button Facebook Button Google Button LinkedIn Button

Leave a Reply

Your email address will not be published. Required fields are marked *