Shared hosting is not a ghetto
In the wake of the Dreamhost blog’s post on Rails and shared hosting, there’s been a bit of a meme going around with respect to deploying frameworks like Rails (or Django, or TurboGears…), and which more or less consists of people asking why, if you’re using one of these frameworks, you’re not just ponying up for a VPS or dedicated server. After all, it’s not like the offerings these days are that much more expensive than commodity shared hosting.
There are some problems with this attitude, some of which are elegantly characterized by a comment on Twitter developer Alex Payne’s post “Shared Hosting is a Ghetto”:
people who are living in ghettos are, you’ll find, rarely there because they’re just too cheap to move to the nicer parts of the city.
Let’s run with that and explore why shared hosting, despite the average developer’s distaste for it, is still a necessity and — I believe — a good thing for the modern frameworks to play nicely with.
The hidden cost of dedicated hosting
The first thing to realize is that a VPS plan that costs $20/mo. isn’t actually that cheap; it comes with ongoing costs in terms of systems administration and maintenance that, frankly, a lot of people don’t have the time or budget for. Yes, you get the operating system preinstalled and maybe a nice control panel to configure services, but that’s just the starting point: you also need to monitor security and bugfix updates for all of the software running on your server, and be ready and able to upgrade or reconfigure in response (and even with nice package managers like apt, this is still a non-trivial job).
For that you either need to have some sysadmin skills or have the budget to hire someone who does, and that means your cost, either in time spent doing this work or money spent paying someone to do it for you, goes up. You can get “managed” dedicated servers, but again your cost and complexity go up.
When you take things like this into account, typical shared hosting suddenly starts looking a lot more attractive to the average individual or small business that’s trying to set up a Web presence: they only need to worry about the things that directly pertain to their own site, and the host takes care of the rest of the server environment. And back when I did freelance work, I steered a lot of clients toward shared hosting solutions (including Dreamhost, though, in the interest of disclosure, I never made any significant referral money from them) for precisely this reason: it let the client focus their budget on the things they actually cared about.
Is dedicated hosting overkill?
Also, for the vast majority of individuals and small businesses out there, dedicated hosting is really much more than they’re ever likely to need; standard commodity shared hosting can handle their application loads and traffic levels just fine.
For example, this blog runs on a Joyent Accelerator, which is a virtualized slice of a beefy Solaris server and gives me root access to go in and configure whatever I want. But it’s overkill for what I’m doing here; even when I’m being linked up by a bunch of popular blogs, shared hosting would be able to handle the load with ease. I bought the Accelerator plan for other reasons (including the fact that, as a geek, I just love having cool things to play with).
If I were helping a typical small business to work out what they need for their Web presence, and doing a realistic assessment of their expected traffic levels and resource utilization, I’d probably recommend shared hosting; most people simply have no need for what a VPS/dedicated plan offers, and the additional costs outlined above would make such a plan a bad choice for them.
Flexibility
Ultimately there’s only one argument I can think of in which VPS/dedicated hosting comes out ahead for the needs of the typical web site: the freedom and flexibility to run practically anything. When you’ve got the keys to your own box (or a virtualized slice of one), you have absolute control over what runs on it and how, and that can be a big attraction.
It means, for example, that you can set up Apache or any other web server, and build exactly the set of extensions and modules you want. It means you can tune the database until it sings. It means you can throw up a memcached instance and give it the memory it needs without worrying about per-process limits. It means you can add or shut off services at will. It’s the ultimate power trip for the average web-dev geek.
But is this level of flexibility necessary for running a framework-based application? Absolutely not. The only reason people recommend dedicated hosting for frameworks like Rails is the fact that, right now, we’re all still figuring out how to make the shared-hosting equation work. Back in the days when consumer-level hosting didn’t typically offer CGI access or limited it to canned pre-installed scripts, people would recommend moving up to the next tier of hosting if you needed to run custom stuff Today you’d be laughed at if you recommended dedicated hosting for that.
I fully believe that within a year or two, the same will be true of the new wave of frameworks: there are promising solutions already nearing maturity (and several hosts which are already doing a great job of helping them along), and worries about whether you can deploy a framework on shared hosting will be as antiquated as a previous age’s worries about whether you can use mailform.pl.
Why I care about shared hosting
Thinking back again to my freelance days, when I mostly worked in PHP and Perl, one fact stands out: I almost never wrote a full application for a client. Most of the time I took something off the shelf, reconfigured it, wrote some stuff on top of it or maybe wrote a plugin, and that was that.
Part of the reason for this was the availability of software I could hack on, but a bigger part was simply that writing an entire application back to front, in those languages and at that time, simply wasn’t an option: grabbing a canned app and hammering it into the right shape for the client’s needs, or (more often) something close enough to work, was the only thing that could deliver on time and within budget. I ended up making some pieces of software do things they were never intended to do, sometimes badly, but it was always faster and cheaper than bespoke development.
Today, though, I’d never dream of working that way. If I were freelancing today, I’d simply pick up a framework and build out an application tailored precisely to my client’s needs, and I’d be able to meet both deadlines and budget requirements. By dealing with the common, baseline problems like database interaction, templating and URL dispatch, frameworks free up developers to, well, develop.
But if it’s too hard to deploy a framework-based application on the kind of commodity hosting that most smaller clients will have, then they’ll never see the benefit of it. They’ll keep hearing, and believing, that custom application development is too expensive and takes too much time. They’ll keep getting square pegs hammered into round holes. They won’t ever get applications that really fit their needs. And that’s a case where everybody loses: clients get crappy sites and developers get crappy jobs, and nobody’s happy.
Shared hosting is not a ghetto
Shared hosting is and likely will always be an appropriate choice for many types of sites: individuals, small businesses, non-profit groups with tight budgets, all sorts of use cases that aren’t necessarily glamorous but exist and make up a huge percentage of real-world web development. There are still plenty of cases where I’d recommend VPS or dedicated hosting to a client who has the budget for it, but shared hosting works and is a good solution for an awful lot of people.
And while it’s currently hard to deploy a lot of framework-based applications on a lot of shared hosts, that doesn’t mean framework developers should just ignore the problem or hope that someone else will solve it, or that people who want to take advantage of the power and flexibility of modern web frameworks should be forced into hosting solutions that don’t otherwise suit them.
Like I said the other day, what’s needed is an ongoing dialogue between hosts and framework developers, to sit down and solve the various issues in ways that work for both sides. Comments about how shared hosting is a “ghetto”, or how the customers at shared hosts are just too cheap to get real hosting, bespeak ignorance at best and arrogance at worst, neither of which contribute anything useful to discussions of a real problem being faced by real people.
January 13, 2008
#
Exactly the reason I use shared hosting.
I tried using a VPS accout. I’m a designer, and I realized that system administration wasn’t as easy as I had thought.
All I want is a hosting account that will handle everything for me, just allowing me to modify what I need to setup a rails or a django app. For now, Joyent’s shared hosting is fine for me. In the future, I would probably want something similar, but with more ram and speed. I don’t think I am going to need the freedom and responsibility of a VPS or dedicated server for running my website for clients’ sites.
January 13, 2008
#
Precisely. If you love software development, why would you want to deal with the hassles of system administration? Understanding what administration and upkeep entail is important I think, but once understood, why do it yourself if you don’t have to? Delegation is the cornerstone of civilization my friends, so delegate that onerous responsibility to someone else! Says the hypocrite who’s bread and butter is currently running on dedicated hosts, but still, that’s the voice of experience talking! ;-)
January 13, 2008
#
Yes, they are!
I’m a Dreamhost user and have had an account with them for almost exactly 3 years.
I use 6 GB. OK, some of it is just wasteful. Pare it down to perhaps 4 GB.
I have at least 3 very active user accounts.
I have about 10 domains/subdomains hosted.
I have perhaps over 10 MySQL databases.
And these numbers will easily grow over time.
The cheapest non-shared hosting is easily double what I pay, with a lot fewer services (much less disk space, much fewer MySQL accounts, etc).
I use my Dreamhost account for a number of things - email, Django, Web gallery, file archive (over 700 MB is just archives of a radio show that I provide on the Web), Subversion server, etc.
VPS hosting is better suited for a single specific task. And as such, given that I’m still a student, is way too expensive. Were my site popular or I was making money out of it, I’d consider it. Until then, it would be just plain silly for me to go for it.
January 13, 2008
#
Quite right. My company recently moved from (a single) dedicated server hosting to (very good, load-balanced) shared hosting for precisely this reason. The result? Much cheaper, more reliable and less hassle.
January 13, 2008
#
There are lots of problems with Dreamhost especially if you get serious with Dreamhost. Just google for dreamhost sucks, they haven’t fixed a lot of it. I can’t even upload a 700mb file without rsync because it drops me so often. Go read the trolling from their own users on dreamhoststatus.com . There has even been a case at dreamhost of their own employee “hacking” a customer’s website (he was fired for it).
January 13, 2008
#
I have to agree with you. People often don’t believe me when I tell them that a web app like The Bivalidator which is written in python (using web.py) and that starts to be successful is hosted on bluehost.
January 13, 2008
#
I use WebFaction. Their shared hosting control panel installs Trac, Pylons, CherryPy, WordPress, or if you’re really so inclined ;-), even RoR, in less than five clicks. They’ve dropped limits on the number of applications you can have, it’s only resource utilization now that counts. I was considering VPS but prices weren’t where I wanted them to be a year and a half ago, and now I’m very happy I went with WebFaction. The last thing it feels like is a ghetto; in fact, I’m surprised somebody would make this comparison.
January 13, 2008
#
You have to apply your host to what you need.
I was using a Dreamhost shared account for a site that was dugg multiple times and I never experienced any problems whatsoever.
I upgraded to a VPS from ProHosters for I needed full control over my sites. I’ve never had any problems, and the minor errors on my fault were fixed within minutes from their excellent support team.
If your an advanced user, then a VPS is a good deal for the price.
January 13, 2008
#
I have read them, and people keep pointing me to them for some reason.
Never had those problems. Not once. Dreamhost has a lot of users. So the total number of complaints is bound to be high. That’s the only way I see it.
(I used to have high latency, which is a total non-issue for me - and that went away recently).
If and when Dreamhost cannot handle my needs, I will leave. Till that day comes, it would be plain stupid to do so.
I don’t intend to start a flamewar. I’m not claiming Dreamhost is the best. If someone knows of other hosts that provide all of what I asked (SSH, Pine and mc) for no more than $10/mo, I’ll happily keep note of it for when Dreamhost begins to suck for me.
January 13, 2008
#
“Shared 1” plan at WebFaction. If they don’t have pine and/or mc ask them (after opening an account, file a support request) and they will install it for you. I asked for some dependency Gallery 2 was missing in PHP and they fixed it next day.
January 13, 2008
#
Until hosts can limit usage of things like MySQL then shared hosting will always be problematic.
January 13, 2008
#
Webfaction is great except for the disk space they provide. I already use more than 4 GB, and can see it going greater than 8GB within a year or two.
January 13, 2008
#
Agreed. I haven’t even broken 4 GB limit yet (I use “Shared 2” that was bumped up from 4 to 8 GB only recently), but I can see how that can become a problem rather quickly.
January 13, 2008
#
I agree that frameworks should be able to run just fine on shared hosts, and that more communication between the hosts and the developers is needed. But I think the negative response to the articles posted at DH is due to how it was written, rather than the overall message. The overall message of the article was spot on, things need to be changed for Rails to work on shared hosts. Simple as that. However, Dallas (the author) basically filled the article with as many insults he could find directed at both Rails itself, as well as the Rails developer community. If he had written it as more of a ‘reach out’ to the Rails community asking for help, the response would have been completely different.
I think what DH doesn’t understand, is that if Rails doesn’t work on Dreamhost, people aren’t going to stop using Rails. They are going to stop using Dreamhost (for the most part).
January 13, 2008
#
Another post that hits the nail on the head. As someone who provides admin services to individuals, small business and non-profits, I always start them with shared hosting and manage their account for them, and work toward them starting to manage it themselves if they are interested and capable.
Surprising to some of us who have technical skills, not everyone grew up in the age of computing or got past using a word processor and playing games. I try to bridge their access to the Internet and if I had to manage their sites all on VPS accounts, they may not be able to justify the additional expense of a VPS and my charges with their few hundred visitors and ten thousand page views a month. For most there is enough work updating and managing content on a site in their busy schedules without learning and thinking about the backend administration.
January 13, 2008
#
I make my living doing sysadmin work and python web development, yet I still use shared web hosting for 3 things:
Non-critical sites like my blog and small client’s whose site doesn’t need five-9s of reliability.
E-mail for anyone not using a 3rd party solution. I’ve wasted far too much of my life administering Postfix + MySQL + clamav + dnsrbls + spamassasin + mailfilter + dovecot + sasl + an spf policy checker… plus the constant hassle of calling AOL when they block my client’s mail. I’ll gladly take a slight drop in performance and reliability and just let a shared hosting provider handle mail for my few clients who still want it.
DNS. Why do people fight with their own BIND installs? I just let DreamHost/GoDaddy/ handle my name serving needs.
Some people might call that crazy, but it gives me a whole lot more time to focus on the things that are really important to my clients.
For my reliability and performance I use (and love) Linode: http://www.linode.com
January 13, 2008
#
This post hits the nail on the head.
SharedHostingThatDoesntSuck.com anyone?
Someone should post to reddit a roundup of the best shared hosts for web geeks.
January 13, 2008
#
I manage multiple shared hosting accounts on multiple providers, some big some small, I manage multiple dedicated private servers and managed servers. I consult for more than one Fortune 500 company as well as manage sites with as little as 15 unique visitors a month and as many as 30,000. I’d like to think I have a pretty good grasp on reality when it comes to hosting. YOUR BLOG PROBABLY DOES NOT REQUIRE DEDICATED HOSTING. I’m not suggesting dedicated or shared hosting is right for everyone, there is a reason the hosting world is so diverse.
If you’re doing anything that requires security of any kind, shared hosting is a joke. Not to mention it’s impossible to met the Payment Card Industry Data Security Standard on a shared host so if you’re doing e-commerce where credit card numbers are passing through your system on shared hosting, you’re in breach of contract at the very least and in some countries worse. Although you’re probably not going to run into trouble the contacts you signed for your merchant system certainly require some level of compliance. If you’re taking cards and you don’t know what I’m talking about, there is a security standard put our by PCI Security Standards Council, LLC. which most Payment Card Providers require you to meet in order to use the cards (which are their property), They provide the information for your benefit free of charge here: https://www.pcisecuritystandards.org/ if you’re using a service like 2Checkout or PayPal or Google Cart or Amazon Payments you don’t need to worry about it.
Users passwords are private information. It’d be nice if everyone used different passwords for every site but the fact of the matter is, if you compromise a system and get passwords and e-mail addresses, or just strait MD5 or SHA1 hashes there is A LOT of havoc you can create. (salted hashes kibosh this but many applications don’t use them)
If you’re aware of the issues with shared hosting and take the security of your information seriously, shared hosting CAN be a workable solution, NEVER rely on the provider to secure YOUR information. I’ve been able to obtain private information from other user’s files on Dreamhost and Web Faction in the last 2 months as well as Bluehost, about 6 months ago (haven’t tried recently) it’s astonishingly easy, most shared hosting providers offer little security and will not secure their system if informed of flaws. (Private information being, database usenames and passwords, private keys, usernames and hashes and in one case write access to source code.)
If your site/application whatever can’t afford dedicated hosting, PLEASE do spend the extra money for a quality virtual private server and take steps to secure it.
January 13, 2008
#
I’m a newbie developer and experienced sysadmin. I’ll let you all in on a secret, programming is a LOT harder than sysadmin work. I’m switching because it’s just not that challenging anymore. Security updates are a simple cronjob for most major distros you really don’t need a firewall for production systems (keep SSH and HTTP open). I’ve used shared, dedicated, VPS - the most bang for my buck comes with a modern VPS (I use slicehost) and I can add more as I need them. On top of that, I feel that knowing both sides of the coin (development and deployment) makes you better overall.
January 13, 2008
#
For what it’s worth, I’ve got no problem with hosting static content you don’t particularly care about on a shared host like Dreamhost. Like most everyone who can spell HTML, I’ve certainly done as much.
You got some stuff wrong, though:
Call it ignorance or arrogance, but we’re both saying the same thing: you don’t put important stuff on shared hosting. “Individuals, small businesses, non-profit groups with tight budgets” and so forth is just a nice way of saying, “people who won’t notice an hour of downtime at 2AM a couple of times a week.”
I’ve seen too many technically un-savvy customers get their sites shoved on shared hosts, where they experience terrible uptime and lousy customer service that’s a pain to resolve after the developer of their site has moved along to other projects. Of course, I’ve also seen way too much small clients get stuck with a custom-built content management system that only one developer knows how to support.
January 14, 2008
#
I agree with the general sentiment here, but some of the explanations are really off-key. The comments suggesting that shared hosting is appropriate if you don’t care about reliability don’t square with my experience - when I’m on a shared host, one of the things I pay for is the peace of mind to not worry about uptime, because it’s someone’s job to take care of it for me. Even as we speak Flickr is recovering from a weekend’s worth of massages, and most of the more popular Web 2.0 services experience a lot more than “an hour of downtime at 2AM a couple of times a week.” A lot of stuff can fall on the floor when you roll your own.
I often tailor the projects I work on specifically to fit within the resource and feature boundaries of shared hosting, just so I can slough off sysadmin headaches like log rotation, CPU worries. My shared host of choice since ‘02 has been Pair.com, and they are absolute champs for support, reliability, and features.
January 14, 2008
#
Alex: I have root within the Solaris zone that is my Accelerator. Not on the box, but then I don’t need that. And even the cheapest VPS still comes with hidden costs, as I’ve outlined above. And for a lot of people those costs move VPS hosting out of the question.
As for this:
No, to the individual or the business or the non-profit, their site is vitally important, and they will notice if it goes down (aside from scheduled maintenance). I know that from experience.
January 14, 2008
#
I you find yourself cursing at your current host you owe it to yourself to try WebFaction. These guys really know to make it easy for people to run their sites. I use them for Rails and PHP (don’t ask…) and they rock!
January 14, 2008
#
As primarily a designer, I’ve found a nice balance in Mosso because it gives me enough power, scalability and flexibility to customize each domain but still remain safe and confident with great tech support. Everything about Mosso, at least to me, feels right.
January 23, 2008
#
I don’t see any problems with using shared hosting, if it works for one’s needs. If you need something better, for whatever reason — running specific versions, running non-standard software or for better performance — then do it. I use DH for several projects I’m in control of, and haven’t yet had a (major) problem. I haven’t used a dedicated server for anything since 2001, because I haven’t worked on anything that became very popular. The key is to know where the limitations are, monitor how close you are to those limitations, and know how to move things to a dedicated server when the need arises.