Operating System

"The box said that I needed to have Windows 98 or better... so I installed Linux."

- Anonymous about Linux

Before a computer can do much, it'll need some software to provide basic system services. This is basically what an operating system (or OS for short) does; it manages devices and memory, keeps applications from stepping on each other's toes, and provides an Application Programming Interface (sometimes many APIs) for applications to use.

In the early days of computing (and even now, on special applications like microcontrollers), computers didn't have OSes; you programmed them directly in Binary Bits and Bytes, and on some really old machines (including ENIAC, the first practical electronic computer, and IBM's old card-counting machines), you didn't have program memory at all—you had to rewire them on a device not unlike an old-time telephone switchboard. Starting in the early 1960s (but not immediately showing up everywhere), the advent of time sharing (what we'd now just call multitasking) led to huge advances in what computers were capable of, and the first modern OSes date from this era. Later, when microcomputers became common, they had much smaller operating systems of their own, such as CP/M, Apple DOS, ProDOS and MS-DOS; since microcomputers didn't have special hardware to manage and protect memory, most of the time a microcomputer OS simply wrapped the machine's ROM libraries with disk I/O functions, something that was especially true on the Apple II and the IBM Personal Computer.

As PCs got cheaper and more powerful, full operating systems started being written for them, with richer APIs, actual memory protection and "demand paging" (which allowed applications to use "virtual" memory that actually lived in a file on disk). Pretty much all PC OSes now include this as a matter of course.

Most operating systems work as four separate layers of software running in the computer. The lowest layer, the one that interacts directly with the hardware, is known as the kernel, the core of the operating system, which handles stuff like memory management, program input and output, communication with your hardware, and might have other additional functions—the Linux kernel, for example, has built-in networking support. The next layer is the driver layer, which is where your hardware drivers—programs specially created to handle and communicate with your hardware—are being run; for performance reasons, drivers run without memory management or protection, which means a bug in a driver will probably crash your entire system (which is why blue screens are usually caused by faulty drivers). The third layer is the service layer. A service is a program that you can't interact with directly, but which provides functions such as audio support, network security, data safety, or maybe even a Web server. The top-most layer, finally, is the application layer, where most user applications are run. This layer usually has tons of features aimed at improving the system's stability and security, which means greater reliability at the cost of performance.

See also:


 * Application Programming Interface
 * Mac OS
 * Microsoft Windows
 * UNIX