1and1 – VPS Odessey
Well, I just burned a day getting my virtual private server up and running. Like a bone-head I was determined to stick with something I knew, but I couldn’t.
I got an Ubuntu server up and running on my Mac using VMWare Fusion. I really like Hardy Haron (especially with Komodo Edit and Rapid-SVN) but 1 and 1 doesn’t support Ubuntu Server. Just Debian. They’re similar, but I figured I’d go with SUSE.
No Joy for SUSE Linux Enterprise Server
I have this burning desire to be able to run the same virtual machine (mostly) on my Mac with VMWare Fusion that I’m running on 1 and 1. I really want to be able to test stuff locally then upload it and make sure it works as expected. I was very impressed with SLES 10 so I figured I would try it on 1 and 1. It’s not one of their recommended servers but it is on the list. What a mistake that was. I just couldn’t get anything to connect to it. Not NoMachines, FreeNX, not VNC. Nothing. No matter what I tried I couldn’t get a GUI running remotely on 1and1. Why was I trying to do this? Becaus the command line YAST2 didn’t work. I couldn’t add users. I couldn’t upgrade software. Nothing. And I needed a more advanced version of PHP to run the latest version of Drupal. Arg. So now what?
No Plesk for me.
After nearly 6 hours, I gave up and went back to CentOS 5. I wasn’t really thrilled about that, but it was the recommended OS. So I fired it up. I probably could have saved myself a lot of heart burn by learning Plesk – Except, I really didn’t want to try and run plesk on my local machine. I just wanted a very simple server. One name, one website. That’s it. Plesk for me was overkill. What’s more, the garden variety SLES tools were plenty good enough to setup what I wanted to do. I got the SUSE server running on my local machine in 20 minutes. Half a day later I had to abandon my efforts to get it running with my VPS.
CentOS 5… the other OS
So, I re-imaged my server and then went to town. Eschewing PLESK, I logged in via ssh and started installing everything. My journey went something like this:
I installed freenx with:
% yum install freenx
That seemed to work fine, so then I went to NoMachines and downloaded their Mac Client. I was able to connect, but right at the very last step… the whole thing failed. I now think it’s because I didn’t have the gnome desktop installed.
So I went back to VNC, and used similar commands.
% yum install vnc
% yum install vnc-server
I found a really nice writeup on using vnc on Egopoly. The big change is that on CentOS the installed application is called: vncserver.
After installing vnc, I was able to use log into my VPS using FireFox with host.com:5801. The RealVNC logo popped up and I could actually connect. It was pretty cool, but I had a completely empty gray desktop. It was the farthest I’d gotten, but I still couldn’t do anything useful.
So I dug some more. Turns out if vnc shows you “nothing” it’s because it can’t fire up any of the programs in your ~/.vnc/xstartup batch file. vncserver starts up the applications it finds in the batchfile when it runs. So every time you update the file you need to kill the Xvnc client that is running and restart the server.
% killall Xvnc
%vncserver
I had to install xterm:
% yum install xterm
And suddenly when I logged in, I had an xterm on my gray desktop. The next thing I needed was a real gnome desktop. Turns out there is a known bug with CentOS and Gnome and the nautilaus-sendto. If you just do a:
yum groupinstall "Gnome Desktop Environment"
It will fail. I found directions on how to fix it at: bugs.centos.org But I had to find the 64 bit version of the sendto library to work with 1and1. I found that (by poking around) here: mirror.centos.org. If you install that library with the command:
% wget http://mirror.centos.org/centos/5/os/x86_64/CentOS/nautilus-sendto-0.7-5.fc6.x86_64.rpm
% rpm -Uvh --nodeps nautilus-sendto-0.7-5.fc6.x86_64.rpm
You can then install the Gnome Desktop with the groupinstall command successfully. The net result is 154MB of downloads later, I can vnc into my VPS and I see the CentOS5 desktop JUST LIKE my virtual machine. With access to my graphical tools and excellent online support at centos.org I can now get about setting up my server.
With Gnome successfully installed, I can now get to my desktop with NX Client for OSX and it looks great.