Ubuntu Desktop in the Cloud
For the past few releases, Canonical has put quite a bit of energy into making Ubuntu a first-class OS for use in the cloud. Ubuntu now has cloud support for Amazon’s EC2 and Ubuntu Enterprise Cloud (a “private cloud” system based on Eucalyptus). This means that it’s easy to spin up Ubuntu instances on EC2 or to make your own private cloud with Ubuntu … where you can spin up more instances of Ubuntu … there’s a lot of “cloud” going on here!
One new feature in Ubuntu 10.04 that caught my attention is the “Desktop in the Cloud” project. Until now, most of the attention on cloud technologies has been focused on servers in the cloud. If you wanted to use a desktop environment on EC2, you needed to do quite a bit of tweaking and installing of packages yourself. With the Lucid release, the Ubuntu team is making desktop in the cloud much easier.
You can now find daily testing images for Ubuntu Lucid desktop in EC2. These images include a full Ubuntu desktop environment as well as Google’s Neatx open source NX server for connecting remotely to the desktop. Here’s what you need to know to get started (note: This is not a full tutorial, and meant for people who already are familiar with EC2 and have their systems configured for working with EC2. Information for setting up EC2 on Ubuntu can be found here. Perhaps I’ll make a full tutorial for beginners after Lucid’s official release).
To find the latest Lucid daily build, simply search for an AMI in the AWS Management Console with the current date, like “20100302.” You should find daily desktop builds for either today’s or yesterday’s date. Make sure to choose the 32-bit version if you want to launch a small instance.
Once you find the AMI, launch it like you normally would. Make sure that port 22 for SSH is open in the security group that you choose. You will connect to this EC2 instance just like to any other instance with only one difference. The official Ubuntu EC2 images do not allow you to connect via SSH as the root user. Instead, you need to connect with your private key as the user “ubuntu”, like this:
ssh -i /path/to/ec2-keypair.pem ubuntu@external-host-name
You should create a new user and give them a password (a password is required by NX). Now you can connect as this new user to your new cloud Desktop instance with NX Client. If you don’t have an NX client, download a free one from NoMachine. Use your NX client to connect to your EC2 instance via its public DNS address on port 22. If all goes well, you should see your newly spawned desktop.
So, we have a desktop in the cloud … but what is it good for?
Right now, it’s a very quick and easy way to test Lucid daily builds. Instead of downloading a new ISO and installing in a virtual machine, you can test on EC2 and save a lot of time. In the future, I can see this being useful for those who would like to have their own personal desktop that’s accessible from anywhere. It might also be useful for organizations who want to provide desktop work environments for employees who work from home.
What ideas do you have for using an Ubuntu desktop in the cloud? Share your ideas in the comments below!