SSD Nodes Learn Hosting plans →
How to do am Matt ConnorBy Matt Connor

VPS Come From Mainframe How?

Trace your VPS history from CTSS and Multics to Unix, IBM VM/370, Xen, and KVM, and see why time-sharing, isolation, and hourly billing still remain.

Wey your VPS come from

The history of computing from mainframe reach cloud na one idea wey dey become cheaper. That idea na time-sharing: make plenty people use one expensive machine for the same time, then give each person private view of am. Dem invent am around 1960 because computer cost pass the people wey dey use am. Every part of the VPS wey you rent today na for that problem dem build am: the isolation between users, the scheduler wey dey share CPU time, the hypervisor, and the bill wey dey count hours. The problem never go away. Hardware don cheap, so one slice wey once need research grant now cost few dollars every month.

1959 to 1961: why dem invent time-sharing

Plenty computers for the 1950s dey run batch, though MIT's Whirlwind dey work interactively in real time for 1951. With batch processing, you go punch your program for cards, give the deck to operator, then come back later to collect printout. If you mistype one character, e fit cost you one day. The machine remain busy, and na the main point be that, because machine like IBM 7090 cost millions of dollars, while the time wey people spend dey wait for am no dey show for any invoice.

For January 1959, John McCarthy make the opposite argument for one memo wey e write for MIT. The machine suppose wait for the person. Christopher Strachey describe one form of time-sharing for UNESCO conference that same year, though wetin e mean na one programmer dey debug while other jobs dey run, no be plenty people dey type at the same time. When McCarthy talk for MIT's centennial for 1961, e go further: computing fit become public utility, with usage measured like electricity.

The objection that time na say time-sharing dey waste the machine. Switching between users dey use cycles, and cycles na the expensive part. The objection correct, but e stop to matter because cost of one cycle fall for sixty years, while cost of one hour of human attention no fall.

Wetín CTSS need invent

Fernando Corbató group for MIT Computation Center build Compatible Time-Sharing System (CTSS) to settle the argument. Dem first demonstrate am for November 1961 on IBM 709, e dey serve four users, and e dey swap each user work go im own magnetic tape drive. “Compatible” mean say the machine still fit run the old batch system underneath, because nobody go buy computer wey only fit do the new thing.

Four users na small number. But the list of problems wey dem need solve to reach there no small, and na the same list your kernel dey work through right now. CTSS need scheduler, so one long job no go freeze every other terminal. E need memory protection, so if program crash, na one user e go affect instead of the whole system. E need storage wey go survive logout, na why CTSS get one of the first file systems wey modern user fit recognise. And e need passwords, so one user no fit read another user files.

Rename those parts and you don get Linux box. The scheduler na EEVDF, wey replace CFS for Linux 6.6. Memory protection na MMU (memory management unit), wey give each process im own virtual address space. Storage wey survive logout na your home directory. The password file still dey called /etc/passwd.

Multics and computer utility

MIT next system suppose to be the utility wey McCarthy describe. Project MAC start for 1963, sign contract for one General Electric GE-645 for August 1964, and publish the first Multics papers for 1965. The name explain the idea: Multiplexed Information and Computing Service. Service, as in something wey you buy by the hour.

Multics take much longer than dem plan. Prototype GE-645 machines reach MIT and Bell Labs for January 1967. Bell Labs comot from the project for April 1969. Multics open to MIT Information Processing Center customers for October 1969, and e then run for production on original hardware somewhere for thirty-one years. The last site wey run original Multics hardware, for the Canadian Department of National Defence for Halifax, Nova Scotia, shut down on 30 October 2000. Multics still dey run today on simulated hardware, including Gold Hill, where users fit request accounts.

People often classify Multics as failure because e arrive late and run slow. But the vocabulary show another thing. E give us hierarchical file system, where directories fit dey inside other directories; access control list for every file; segmented virtual memory wey let program address file as if na memory; and protection rings wey rank code based on how much trust e get. Rings still dey inside the silicon for front of you. Honeywell Multics hardware provide eight rings, numbered 0 to 7. The most privileged code dey for ring 0, while ordinary user programs dey for ring 4. Inner rings also support protected subsystems. Intel's x86 keep the name and keep ring 0 for the kernel, but reduce the number to four. Na why user code for your VPS dey run for ring 3. Hardware virtualisation later add one mode underneath ring 0 for the hypervisor. People informally dey call am ring -1.

Unix: time-sharing for machine wey you fit afford

After Ken Thompson comot from Multics, e remain for Bell Labs without system wey e really wan use. For 1969, e start much smaller system for one discarded PDP-7. The first Unix Programmer's Manual get date for November 1971. By that time, the work don move go PDP-11. For 1973, Thompson and Dennis Ritchie rewrite the kernel for C, so the system fit move go new hardware without people writing am again by hand.

Na why you dey type inside descendant of Unix, no be descendant of Multics. Multics need hardware wey dem build specially for Multics. Unix run for anything wey cheap and dey available, and that one turn out to be the feature wey decide everything.

"The UNIX Time-Sharing System" by Ritchie and Thompson appear for Communications of the ACM for July 1974. The paper describe your VPS: processes, one hierarchical file system, files as plain byte streams, fork, users and groups with permission bits, and shell wey be ordinary program instead of part of the kernel. Fifty-two years later, dem don extend that interface, but dem never replace am.

Mainframe really run virtual machines for 1972?

Yes, and na this part of the story wey plenty people dey miss. While MIT dey build Multics, IBM's Cambridge Scientific Center attack the same goal from the other end. Instead make one operating system serve many users, Robert Creasy and Les Comeau build one control program wey give each user complete simulated computer. CP-40 enter production for January 1967. Every user get virtual System/360 and run small single-user operating system, CMS, inside am.

CP-67 for System/360-67 finish for the later part of 1967 and become available to Model 67 users for July 1968, and IBM announce VM/370 on 2 August 1972. Na commercial hypervisor be that, wey dem sell to customers wey pay, fifty-four years ago. One control program multiplex the real hardware, and guest operating systems run unmodified inside virtual machines wey believe say dem own the machine.

The theory show up two years later, for the same July 1974 issue of Communications of the ACM wey carry the Unix paper. Gerald Popek and Robert Goldberg's "Formal Requirements for Virtualizable Third Generation Architectures" explain sufficient condition for processor to support virtualization. The main rule short. Every sensitive instruction must be privileged, and e must trap when guest execute am outside kernel mode, so the hypervisor fit take control and answer with that guest's own private version of the state. Sensitive instructions control resource allocation or behave differently depending on machine mode or memory mapping. Ordinary arithmetic and memory operations execute directly on the hardware. Dem dey call this trap and emulate. IBM hardware follow the rule.

Wetin make minicomputer break the old model

DEC introduce PDP-8 for 1965 for about $18,000 in 1965 dollars. Na the first minicomputer wey price dey below $20,000, and e later sell pass 50,000 units. Microprocessor come push the price down again. Once department fit buy im own machine, and later when one person fit buy one, sharing one central computer look like problem wey dem don solve and no need solve again. Through the 1980s and 1990s, computing move from central systems go individual desks and racks of small x86 servers.

The waste come back for another form. One application per server easy to understand, but e leave most of the hardware idle while dem still pay full power and rack space cost. Na the CTSS problem again, but for new scale. This time, na room and electricity be the expensive resources, no be processor. The answer still be the old answer. Share the machine.

Why x86 hard to virtualise?

Because x86 break Popek and Goldberg rule. For 9th USENIX Security Symposium for August 2000, John Scott Robin and Cynthia Irvine check the Pentium instruction set and find seventeen sensitive instructions wey fit execute for user mode without trapping. popf na the standard example. If you run am for user mode, processor go quietly ignore the bits wey program no get permission to set, instead of trapping. So hypervisor wey depend on trap and emulate no go ever know say guest try do am.

Two solutions show up before dem fix the hardware. VMware, wey dem found for 1998 from Stanford's Disco research, inspect guest kernel code and rewrite the awkward instructions before dem execute. Dem call this technique binary translation. Xen, from University of Cambridge Computer Laboratory, change the guest instead. The paper "Xen and the Art of Virtualization", wey dem present for SOSP for October 2003, describe paravirtualisation: modified guest kernel dey call the hypervisor on purpose instead of running instructions wey hypervisor no fit intercept.

Later, dem fix the hardware, the same way IBM fix am for the 1960s. Intel ship VT-x for two Pentium 4 models on 14 November 2005, and AMD ship AMD-V for May 2006. Both add processor mode wey dey below the guest kernel mode. This one make guest run im own kernel for full speed, while hypervisor still control the events wey guest request. E make hypervisor small enough to run inside ordinary operating system. Avi Kivity's KVM for Qumranet do exactly that: e turn Linux kernel itself into the hypervisor. KVM merge into Linux 2.6.20, wey release for February 2007.

How VPS take its name

Two lines join together for early 2000s. One na full virtual machine for x86, where guest dey boot its own kernel. The other na operating-system-level virtualisation: one shared Linux kernel wey dem divide into separate environments, and each get its own root user plus its own process table. Linux-VServer and SWsoft's Virtuozzo offer this model, and SWsoft release part of Virtuozzo as the open-source OpenVZ for 2005. The phrase "virtual private server" come from this side of the family, based on the idea of virtual private network.

Amazon turn the rental into an API call. S3 launch on 14 March 2006, and EC2 open as limited public beta on 25 August 2006 with one instance type, running on Xen. Buying compute stop being contract with service bureau and become request wey fit return within one minute.

Both lines still dey, and the split still decide wetin you fit do with the server wey you rent. KVM VPS dey boot its own kernel, so you fit load kernel modules and, when the host expose the required virtualisation features, run hypervisor inside your VPS. Container-based plan share the host kernel instead of booting its own. Sixty years of history dey behind that one line for pricing page, na why e make sense to understand how VPS, VM and VPC different before you choose one.

Wetin change from mainframe reach your VPS, and wetin no change

Four things change. The machine no dey your building again. The terminal na program instead of furniture. The unit wey you rent na complete computer with e own kernel, instead of account for another person operating system. And the price drop reach point wey payment na card transaction instead of procurement process.

The mechanism no change at all.

  • Your ssh session na time-sharing terminal. You get login and shell, and scheduler decide when your process go run next.
  • Hardware still dey enforce isolation. The MMU and processor privilege levels dey do the work, exactly as CP-40 need dem for 1967.
  • You still dey pay for part of a machine based on elapsed time, like service bureaus dey charge for connect hours.
  • You still dey feel the other tenants. When host get more workload than e capacity, your guest go wait for physical CPU, and Linux report this wait as CPU steal time from noisy neighbour.

That last point na the honest summary of the whole history. Sharing one machine na trade-off. Dem accept am for 1961 because computer cost pass the people, and dem accept am for 2026 because server wey dey run at ten percent of e capacity na money wey dey burn. If you prefer to dey on the operator side of that trade-off, running Proxmox on hardware wey you own go give you the hypervisor together with the operator problems.

Keep the ratio for mind. CTSS serve four users on machine wey fill one room. Your VPS, for few dollars every month in 2026, na far better computer pass the one wey Corbató team dey ration, and na only you get am. The reason you fit rent am at all na sixty-five-year-old idea wey finally meet cheap hardware. If you dey decide wetin to put for am, start with wetin VPS actually give you and then wetin people dey run for one.

FAQ

Wetin be the first time-sharing computer system?

CTSS, wey dem call Compatible Time-Sharing System, na one of the first general-purpose time-sharing systems. Fernando Corbató group for MIT Computation Center build am. Dem first demonstrate am for November 1961 on IBM 709, and e serve four users. Each user dey swap go separate tape drive. CTSS start to serve MIT users for May 1963. Dartmouth Time-Sharing System follow on 1 May 1964. E run BASIC programs for two terminals at the same time and return correct answers to both.

Dem really invent virtual machines for the 1960s?

Yes. IBM Cambridge Scientific Center put CP-40 for production for January 1967. E give each user complete virtual System/360 with CMS operating system running inside am. Dem complete CP-67 for System/360-67 for the fall of 1967, and e become available to Model 67 users for July 1968. IBM announce VM/370 on 2 August 1972. Those ones na real hypervisors wey dey run guest operating systems without modification. Dem sell VM/370 commercially, decades before x86 hardware fit do the same thing.

Why x86 hard to virtualise when mainframes no hard?

Popek and Goldberg sufficient condition for 1974 talk say every sensitive instruction must be privileged. E must trap when guest run am outside kernel mode. Normal arithmetic and memory operations fit execute directly. x86 no follow this rule. Robin and Irvine count seventeen sensitive Pentium instructions wey fit execute for user mode without trapping. Because of this, classic trap-and-emulate hypervisor no go see dem, and popf na the usual example. VMware work around the problem with binary translation, while Xen use paravirtualisation. This continue until Intel VT-x for November 2005 and AMD-V for May 2006 add hardware mode for the hypervisor.

Renting VPS na the same thing as getting time-sharing account?

The billing model and isolation problem na the same. But the unit different. Time-sharing user get account for operating system wey everybody dey share, so administrator na person for computer centre. KVM VPS give you virtual machine with your own kernel and your own root account, so you be the administrator. Container-based VPS dey between the two, because e share host kernel but still give you root inside your own environment.

Dis article help you?

#history#computing#virtualization#mainframe#vps