Slicehost and SliceManager 2
Introduction
Slicehost is a virtual private server (VPS or Slice) provider that is built on top of Xen Source. They have built their own management interface for Xen called SliceManager. Slicehost is SysAdmins’ Chronicles hosting provider and has been for the last three months. This article will review SliceManger, SliceHost as a VPS provider, and our overall experiance with them so far.
Cost
The currect costs as of October 29th, 2007 are:
| Plan | RAM | HD | Bandwidth | Monthly Cost |
|---|---|---|---|---|
| 256slice | 256MB | 10GB | 100GB | $20 |
| 512slice | 512MB | 20GB | 200GB | $38 |
| 1024slice | 1024MB | 40GB | 400GB | $70 |
| 2048slice | 2048MB | 80GB | 800GB | $140 |
Source: http://www.slicehost.com
SysAdmins’ Chronicles is currently using the smallest plan, 256slice.
Signing Up / Making a Reservation
Currently Slicehost will let you make a reservation for the next available Slice of the size you want. They prioritize reservations on what prepayment term you commit to. The minimum being 3 months, then 6 months, 12 months, and the maximum term being 24 months. When we made our reservation we committed to a 256slice for a 12 month prepayment term. We had our Slice available within one day (the reservation page gives you an ETA on availability). Your millage will vary based on SliceHost’s current availability of hardware. Oh I should mention that a reservation is not binding, and no payment information is taken at the time of reservation.
The reason Slicehost works on a reservation system is one, they seem to be pretty popular these days, and second they do NOT over-provision their hardware. They are actually are buying new servers each week based on the reservations (there is a chance you will be placed on a vacancy on an existing server if one becomes available).
SliceManager
SliceManager is the client’s interface to the Xen back-end for maintaining their Slice. We will now through all the functions of SliceManger (it appears it was just recently updated this weekend).
First we login at http://manage.slicehost.com.

You be brought to this page once you have successfully logged in. It shows a brief overview of your current Slice(s).

Add a Slice
Under the Slices tab you can add a new Slice if you would like. I not sure if these new Slices fall under the same reservation system as when you are first signing up.
Update: Stubblechin in the comments, confirms that you jump ahead of all reservations when adding a new slice when you are already a customer.

Here are your operating system choices when creating a new Slice, Ubuntu Dapper, CentOS 4.3, Gentoo 2006.1, Debian Etch, Fedora 6. It should be noted that Ubuntu Dapper is easily upgraded to newer versions of Ubuntu via the standard Ubuntu release upgrade methods. Gentoo can be upgraded just as easy with portage.

Not much else compares to being able to add new servers (or any of the other features I’m going to show you) from the web interface with no need to contact customer support. Neat eh?
Slice Detailed
Now for a more detailed view of an individual Slice. Below shows you the first screen you will be presented with once you select a Slice. It included basic stats such as status, age, size (RAM), IP address, bandwidth used this month, and if backups are enabled.

Console
Next tab over is the console. This is probably the top feature of SliceManger and SliceHost compared to any other VPS provider. SliceManger’s console is an Ajax interface to the actual console of your Xen virtual host (Slice). This means if you somehow manage to lock yourself out of your Slice via SSH you can log in and use the console to fix whatever you broke (I’m guilty of having to do this on a few occasions). No support calls needed if you lock yourself out.
I have noticed (probably because its in a web browser) that the console doesn’t support most ctrl commands like ctrl-c, so don’t do anything that will loop forever and require such a command to break out. Note: This was on a Mac with Safari or OmniWeb for a browser.
Update: Stubblechin in the comments, clarified that Firefox on Mac allows you to issues ctrl-c commands while OmniWeb and Safari do not.
Below is top running in the web based console.

Stats
Next tab is the stats tab. This allows you to pull real time statistics from your Slice. Current time, CPU percentage, CPU time, disk read/write, and network bandwidth are all included as seen below.

Backups
Slicehost offers backups of your Slice at an added cost, from the SliceHost FAQ current pricing is “$5/$10/$15/$30 for 256/512/1024/2048 slices”. This affords you three backups, a daily backup, a weekly backup and a snapshot. Currently SysAdmins’ Chronicles does not use SliceHost’s offered backup. We opted to backup our critical files to Amazon S3, see: Backup to Amazon S3, which costs us a mere 79 cents a month.
Rename
You can rename your Slice if you wish.

Reboot
Another key feature of SliceManager is that you can reboot your Slice. Since SliceHost is using Xen and Xen does have a certain amount of control inside of the Slice, we can do a Soft Reboot. This is equivalent to doing a normal reboot from inside of Slice (technically its sending a ctrl-alt-delete to the Slice). And, of course you can do a hard reboot which is equivalent to powering off the Slice and then back on again. Again no need to call customer support for what at other companies is often a charged for support item.

Resize
So you decide to sign up for a small 256 Slice to test out the service, you start to implement various services, and you find you do not have enough RAM, bandwidth or hard drive capacity, well normally you would look at recreating the system you just setup. With Slicehost they offer the ability to upgrade or resize your Slice. This can be done without any data loss on your current Slice and only requires minimal downtime.

Rescue
If you totally botch your system to a point where even console access is not going to help you, you can just rescue your Slice. This is equivalent to booting off a Linux rescue CD on a traditional system. It will boot your Slice into a rescue environment with your Slice’s hard drive mounted, so you can hopefully fix what is broken.

Rebuild
If rescuing your Slice does not work, with SliceManger you can always just rebuild. This is a fresh operating system install that overwrites all existing data. Another instance where you want to rebuild your Slice is if you decide to change Linux distributions.

Delete
You can delete a Slice whenever you would like.

DNS
SliceManger also supports being a primary DNS server for any number of your domains.

Records
SliceManager supports most of the standard DNS record types, A, CNAME, MX, NS, SRV, TXT, and AAAA. There appears to be no limit on the number of records or domains that can be created.

Reverse DNS
The best part about DNS with Slicehost is that they let you set the reverse DNS record for your IP address, which seems to be a very rare feature with any service provider these days.

Help
Slicehost and it’s staff seem to be very community orientated. During working hours you can find at least one staff member in both the Campfire and IRC chatrooms. The staff there are always knowledgeable and able to check on your Slice or do other technical support items. There is also a typical ticket based support system. Response times have been very fast the couple of times I have used it (I have even received a response on a Sunday evening). Slicehost also has forums and a wiki for community use, as well as technical articles and a FAQ that is managed by the Slicehost staff.
Slicehost Forum
Slicehost Wiki
Slicehost FAQ
Slicehost Blog
Slicehost Technical Articles
Slicehost Twitter Stream
Slicehost Campfire
IRC: irc.freenode.org #slicehost

Account
Lastly, SliceManager lets you take care of the typical account items such as change your email address, password, name, billing address, and credit card information. You can view your current and past invoices and see your current balance and due date for the next bill. You can even cancel your account if you wish.
Referral
Slicehost also offers a referral program. If you have someone sign up for hosting with Slicehost using your email address or referral code and they keep there service for at least three months, depending on the size of Slice they signed up for, you will received $5/$10/$20 credited on your Slicehost account. Its not a ton of money, but it is a little incentive to get your friends or colleagues signed up.
If you are planning or thinking about signing up for Slicehost please consider using us as your referral. Either use the email address ben [ at ] unilogiclabs [ dot ] com or feel free to use the following link: Slicehost Referrer Link
Issues
I really have to nitpick to pick out problems with Slicehost. Ron and I have been extremely happy with our Slice over the past three months, and we plan to continue being a customer with Slicehost for the foreseeable future.
OS Selection
While not Slicehost’s fault, Xen does not have support any 64-bit (all Slicehost’s servers are running 64-bit CPUs and operating systems) BSD based operating system. As of right now the first BSD with 64-bit Xen support is likely to be NetBSD. NetBSD or FreeBSD would be Ron and I’s first choice (Solaris is somewhere in there too) for a server operating system. The Slicehost staff has told me that they plan to support any operating system that supports paravirtualization (see: Types of Virtulization) within Xen on a 64-bit architecture.
Network Downtime
I hate to even bring this up as it was not Slicehost’s fault, but on Thursday, 25th and Friday, 26th of Octber 2007 Slicehost’s dataceter had a distributed denial of service attack (with some or all of the attack pointed at Slicehost customers). Downtime was actually very limited, around thirty minutes each day. The Slicehost team was very responsive talking to people in their IRC and Campfire chatrooms, as well as posting updates on thier Twitter stream and at offsite.slicehost.net. Overall in my opinion the Slicehost staff handled the outage very well. I should also note that is the first time since we have signed up with Slicehost that we had a single problem, and from reports from other users, this is the first network outage as long as they have been signed up (8+ months). See: Network Trouble at the Slicehost blog for more details.
Secondary DNS
Although Slicehost has three nameservers setup for DNS, they do not offer secondary DNS hosting, which would be handy in our situation where we had our DNS setup with a different service when we first started using Slicehost (We still do actually at editdns). It also does not look like they allow domains to the transfered to secondary DNS from their primary DNS service. Additionally, I have not run across any settings in SliceManager to set the allowed IPs for such a setup.
Java and Ruby together. Is it a good thing?
There are some rumblings around the web using GlassFish to host rails applications to offer a simple deployment option instead of the traditional mongrel cluster and reverse proxy frontend. I am currently looking deep into the issues other both scenarios and will report my findings as soon as I make a education conclusion. Stay tuned.
Ruby on Rails Deployment
Introduction
Ruby on Rails is a wonderful platform for web applications and rapid web development. That being said when running an application using the ruby interpreter as well as the plethora of deployment options one can get confused quite quickly. I am writing this post to try and clear the muddy water of deploying Ruby on Rails web applications.
Platform Choices
Disclaimer: None of the recommendations below are tested for the Win 32 platform and there is a high probability that nothing will work correctly or at all.
All of the following deployment recommendations I will be writing about are achievable on most if not all of the UNIX/Linux/BSD operating systems that are available today. Now that we have those very important logistics out of the way lets get started with the foundation for rails deployment!
Note: Mac OS X Leopard (The next release slated for October) will ship with the Ruby on Rails stack already installed and ready to start development.
If you are running Mac OS X Tiger then head over to my Mac OS X Ruby on Rails setup How-To to get yourself up and running with an optimized server-grade Ruby on Rails installation.
Don't be too thrown off by that title because it can be used on any UNIX/BSD Operating System. Just switch up to a source based installation or use the package manager built into your OS.
Foundation
I have two recommendations for optimized Ruby on Rails hosting. I will go over the benefits of each and when to choose one over the other. Both options require an external listening web server and a process to access the Ruby on Rails web application.
Web Servers
I have two favorite WebServers that I use currently. One which runs the blog and one that I run on my internal servers. Each of the below web servers each offer their own advantages to the mix which you can weigh and choose the one based on your requirements.
- Nginx (Pronounced "Engine X")
- LiteSpeed
For example LiteSpeed is not open source and there are two version one which is "more optimized" which costs quite a bit of money. Both the free and commercial versions are managed via a web interface. There is also an option at the time of installation to enable AWstats to monitor the traffic on your website. This is quite simple to setup and maintain. The upgrade process detailed blow is extremely simple to do and requires minimal time and effort.
Ruby on Rails Dispatcher
There are two methods of dispatching the Ruby on Rails web application that I use. One which is handled though an API which is installed via a gem (Ruby LSAPI) and one that runs a backend server which handles the dynamic Ruby content (Mongrel).
- LiteSpeed Ruby LSAPI
- Mongrel HA Cluster
If you have never setup a High-Available cluster before don't worry mongrel makes this process very simple. The configuration for a mongrel cluster is also extremely easy to create and understand. The config file itself can be as small as three lines. I would recommend against this as there are some options that would allow for a more secure mogrel cluster. As you can see below mine is a little bit longer but still you can agree with me that it is quite easy.
---
cwd: /path/to/railsapp/
log_file: log/mongrel.log
port: "8000"
environment: development
address: 127.0.0.1
pid_file: tmp/pids/mongrel.pid
servers: 3
Comparison
Both of the above options are very good choices when deploying Rails web applications. Each have drawbacks. For example if you are on a resticted VPS or other RAM limited server then the choice would be to use the Ruby-LSAPI because it requires only one ruby process to be run thus saving you tons of memory. On average a ruby process takes about 32MB of RAM. This can be quite detrimental if you only have 256MB on a VPS if you are running a 3 server HA mongrel cluster which would require (you guessed it) 96 MB of RAM! That is without the web proxy running which is required by mongrel cluster to proxy between the mongrel servers.
On to the comparison of the web servers that we use as a reverse proxy, Litespeed and Nginx. Both are wonderful web servers that are efficient and have a very small memory footprint. Each taking about only 2MB of RAM to run with minimal load. As the load increases the RAM usage does not increase that much. That being said Litespeed with Ruby-LSAPI is a wonderful choice when RAM is a consideration. When running development mongrel and Nginx might seem more responsive depending on the load and the amount of mongrel servers you have running in the cluster.