Skip to main content
Advice

Blocks: Containers and virtualised computers explained

A tale of computers, containers and Swiss Army knives

Joe CollinsHosting operations engineer
1 min read24 September 2021

After completing a PhD and a short career studying road safety at Southampton University, Joe Collins has spent the last 20 years writing and maintaining software for the likes of the Ordnance Survey, BT and IBM. Now he is part of the hosting team at Contensis and helps maintain the infrastructure that runs the platform. Most of the time he finds computers just as irritating as you do.


Computers are like Swiss Army knives

Ever had that Mac or PC discussion before? Even if you haven’t been directly involved, I’d be surprised if you hadn’t at least been present. You know the kind of thing...

“If only you were using a Mac, it would just work.”
“You should have bought a PC if you wanted to do that.”

The discussion, the people involved, and the computers themselves are all pretty irritating. Whilst there’s no resolution to the discussion other than a few bruised egos, it does point to one thing – the computers you and I buy from PCWorld are a sort of Swiss Army knife of computers.


The “does everything tool” might seem like an attractive cost saving, but as every craftsperson knows, if you need a knife, you should get one suited to the task at hand. The Swiss Army knife, whilst handy, isn’t actually a very good knife.

Joe Collins at Contensis

We expect them to be able to do a lot of different and diverse things for us. However, like any multi-tool, they’re often not quite the perfect tool for the job. They just don’t work as well as you want or aren’t quite capable of doing exactly what you ask.

It is probably significant that new recruits to the Swiss Army, when issued with an actual Swiss Army knife, immediately go out and buy a second one. The first is to present at inspection, while the second is the one they actually use – the one that inevitably becomes mangled and damaged by being employed to do tasks it isn’t quite capable of doing.



Specialized computers

The principle above transfers very well to computers. If you want a computer to do a task well and do it reliably, it should be designed and used for that singular task and that task only. So, if you are doing different things with computers, the solution is to have lots of different computers – one for each task. This would mean having your web server, your file server, and your database all on different computers, for example. Back in the mists of time, when I was a newly minted nerd, this is exactly what we did.

The computer room had rows of tables with computers, screens, and keyboards. Typically there was one worn-out office chair so you could scoot between computers as you worked on them. Over the years we have gotten smarter. First, we stacked the computers together on shelving and eventually in special racks. Then, rather than having multiple screens and keyboards, we used a special switch to alternate between the computers so we only needed one keyboard and screen.

Somewhere along the line, the office chair got lost, so now we kneel down and wear out the knees of our trousers, or bend over and get an aching back. And, because every time we had a new task we’d buy a new computer, after a while we’d end up having to maintain a lot of different physical computers of different ages and specifications. As a result, there is an upper limit to the number of physical computers any one member of staff can maintain – leaving aside the wear and tear on their knees and back, just remembering where the computer is and its characteristics is a challenge.


Specialised virtualised computers

Eventually, some brilliant soul realised you can get a computer to pretend to be another computer. This is an idea that, to this day, still charms me. Rather than installing your Windows operating system or Mac OS on a physical computer, you can install it on a piece of software running on another computer that is pretending to be hardware. This is known as virtualisation, and it’s all a little bit mind-boggling. But, it means that one fairly large computer can run a whole bunch of smaller computers inside it.

Each of those smaller computers can be designed and used for a singular task, but they don’t exist as physical hardware anymore. If we want to change anything, we can tell the large computer to pretend to be different hardware.

For example, if one of the smaller computers needs more memory, we can flick a switch and the large computer will pretend to the smaller computer that it has more memory. This has been a great leap forward in allowing us to conveniently manage many more computers, not to mention the great benefit of avoiding having to bend down or kneel down to work on the machines.

Much in the same way that physical computers went from being placed on tables with their own monitor and keyboard to being mounted in racks in dedicated data centers, virtualisation has also gone through a number of iterations over the years.


Specialised virtualised containerised computers

The current incarnation of virtualisation is generally referred to as “containers”. At some point an even more brilliant soul realized that it was a lot of work for the big computer to pretend to provide complete incarnations of a computer's hardware to run a smaller computer. Most of the jobs we need done by the smaller computers aren’t actually that complicated.

So, the big computer only needs to fake just enough hardware to get the smaller computer to work. The smaller computers don’t need to play music, stream Netflix or do any of the thousand and one things we expect our “do everything computers” to do.

The smaller computers are now simply called “containers” because they are no longer complicated enough to merit the term “computer”. They contain a single task with just enough computing power and intelligence to do their job. Containers are really just self-contained packages of code and configuration files that can be used to run the independent parts of your website or application.



Blocks - a new way of working with containers

It is this “container” technology that underlies the Contensis Blocks service. Blocks is a new feature of Contensis that allows you to deploy a container with your code managed on our enterprise-level infrastructure. Once a Block (which you now know is a container) is built and deployed, it becomes available in the Contensis interface, where you can choose to make it live or just experiment with something new. Since it is literally contained, any experimentation won’t interfere with your live website.

Also, since the “containers” are very specialised (or in computing terms quite dumb) and are only doing one thing at a time, they tend to be a lot more reliable than the computers we buy from PCWorld. I say “tend to be” because nothing is completely reliable, inevitably sometimes things go wrong.

What’s our solution? Well, turn it off and on again, just like any other computer. They say IT is a dynamic and changing industry, but this piece of advice has stood the test of time. However, because Blocks are now a long way from being real computers, they are a lot easier to turn off and on again. In fact, we can tell the big computer to create a new replacement and turn off the ailing original Block for us. So, for us the procedure is more like turning on a clone or twin and then turning off the original.

If this all sounds jolly convenient, it is – until you realize that we now have thousands of these Blocks or containers to manage. This is way more than we were able to manage when they were physical computers, to the extent that now just finding the container becomes a challenge in itself. The convenience and reliability of having lots of containers doesn’t come without cost.


Big Macs and Blocks

In the hosting department we have whole infrastructure dedicated to monitoring what the containers are up to. Whatever you think of McDonalds’ product, a Big Mac is the same every time you buy it. It's this kind of consistency we aspire to in the hosting team. We want to provide containers that are as reliable and consistent as Big Macs, and a whole lot less irritating than those conversations about Macs and PCs. We’ll let you do the creative, imaginative and exciting stuff, while you let us take care of the container that's running it.

If you’re interested in finding out more about Blocks or our hosting services, please get in contact. You don’t have to host with us, but we can talk through the options and ensure that you get the best service you can for your Contensis website.


Get more info about blocks
Joe CollinsHosting operations engineer

Joe has spent the last 20 years writing and maintaining software for the likes of the Ordnance Survey, BT and IBM. Now he is part of the hosting team at Contensis and helps maintain the infrastructure that runs the platform.

Ready to get started?

Contensis supports modern development practices. And it works with your preferred tools – from VS Code to Git. Browse the documentation to get started.

Request a demo