brief excursion into server virtualization

Wednesday, April 29th, 2009

Having a few accounts at slicehost has sold me on the potential of server virtualization. Faced with the need to build a new in-house server on some older hardware, I figured it’d be worth taking a look at setting the new server up as a virtual host. Even though I only need one linux server today, it’d be nice to easily migrate  sets of services on/off it in the future, jump onto new hardware without doing a whole reinstall, etc.

I like ubuntu, so that’s where I started looking at for the host OS. Being on the client end of Xen via slicehost has been smooth, but there are also other virtualization options pushed in the Ubuntu docs, including at least VMware and KVM, so I’ve spent a little time looking into them. I’m a bit of a Free Software snob, so VMware was off the list. KVM requires one of a small set of recent processors to run — the CPU of the server in question is on that list, so KVM remained an option.

Due to previous experience, though, I started looking at Xen first, only to find that Ubuntu isn’t and won’t be supporting Xen from the current release onwards. Wondering why that would be, I came to the following debate, and became thoroughly confused.

After getting this far into the process, I revisited my reasons for looking into virtualization in the first place, and came to the conclusion that my relatively simple needs don’t justify the time to wade through the options.

Migrating from mongrel to passenger

Wednesday, December 24th, 2008

In short, I’m happy to report that passenger a.k.a. mod_rails is awesome. I see no need to fiddle with mongrel, mongrel_cluster & mod_proxy for future rails apps.

Miscellaneous notes from the project:

  • My environment is now ubuntu server 8.04, on slicehost. This project finally prompted me to upgrade from 7.10, which went very smootly — the long-term support releases of Ubuntu seem like the way to go for most server situations.
  • How to handle the apache config? We have some php stuff running on this server, too, so the 3rd party ubuntu passenger package, which wants to use the worker mpm, isn’t the hot ticket. No problem, passenger’s default gem-based install is smooth as butter.
    This configuration also seems to require RailsAutoDetect off, which had the side benefit of letting me leave an existing mongrel-using configuration alone until I had a few minutes hours to upgrade it to rails 2.2.2, then switch it over to git & passenger.
  • Slicehost has decent docs for this, in particular ubuntu-hardy-mod_rails-installation and ubuntu-hardy-using-mod_rails-to-serve-your-application & its comments.
  • Capistrano mods for passenger
  • This was also my first git-powered rails app, which proved a little challenging to get going with cap, but has turned out really nicely. Very fast deployments.
    Along the way, having a plugin as a git submodule proved to be more trouble than it was with, though I’m not sure if that’d apply to my final configuration, which involves checking the project out from the same server as it’s deployed on,  using the :local_repository argument to capistrano.
  • This project helped me realize that having a deployed app as a public github project is more trouble than it’s worth, what with the various configuration informations that I’d rather have under SCM but don’t want to share.