Anti-Buzz Software

Anti-Buzz: Operating Systems

Andrew has been writing Anti Buzz for 4 years resulting in almost 200 articles. For the next several weeks we will revisit some of these just in case you missed it:


newface-620x461The Buzz: Operating Systems are a brand, inseparable from the machine they are sold with.

The Anti-Buzz: Operating Systems are just mediators, and more interchangeable than you might think.

Operating systems: How do they work? What is their relationship with your hardware?

Where is the operating system?

The first thing that might come to mind for most people is that when they think of operating systems, they probably only think of two options: Mac and Windows. This is fine, but it does ignore the fact that your smart phone, (even if it is a “Windows” phone), has an operating system, as does your tablet and your Kindle. Of course, pointing this out only exacerbates the first common misconception I’d like to destroy, which is that the OS has anything to do with your hardware. If your observe that the iOS is only on iPhones, Mac OS is only on Macs, and Windows is only on “PCs”, you’d be forgiven for thinking that the OS was in fact part of the hardware itself, that it was encoded, at least partially, in the actual transistors of your machine.

No, all operating systems are 100% pure software, and they 100% live on your hard disk. They are just programs, not unlike all that other software you use. They are, however, incredibly reliant on the hardware they work with, so in some way specialized cases, such as your smart phone, both the hardware and the operating system were designed with each other in mind. However, computing hardware and software have become increasingly modular in design, so it is likely that all of these components can be made interchangeable, with some work, (That is, iOS on your PC, Windows 7 on your Kindle, whatever).

In fact we have seen this already to some extent, as it was widely publicized that a little elbow grease could get Chrome OS installed on a Nook Color, effectively turning it into a tablet at a fraction of the cost. In a brilliant stroke of 21st century thinking, Barnes & Noble responded by saying “Cool, we’ll just sell them this way,” instead of the usual, paranoid protect-our-product-from-our-customers that we are used to seeing from the entertainment industry, (I wouldn’t be surprised if, being a bookseller-that-survived-the-great-reckoning, B&N has a better set of priorities than many software companies).

Anyway, less surprising, (But maybe you did not know?), is that you can install Windows on your MacBook, and Linux too if you are so inclined. Some of you might be a little surprised to think of a machine with multiple operating systems, (you just pick which one you want to use when you boot up), but that should drive home the point that operating systems are just software, and all your things: photos, music, documents are just data. In my case I listen to the exact same mp3s when I am using Windows as I do when I am using Linux – it’s just data, and the operating system is just a portal to that data.

How does the operating system use the hardware?

Again, the OS is extremely reliant on hardware, most especially the CPU. A compiled OS will only work with one architecture, which was the real sticking point in the 90s…

when considering the rift between Mac and Windows: they both were made to run on entirely different CPU architectures. Apple has since switched to Intel from PowerPC, and Intel rival AMD makes processors that obey the same instructions set as Intel. So Mac, Windows and Linux can all be run somewhat interchangeably on the same hardware.

Except, why do you only find Mac OS on Apple products? Because the OS is also reliant on device drivers, (Drivers, again, being pure software, that are effectively a bridge between the OS and the actual hardware). Very intentionally, Apple has ensured that Mac OS only has drivers for the hardware that their products actually use, thus ensuring that Mac OS will only work on Apple products, while Windows can be installed on a myriad of configurations, (And thus, there are myriad manufacturers), including Apple products. This is why you can install Windows on your Mac, but not Mac on your PC, because Apple has intentionally created this barrier. This barrier is actually fairly small because there is no theoretical reason why Mac OS can’t be run on a larger scope of machines, and in fact there is a community based around doing just that.

So those are two primary hooks that cause hardware to limit your choice of systems, CPU model and the existence of drivers. At the end of the day, your operating system is the only software that actually has the privilege of interacting directly with any hardware, (including the CPU), and this is actually the entire point of an OS – to provide an abstraction of your hardware resources to other programs stored on your hard disk.

So why can’t I run Mac programs in Windows and vice versa?

In many cases the architecture is the same, which means that anymore there is not actually that much of a difference between compiled binaries of programs meant to run on different operating systems. However, the OS is the great mediator, and so any access to hardware goes through the OS, and each OS handles these things differently. When programs are compiled, they are still compiled to be OS-specific, even if they often share the CPU architecture, because going through the operating system uses system calls, and they are different for every OS. However, modular software libraries have made it increasingly such that making a Mac version and a Windows version of the same program is almost just a matter of just compiling twice.

The divide between operating systems is made worse by a lack of unity among file systems. A file system, at the end of the day, is just a schema for how files are organized on a hard disk, (Here, files includes your applications), and some operating systems only want to work with a subset of the file systems out there. In the case of Mac and Windows, they have to be really coaxed to even look at a drive formatted in the file system of the other.

So how does the operating system actually boot up and start running?

Terminology time! You’ve probably heard of a few of these terms, but never quite got the lowdown on what they are. Life on your computer begins with the motherboard and its firmware. On non-Apples this is referred to as BIOS, while Apple uses AFI. Firmware is software that is stored directly on a piece of hardware, (So your BIOS is not on your hard disk anywhere, it is stored in a tiny disk somewhere on your motherboard). So, the power goes on and your motherboard begins running its firmware, which in turn wakes up all your other hardware, makes sure it can see them, and then it tries to relinquish control over to some operating system, typically by looking for one on your hard drive.

When you start up your machine and get that wall of text, usually with stats about your hardware, before you get to your Windows loading screen or whatever, that is your firmware talking, and that is actually specific to your hardware, and will look the same regardless of what OS you eventually boot into.

The program that gets run by the firmware when it wants to boot up your operating system is called the kernel, (because it is the seed for everything that follows). The kernel is the operating system, these terms are practically interchangeable. This is the program that manages everything: which program runs on which processor and for how long, who gets access to what memory, and so on. All of that micromanaging required to mediate your software and your hardware, that’s what the operating system does, and that’s what the kernel does.

But what about windows and buttons and the GUI I use to start all my applications? Isn’t that the operating system?

Yes and no. Here is the other common misconception about operating systems. Users equate the abstraction of Finders and Docks and Start Menus with the actual operating system. The thing with the windows and the folders that let’s you navigate your computer and do stuff? That’s not your operating system, that’s a shell. A shell is a program that allows the user to issue commands directly to the operating system. And yes, clicking on the Start Menu and selecting a program counts as issuing a command to your operating system – “issuing a command directly to your operating system” isn’t some crazy hard-core thing that only happens on a text-only console.

So I say “yes and no” because it should be obvious that you can’t really use an operating system without at least one shell, which is why the casual user might equate them. Also, much as the firmware looks for a kernel, the kernel needs to start up at least one shell after it gets a grip on your hardware.

So, you can only be using one OS at a time, but any OS can have any number of shells. Most people just only use the one, the nice graphical one designed specifically for whatever your OS of choice is. The old-fashioned command line interface, still available on all machines, is another type of shell you could be using. But even among graphical interfaces, there is nothing to stop you from having multiple options for graphical shells, as is the case with Linux, where you can install a variety of different GUIs and use them all to navigate your files and launch applications.

I’m not trying to sell you on Linux, just trying to get you to understand that your operating system only sees things like “Start Microsoft Word” and doesn’t really care if it received that command from a user typing onto the command line or a user clicking on some icons. That thing where you click on icons is just another application, one meant specifically for you to tell the kernel what you want to see happen next.


Leave a Reply

Your email address will not be published.