Cloud Servers vs. Virtual Machines vs. Micro-Servers

by Mike Levin SEO & Datamaster, 03/07/2012

[caption id=”” align=”alignright” width=”300” caption=”Image via Wikipedia”]English: SheevaPlug with external drive enclos...[/caption]

My procrastination on the loadbalancing project was in-part because I don’t yet have work paying for my Rackspace hosting yet (yes, the project is THAT skunkworks-y) and I thought loadbalancing was going to be expensive, but also in part because I thought load balancing was going to be complicated. Well, I was wrong on both counts. A load balancer AND second server is only costing me $15/mo more, due to adjusting my service tier down on my first server.

Even so, I don’t want to keep paying $35/mo for this, and my priority now is to either get work to pay the Rackspace bill for my account, or to create a new account and move or reconstruct my servers there. Reconstructing a server is actually pretty easy. It’s nearly scripted now. But either way, making work pay for Tiger hosting is a big step in going official. That may take time, so I should get on it. But now, there are no unknowns. I am speaking from a position of having done it. Perhaps automated servers-on-demand via a Python script—but I can tackle that later.

Days like yesterday really hit home for me the narrow divide between thinking and doing. I set up what in earlier times would have required securing rack space, spec’ing out 3 servers, building and configuring them, and setting up the network, and rigorously testing everything. But now, it’s much like using Office software. I would go as far as to say its even easier, as you’re not dealing with unlimited revisions, half of which are lost in email attachments. Indeed, it’s a golden age for doing this sort of stuff, thanks to Rackspace, Amazon and others like them.

With all that positive experience, you would think I’m a devout cloud advocate—but as much as I love the cloud, I’m equally pumped over tiny servers that can fit in the palm of your hand, and be hosted from home. I’m still even having trouble letting go of the big rack-mounted hardware that served as the heart of HitTail, where if you tweaked the software just-so you could squeeze ungodly levels of performance out of the hardware. People still can’t believe what I did with 2 vintage 2006 boxes.

Point is, there’s power in ‘dem ‘dere boxes that we would all be remiss to walk away from for love of the cloud. And the power doesn’t all come from dedicated hardware and clock speeds. It comes from sheer control. It comes from doing things others tell you that you can’t or shouldn’t do. It comes from understanding things more deeply, because you had to wire it all up yourself and make it go, and therefore have a better grasp over what’s possible and what’s not.

Now, I never really did a loadbalancer myself in a server closet. To tell you the truth, I barely even understood the difference between a switch and a router until recently. But I’ll tell you, I’m going to be doing it myself now—without the cloud. It’s apropos that my monthly cloud-hosting fee is about $35/mo after this work. Guess how much a brand new server costs? You guessed it: a Raspberry Pi is $35!

In 3 months of paying for cloud service, I could use the same money to fully pay for the hardware it takes to build such a network. Of course, you would have to use your wifi router as the switch, and your home cable or DSL service for hosting. But you’re paying ridiculously high rates for home broadband already anyway, so why not do some home hosting, and get the most out of it?

But it all sounds so terribly techie, right? That’s where my third love—or should I say love/hate—fits in: virtual machines. They let you experiment and cut your teeth on this stuff with no risk and no cost. Get good at it now, and rent cloud hosting or buy micro servers later when your confidence level OS boosted. I say love/hate because virtual machines can be your best friend or your worst enemy—depending.

So, what’s a virtual machine? It’s a computer inside a computer. You know you’re looking at one when you see one computer literally “booting” inside another (you know it’s not a remote desktop because you never see those boot).

In reality these days, just about everything is a virtual machine (VM) of one sort or another—but it didn’t start out that way. Virtualization was mostly a mainframe technology to isolate multiple users from nuking each others work, until companies like VMWare popped up and made it a desktop novelty toy. But over time, thanks to the big multi-core CPU push by Intel and others, it really only made sense to make virtualization more common.

By knowing computers could emulate each other, somewhere along the line, somebody… and soon everybody… decided it would be a good idea to virtualize everything, due to the advantages it provided in security and resource management. Java always worked this way. Windows now works this way. Many flavors of Linux also work this way. And anything “sandboxed” like iPhone apps and Google Chrome tabs more-or-less work this way.

But I digress. That’s all just background to the fact that sometimes a virtual machine is not actually being hidden from you, and this is the case with how I use the one called QEMU. QEMU is special because it’s a free and open source (FOSS) virtual machine that has been ported to every major x86 platform—meaning Mac, PCs and Linux/Unix. QEMU also doesn’t need to be installed or have admin privileges to run on your computer.

The upshot of all this is that you can have a computer that you carry around on a USB stick, or which run from cloud drives like Dropbox quite nicely. Of course it’s just a file that needs to be double-clicked on a host machine, cut it doesn’t matter if that host machine is a Mac, PC or Linux—so long as it’s x86: Intel or AMD 32 or 64 bit, which almost all desktop PCs and laptops are. And the file is still under 15MB—one tenth the size of most tiny Linux installs.

Putting a FOSS operating system, language and editor onto FOSS virtual hardware actually constitutes a universal development platform—or at very least, a universal learning platform. The way you learn to code will in all likelihood be the same way you code 20 years from now (as opposed to commercial IDE’s like Visual Studio and Xcode). The code you write today will in all likelihood be able to be run on that very same virtual machine 20 years from now (of course, there will have to be a ziggurat of VMs to make that possible). And your code, or indeed a copy of the entire virtual machine, is 100% ready to share with other people… without worrying about “execution context”. The entire execution context travels with it! It’s a genie in a bottle.

The goal here is to give you the capability and know-how to do anything you can do on a cloud server with your own hardware—merely using the QEMU virtual machine as a convenient stepping stone to build experience and confidence. Knowing how and why QEMU works the way it does will go a long way towards understanding processors, system architecture, security, and networking. But I actually want to get you onto a Raspberry Pi or SheevaPlug as soon as possible, because dealing with actually tangible hardware that belongs to you makes all the difference.

So, I am indeed an advocate of cloud servers, micro-servers and virtual machines. The personal QEMU VM is a safety-net and a stepping stone. It ensures you always have a place to run your code, and that you can fire up that environment just about anywhere. The micro servers ensure that you have hands-on hardware experience—forgoing only the increasingly unnecessarily server build of rack-mounted servers. They also let you eek the full value out of the money you pay for broadband Internet access at home. And finally, I advocate the cloud, because once you thoroughly understand a thing—and don’t need any of the special advantages controlling the hardware can provide—it’s much better to use Amazon, Rackspace and the other cloud providers to let you do more in less time and with less maintenance.

Enhanced by Zemanta