Monday, October 4, 2010

VPS/VM vs Dedicated vs Cloud Servers: Hosting options and cost comparisons

I usually talk about Code on this blog, but eventually that code is going to have to run somewhere so I thought I would outline some of the different server options that are available. While there are free or low cost options for hosting simple or small websites, if you are using ASP.NET, PHP, or Java to create a dynamic website or if you are looking for a file or application server then you are going to have to pay for the resources that you use (bandwidth, hardware, software, etc). The price/performance ratio can vary greatly depending on what type of server you purchase. There are a lot of different configurations, but here are some of my recommendations.

First, what not to do:

While in certain cases it may be appropriate, my recommendation is to steer clear of two specific hosting options: Shared web hosting and Do-It-Yourself hosting. Shared hosting refers to the $5 a month plans offered by Godaddy, Yahoo, and thousands of “resellers” that use a control panel like Plesk or cPanel to divide up a single server into hundreds of small websites. These servers are often over-sold and under-powered, and you will only get FTP and control panel access, so you will have to rely on your hosting provider to make any advanced configuration changes or perform troubleshooting steps for you. If you cannot afford any of the other options then Shared Hosting might be a good way to start, but keep in mind that you get what you pay for and will  probably out-grow it very quickly.

As for Do-It-Yourself hosting, this is simply a case of economies of scale: You wouldn’t start a wheat farm just to make a sandwich, so why build and maintain your own servers? Unless you are a corporation with a full IT department, it is not in your best interest to setup and maintain your own web or application servers outside of your personal testing/development environment. Servers are more or less a commodity nowadays, so while you could setup a computer in a closet of your office and use it to host your company website, you then have to worry about what happens when the power goes out or when your Internet connection goes down. Setting up and maintaining a reliable network with redundant paths and uninterrupted power takes a considerable amount of time and money. I highly suggest that you outsource this effort to a 3rd party and focus your energy on improving your website or application instead. And in terms of running your own Email and Calendaring server, you really, REALLY should look at paying Google, Microsoft, or someone else to provide these services for you if at all possible.

Virtual Private Server / Virtual Machine:

It use to be that when looking for a hosting provider you were either stuck with shared hosting or a dedicated server. Now there are many other options, most of which are based on server virtualization. While it may sound similar to Shared Hosting, VPS or VM hosting options can provide guaranteed resources and an isolated execution environment in which you have full control of the server. The hosting provider will purchase high-end server hardware and then use a hypervisor to divide that server up into multiple virtual machines for different customers (usually 2-24 depending on the size of the VMs). Each VM gets a certain percentage of the CPU, Memory, and Disk Space and will function as its own server. From my experience VPS or VM hosting provides the best bang for your buck at around $20-$120 a month (see Choosing a Hosting Provider below).

Dedicated Servers:

Some applications require significant horsepower, in which case a dedicated server is usually a requirement. You can purchase standardized “cookie-cutter” servers from most hosting providers, or you can also get a custom quote if you need to have a specific type of RAID setup or maximize RAM size or CPU speeds. Until recently I have primarily worked with dedicated servers that usually run anywhere from $100 to $1000 a month, so they are only viable in business environments that can justify the cost of the server. You also may have the option to rent, lease or purchase the server, but if you are purchasing you must factor in the time and costs for replacing failed hardware components in the future. Also if you work with sensitive information such as credit cards or medical records then you may require a dedicated server to meet Payment Card Industry (PCI), Health Insurance Portability and Accountability Act (HIPAA) or various other federal regulations.

Cloud IaaS and PaaS Servers:

Cloud hosting is the new hot term, but a lot of the time it means the same thing as VPS or VM Hosting except you pay by the hour instead of by the month. There are typically 3 types of “Cloud Computing”: IaaS, PaaS, and SaaS. For the most part Infrastructure as a Service (IaaS) is exactly the same as VPS or VM hosting just with a fancy API and pay-by-the-hour terms. Software as a Service (SaaS) doesn’t really have servers in the sense that you usually are riding on top of another application (Ex: Google Apps or Salesforce). Platform as a Service (PaaS) still uses Virtual Machines, but the platform is designed to help you scale your application horizontally across multiple nodes. Amazon Web Services (AWS) has some PaaS products, but their EC2 product fits more into the IaaS category (you have to scale-out your code to work on multiple servers on your own). Windows Azure, Rackspace Cloud Sites and Google App Engine are examples of PaaS, but they each have different programing models so you have to build your application around their platform. PaaS is designed to scale to meet your traffic needs and use multiple server nodes to provide better reliability, but this also means you will play a higher cost if you are running a 24x7x365 application. For instance, running two small web roles in Windows Azure to create a high availability website would cost $0.12*2*24*30 = $172.80 a month.

Choosing a Hosting Provider:

So now that you have an idea of the different types of hosting, all you have to do is find a hosting provider that offers a solution that meets your needs. I have worked with ASP.NET websites of various sizes for the last 5-10 years and can highly recommend the following companies based on my experience with them:
  • Offers all types of hosting ranging from shared to dedicated to virtual machines and custom quotes. Their VPS product is very affordable starting at $35 per month for a Win 2003 server or $20 per month for a Linux server. They also have great rates on dedicated servers starting at around $70-$80 a month. I had a server with them for about 10 years and they have always had great support and great prices.
  • Recently I moved my Windows server over to a VPS hosted at AccuWebHosting. They are not as large as, but they offer some of the the best rates on VPS servers starting at $23 per month for Windows or $16.50 per month for Linux. While not as powerful as a dedicated server the VPS servers work great for light web or application servers.
  • Offers fully managed dedicated servers and colocation services with “Fanatical Support”. They are a premium provider and cost a bit more than their competitors (starting around $500-$600 a month for a mid-range server), but if your application is mission critical you can feel comfortable turning over the keys to them and they will make sure your servers remain online and operational. Also Rackspace is the only vendor I have ever been able to get to sign a HIPAA compliant Business Associate Agreement (BAA).
  • Originally called Mosso it was rebranded in July 2009 and offers Cloud CDN, Website, and Server solutions. They have managed servers starting at less than $100 a month, so if you want “Fanatical Support” without the high costs this might be a good place to start.
  • Amazon EC2: EC2 is the most mature of the online cloud providers and offers the most pricing options including Spot and Reserved instances. If you envision scaling out to hundreds of servers it is well worth your time to check out EC2. Their Simple Storage Service (S3) is also one of the best storage providers as it offers two price points depending on the level of durability that you require.
  • Windows Azure: Designed for high reliability and easier development, Azure is worth looking into if you are starting a new Microsoft .NET project that will require multiple servers. They are the new kid on the block, having been officially released in February 2010, but their use of Roles instead of servers means an application can be easily scaled up or down as needed. Also SQL Azure is a great way to create a hosted MS SQL database, as you pay $10 per GB per month, which combined with $0.15/GB/Month for blob storage means you should be able to store all your data and images/files for relatively cheap and support a large number of simultaneous users. Check out an introduction to Windows Azure for more information and watch the Cloud Cover show on Channel 9 for great coverage.
I hope this helps as you look at designing or scaling out your application or website. If you have questions I highly suggest asking them on one of the StackExchange websites such as or There are usually lots of great people there willing to help answer questions.


Anonymous said...

THanks for the article. very helpful.
I am building an apps with MySQL (cost reason obviously), and I am debating between
1) Amazon windows EC2 + MySQL RDS
2) Rackspace Cloud Server ( 1 Windows 2003 + 1 linux (mysql)
3) or a good VPS server. like you suggested

I am leaning to 1) and 2) because I have a small operation, I don't have the resources to seemingly scale up with a VPS.

Anonymous said...

Hello, I spotted a broken link. You've an extra . in the rackspacecloud link

Anonymous said...

Thanks, great article.

Blog.TheG2.Net - Your guide to life in the Internet age.