Install x2go on Ubuntu Oneiric

This article will take you step by step though installing the x2go server on your Ubuntu Oneiric based machine. The x2go server offers remote desktop access to you machine meaning that you can virtually sit at the machine from anywhere in the world. Unlike some other remote desktop systems x2go uses powerful algorithms to compress the data sent over the wire so it should work reasonably well even over a very slow link.

Firstly I have to admit that I’m actually installing on Kubuntu Oneiric but the process should be the same whether you are using Ubuntu or Kubuntu (and probably Edbuntu as well). There are a number of different remote desktop systems for Linux and choosing between them can be difficult. Probably the most popular is VNC because it’s very simple to set up and clients are readily available and generally stable. I don’t really like VNC though. As far as I know you have to be logged in on the machine physically before you, or someone else, can take over the desktop remotely (at least that was how it worked last time I played with it).

The x2go server offers properly remove login and session detachment and re-attachment in much the same was a Windows Remote Desktop does. I’m a big fan of Windows Remote Desktop, I use it all the time at work to access machines on client sties. If Linux can provide something with that level of functionality I’ll be very happy.

​Install the x2go Packages

The x2go software isn’t currently in the main repository for Oneiric so you’ll need to add a couple of sources to your sources.list file. I’ve described both the automatic method and the much slower manual method, you need to pick just one and I highly recommend the automatic method.

Automatic Method

Open a command prompt and enter

sudo add-apt-repository ppa:x2go/ppa

Press enter when told to do so, job done.

Manual Method

Open a command prompt and enter

sudo emacs /etc/apt/sources.list

Enter your password and add the following two lines to the bottom of the sources file.

deb oneiric main
deb-src oneiric main

These two lines add the package repository that contains the current best x2go packages.

Update the Package List

Once you have saved the file update your package list with:

sudo aptitude update

If you get a security warning you’ll need to add the repository key to your system. This shouldn’t happen if you used the automatic method as it would add the key if required.

​Now all that is left to do is actually install the needed package:

sudo aptitude install x2goserver

There are several other packages that you could install as well but the server is the only one you need to get started.

Install the x2go Client

So far I’ve only played with the Windows client but there are clients available for Windows, Linux and Mac. When you install the Windows client it will also install Ximg, a Windows X client and some SSH libraries from Cygwin.

One the client is install open it up and it will present you with a dialog that lets you set up a session. A session contains the settings for connecting to the remote server and describes what resources will be available such as remote sound. You can also decide the quality level of the connection. On the connection table there is a slider which runs from Dial Up to LAN. If you are on a LAN I recommend telling the client this as it will give you a better looking remote desktop. Likewise I suggest switching from 16m JPEG to one of the PNG compression methods as, again, it will make the desktop look better. The best possible display is nopack but you need to have a really good connection to this to work.

The server part of the set up is very smooth but the client side still needs a little bit of work. I found that I had to have the Ximig server running before I tried to start an x2go session. I realize that the x2go client requires the Ximig server but it would be nice if it could start it automatically if it’s not running.

The other issue I found was tp do with secure connection. The x2go client can use key authentication so you don’t have to enter a password in order to log on. I don’t currently have that set up but that doesn’t stop it from trying to read the file

C:\Program Files (x86)\x2goclient\etc\

every time I make a connection. I wouldn’t mind so much but it pops up a dialog that prevents the connection from proceeding until I dismiss it. I then get another that just claims it can’t read .pub. Oh well, it’s a small price to pay.

I found I could work around the first error message but creating an empty file at the path shown above. That means I only get the second error message about not being able to read .pub. That dialog doesn’t stop the connection and login process so it can be dismissed at my leisure.