If you run linux desktops (virtual, containerized, physical… or other?) then you may have come across the term VNC which is shorthand for “Virtual Network Computing” which is so ambiguous it means practically nothing. If you come from the windows world you are probably familiar with the term RDP which is shorthand for “Remote Desktop Protocol” which is vastly more descriptive.

VNC and RDP are both technologies used for used for interacting with an operating system from a distance, over the network, typically with the GUI. If you just need CLI access then most (all?) versions of Linux support SSH (secure shell) and Microsoft has remote powershell. But hitting up a GUI from afar is a more difficult affair, particularly on Linux.

In the monolithic world of Microsoft, RDP is dead simple and I will applaud Microsoft on a phenomenal application that has evolved well over the years, is simple, and honestly works fantastically well.

In the not-at-all monolithic world of linux however we are left with VNC… and there are many many VNC clients, most of which don’t work well in my experience and none-of-which are nearly as efficient as RDP… which means slow network links (like connecting to systems on the other side of the world) are a killer.

In my search for a good VNC server/client combo I finally stumbled across TigerVNC. I am delighted to say that it is stupid-simple to use and while perhaps not as fast as RDP, it does seem to perform better than the bulk of other VNC options out there.

So how do we get it setup and running?

First, I am writing this article and assuming you are running some form of Ubuntu. Personally, for desktop systems, I like running Ubuntu Server (it is much lighter-weight than the desktop distros) with the extremely small footprint XFCE desktop installed. I find that Unity and whatever bastardized gnome variant Canonical has recently moved to don’t tend to perform well over any VNC stack… too much pretty graphical flare I suspect. If you are running Ubuntu server 16.04 and want to install XFCE, you can do so with the following command:

sudo apt-get install xubuntu-desktop

BTW – if you don’t need a GUI, I recommend you just not read this article and don’t install one. But for the odd use-case where a GUI is desired and remote administration is needed… read on.

You may want a few more tools if you are following along so I would also install:

sudo apt-get install vim

Next, we need to install the TigerVNC server software package. Which isn’t part of the main Ubuntu repositories.. So you will need to get the .deb package and manually install…

The current “as of this article” latest 64-bit deb package installer can be downloaded via:

wget https://bintray.com/tigervnc/stable/download_file?file_path=ubuntu-16.04LTS%2Famd64%2Ftigervncserver_1.8.0-1ubuntu1_amd64.deb -O tigerVNC.deb

—-
You can check what the latest version available is on bintray.com here: https://bintray.com/tigervnc/stable/tigervnc/
—-

Then you can use dpkg to install it and apt-get to additionally install any missing dependencies:

sudo dpkg -i tigerVNC.deb
sudo apt-get install -f

Finally you start the VNC server with this command:

vncserver

When you first start the service you will be asked to create a session password which you will need to supply every time you connect.

Now the client software…
I love linux, but Windows is my daily driver. This is one of the reasons I love TigerVNC. They have a ridiculously easy and light-weight client package for Windows that you don’t even have to install, just download and run the executable.

You can get the vncviewer-1.8.0.exe program from bintray here:
https://bintray.com/tigervnc/stable/tigervnc/1.8.0

Download that and put in on your desktop, double-click it and you will be presented with an entry line and a connect button. The default port for the first VNC session connection is 5901. So lets say I have a server at the address of mycoolserver.example.net. I would punch in:

mycoolserver.example.net:5901

You will then be prompted to enter the password you set the first time you ran the vncserver command on your system. Put that in and like magic… there is your desktop.

I will also note that unlike many other VNC applications/servers, TigerVNC connections are encrypted by default.

Reference:
https://www.stoutpanda.com/2016/10/20/tigervnc-ubuntu-1604-xenial-xerus/

Because I am getting old and can’t remember anything, I will note that I wrote a slightly more involved article on this exact same topic here:
https://www.kiloroot.com/proxmox-ubuntu-server-14-04-tigervnc-how-to-remote-desktop-into-a-linux-container/

1 of 1

This post has no comments. Be the first to leave one!

Leave a Reply