56
A Short History of UNIX (and what is it anyway?) Bob Eager History of UNIX 1

(and what is it anyway?) Bob Eager History of UNIX1

Embed Size (px)

Citation preview

  • Slide 1
  • (and what is it anyway?) Bob Eager History of UNIX1
  • Slide 2
  • An overview What is UNIX? loosely speaking, its a computer operating system operating systems are the programs that run computers examples of other operating systems are Windows, MacOS X, etc. Is it new? no, it first saw the light of day in the very early 1970s but it has changed and grown a lot since then Do many people use it? many millions! Can I run my Windows programs on it? sometimes, but thats not the point there are free alternatives History of UNIX2
  • Slide 3
  • UNIX is actually a trademark, although its used informally for: UNIX derivatives : FreeBSD, OpenBSD, NetBSD, etc. UNIX lookalikes (wannabes!): Linux systems in all their many incarnations real UNIX systems (i.e. those that can legally use the name): MacOS X (Apple) Solaris (Sun, now Oracle) HP-UX (Hewlett-Packard, or HP) AIX (IBM) History of UNIX3
  • Slide 4
  • so really, its merely a name applied to a specification of a system but since they all look similar, they get called UNIX! many versions available (mostly open source and free) user friendly (ish), but picky about its friends! although much more friendly (less hostile?) than it used to be for example, it now has a graphical user interface but the real power lies in the original command line originally, UNIX worked entirely at the command line and still does, if you want it that way real UNIX users mostly use the command line its very fast and productive heres a sample History of UNIX4
  • Slide 5
  • 5
  • Slide 6
  • UNIX features originally based around a textual command prompt now provides a graphical user interface in fact, many different graphical user interfaces take your pick some of the GUIs are excessively bloated! multi-user proper security makes it harder to do accidental damage... remote access via network (or hardwired) extensive networking support very rich set of features and applications So, how did it all start? History of UNIX6
  • Slide 7
  • Phase I the mini systems UNIX was internally developed by researchers at Bell Laboratories in the USA, in the late 1960s/early 1970s Ken Thompson, Dennis Ritchie, and others (picture soon) the initial system (First Edition) was on a spare PDP-7 (an 18-bit machine), and it was capable of building programs, and text processing this was between 1969 and 1971 by 1973, it had been rewritten in a new language called C. This had developed from a previous Bell Labs language called B - which was in turn based on a language called BCPL BCPL was developed at the University of Cambridge, UK, in the mid 1960s a completely typeless language, much more dangerous than C! in 1975, Sixth Edition UNIX was released to academic and research institutions - it arrived at Kent in July 1975, being the first system in England, if not the UK History of UNIX7
  • Slide 8
  • Kents copy of Sixth Edition arrived on three exchangeable disks of 2.4MB each: History of UNIX8
  • Slide 9
  • Heres the drive it fitted into: History of UNIX9
  • Slide 10
  • at Kent, Sixth Edition UNIX ran on a Digital Equipment Co (DEC) PDP-11/40; a 16 bit machine with 112kB of memory (costing tens of thousands of pounds) this supported 6 simultaneous users (most of the CS students at the time!) if you want to try running this version, a free licence is now available disk images and a PDP-11 simulator are available more later the Kent system ran for over 5 years before it was replaced by a VAX (see later) History of UNIX10
  • Slide 11
  • What was this PDP-11? made by the Digital Equipment Corporation of Massachusetts one of the most successful minicomputers of all time at one point, Kent probably had at least ten of them Bob owns four! 16 bits, memory from about 56kB up to 2MB or so (mostly at the low end) many possible peripherals some in big cabinets, some in deskside towers Now for some historical pictures. History of UNIX11
  • Slide 12
  • Hardware a PDP-11/40 CPU! This was in a full height rack (6 feet high), modules 19 inches widethis is just the CPU and memory History of UNIX12
  • Slide 13
  • More hardware! A big PDP-11 (actually, two), with Ritchie and Thompson using it: History of UNIX13 Dennis Ritchie Ken Thompson
  • Slide 14
  • In the previous picture, note the main I/O device the teletype; this ran at 10 characters/second, in upper case only: History of UNIX14
  • Slide 15
  • Students needed long term storage (as we use USB sticks today); the equivalent was the DECtape, storing 300kB or so of data: History of UNIX15
  • Slide 16
  • just about small enough to carry around in a (large) pocket History of UNIX16
  • Slide 17
  • a micro PDP-11! deskside size often used for word processing circa mid 1980s Bob has one of these... History of UNIX17
  • Slide 18
  • Seventh Edition UNIX appeared in 1979, and included various enhancements. It was a very tight squeeze except on more expensive PDP-11s (which supported an operating system area of 120kB instead of 56kB) at about the same time, an interesting derivative was UNIX 2.9BSD, a modified version developed by staff (and, largely, graduate students) at the University of California at Berkeley (the Berkeley System Distribution, or Berkeley Software Distribution) included networking again a very tight fit! Kent didnt have an expensive PDP-11, so never really used these a great deal it is said that only two important things came out of Berkeley at that time: BSD and the drug LSD and that this is no coincidence! History of UNIX18
  • Slide 19
  • Bell Labs also produced Mini-UNIX, which ran on really small PDP-11s and supported (effectively) just one user with some limitations (no real pipes, for example) (~1978) still on the PDP-11 series, but low end ones this was limited simply because it ran on machines with the minimum amount of memory, and no memory management hardware at all really just a feasibility project, although fun to look at but it was possible to do real work on it History of UNIX19
  • Slide 20
  • UNIX source code was not meant to be shown to undergraduates, but someone actually used it to teach operating systems this was a man called John Lions, at the University of New South Wales, Australia he went further, and in 1977 had the UNIX kernel source code made into a book, with his own companion volume as a commentary on the code probably one of the most interesting computer science/operating systems publications ever produced it was circulated internally in UNSW, and also sold to UNIX licensees unfortunately, Bell Labs/AT&T were not happy, and essentially had the books rationed to one per company/institution after the first print run was sold; by 1978 they were completely unavailable despite the books being under copyright, they must be the most frequently photocopied books in the whole area of computer science History of UNIX20
  • Slide 21
  • they were finally republished as a single volume in 1996 see link on website later History of UNIX21
  • Slide 22
  • UNIX was (and is) written mostly in the C language; heres a sample: /* * Switch to stack of the new process and set up his segmentation registers. */ retu(rp->p_addr); sureg(); /* * If the new process paused because it was swapped out, set the stack level to the * last call to savu(u_ssav). This means that the return which is executed * immediately after the call to aretu actually returns from the last routine which * did the savu. */ /* * You are not expected to understand this. */ if(rp->p_flag&SSWAP) { rp->p_flag =& ~SSWAP; aretu(u.u_ssav); } /* * The value returned here has many subtle implications. * See the newproc comments. */ return(1); History of UNIX22 comments code
  • Slide 23
  • yes, C looks a bit like Java, but pre-dates it by decades! the C look has been adopted by many other languages C is a very low level language, and allows the programmer to do pretty well anything even if its dangerous even if it makes no sense at all which is why its fun UNIX systems are written almost entirely in C a few hundred lines, at most, may be written in assembler, to interface with the hardware in other words, the innermost layer of our operating system kernel History of UNIX23
  • Slide 24
  • Phase II the 32 bit systems a major turning point was the transfer to the Digital Equipment VAX supermini systems (~1980) 32 bit machines with, to start with, 1MB of memory they were relatively affordable compared to the mainframes (also 32 bit) of the time, yet relatively powerful the VAX was to be a very influential machine for the next 15 years machine architecture based heavily on the PDP-11, so a lot of expertise from PDP-11s made the re-engineering of UNIX simpler than it might have been the VAX had proper hardware for virtual memory support (that on the PDP-11 was very limited) VAX stood for Virtual Address eXtension other machines were also tried, but the VAX dominated by far it was to drive UNIX forward for the next few years History of UNIX - Part 224
  • Slide 25
  • UNIX on the VAX was developed from Seventh Edition on the PDP-11, and was known as UNIX 32-V (it came straight from AT&T, previously Bell Labs) a Berkeley release followed shortly, to be known as 4.0BSD it was more popular than UNIX 32-V, which was fairly basic BSD became the de facto standard for VAX systems subsequent Berkeley releases were called 4.1BSD, 4.2BSD, 4.3BSD and, lastly, 4.4BSD (this is now publicly available as source code only, under the name 4.4BSD-Lite) you can get 4.xBSD, and run it on a VAX simulator if you want! a major BSD contribution was a new shell (command interpreter) based on the C language (the C shell) - more later History of UNIX - Part 225
  • Slide 26
  • the transfer to the VAX removed the architectural limitations on program size, etc., allowed proper virtual memory, and provided much increased computing power Kent acquired a VAX-11/780 (~1 million instructions/second) in 1979/80, and this was a significant computer science teaching system for some years; initially it was just called unix, later renamed to eagle it had approximately 300MB of disk space, and 1 MB of memory it supported 20-30 users, initially running UNIX-32V, then 4.0BSD, all the way through to 4.3BSD it was soon supplemented by a VAX-11/750 (~600 thousand instructions/second) for departmental use, also running 4.xBSD, called comet (well, the pesky students were using eagle far too much) these were eventually replaced at Kent by various other machines from various manufacturers, latterly from Sun, for example, and others History of UNIX - Part 226
  • Slide 27
  • The Kent VAX-11/780 (eagle) History of UNIX - Part 227 100MB disk tape drive glass teletype 30MB tapes
  • Slide 28
  • A VAX-11/750 (like comet) about 1.5 metres tall History of UNIX - Part 228 boot selector switch tape drive for software installation etc. (capacity 360kB)
  • Slide 29
  • UNIX development meanwhile continued at AT & T, culminating in 1983 in a different, incompatible, UNIX system known as System V there were various releases, the most common being release 4.2 (SVR4.2) in 1989, unifying contributions from System V and BSD (and other variants) these notably included the C shell, and the underlying support for it this was licensed to many vendors who added their own modifications and names (often ending in -ix!) meanwhile, other vendors had formed the X/Open Company (now known as The Open Group), who wanted to produce a single specification for an open system, based on UNIX in 1994, after a lot of messy politics, the UNIX trademark and the Single UNIX Specification were transferred to X/Open History of UNIX - Part 229
  • Slide 30
  • also in 1994, BSD4.4-Lite was released, eliminating all code still claimed to rely on the commercial version. This version was merely a collection of source code, and was not absolutely complete; it did however show what could be used, and what could not this is available if anyone wants to have a look, for interest in 1995, the UNIX branding programme was introduced; this still exists and is the basis of commercial systems note that any system creator can apply to have it certified as UNIX it must comply with the Single UNIX Specification, but need not use any particular set of source code e.g. MacOS X is loosely based on BSD Solaris (Sun, then Oracle) based more on System V but both are UNIX History of UNIX - Part 230
  • Slide 31
  • A GNU interlude before going into Phase III, lets backtrack a littlein time! well visit a group of hackers (programmers, not security breakers) at Massachusetts Institute of Technology (MIT) this would be from the early 1960s, all the way to 1981 or so they worked in a laid back, co-operative way, freely giving away any programs etc. that they wrote, and modifying others they were given things changed, and most of them left; those that remained had to use commercial software that they couldnt hack around, and they were no longer as free to give away their work either one person decided that this was wrong, and that software should be free and unencumbered a software socialist! History of UNIX - Part 231
  • Slide 32
  • his name was...Richard Stallman...! any similarity to School of Computing staff is entirely coincidental... Stallman resigned from MIT, and started a free software project free as in no strings attached rather than never any payment the plan was (eventually) to produce a complete UNIX-like system that wasnt UNIX, but would look the same the project was called GNU a recursive acronym standing for GNUs Not UNIX History of UNIX - Part 232 Stallman The GNU logo
  • Slide 33
  • the first product was going to be a C compiler, but it ended up being an editor program called EMACS one of the most powerful editors available, because its ridiculously extensible in it, you can: play Tetris, Towers of Hanoi check phases of the moon have a Java development environment manage files etc. it is programmed in a language called LISP, with a large library of stuff EMACS was also considered ridiculous because it was a very big program a common joke was that EMACS stood for Eight Megabytes And Continually Swapping another was You means that EMACS can edit files, too? History of UNIX - Part 233
  • Slide 34
  • History of UNIX34 Here is EMACS - running Tetris!
  • Slide 35
  • copies of EMACS are available on most platforms the ancestor of EMACS was an editor called TECO real masochists can try and use it its available for most platforms heres the TECO commands to create a file containing Hello World and display that line: *IHello World $$ *-1t$$ Hello World *ex$$ (computer output in red above) one can also, apparently, use it to solve differential equations for more information: http://en.wikipedia.org/wiki/TECO_%28text_editor%29 History of UNIX - Part 235
  • Slide 36
  • the next GNU product was the C (and C++) compiler, gcc lots of other programs (often quite feature-heavy) followed really, LOTS... see http://www.gnu.orghttp://www.gnu.org all the software was released under the GNU Public License (GPL) this said that you could do what you liked with it (even sell it) but must provide all source code (including anything you added) free of charge the license is still similar, but there are variants as it is sometimes too restrictive History of UNIX - Part 236
  • Slide 37
  • eventually the GNU Project produced an operating system (HURD), although it wasnt really suitable for general use it was slow and underdeveloped so GNU became: a software project looking for an operating system.... (although HURD is not quite dead....) the GNU Project is sponsored by a non-profit organisation called the Free Software Foundation which promotes the idea of free software: http://www.fsf.org Back to our story... History of UNIX - Part 237
  • Slide 38
  • Phase III the PC and beyond the earliest PC UNIX is probably PC-IX, developed by IBM for the PC/AT (~1984) an 80286 machine very few copies of this were sold; it was mainly an executive toy the 80286 had memory management hardware, but it was awful inferior to that on the old PDP-11/40 various vendors provided UNIX over the next few years, but most systems were expensive and needed expensive hardware UNIX still hadnt properly cracked the commercial market the eventual breakthrough was gradual, and came via free softwarethe catalyst was a system called: History of UNIX - Part 238 MINIX
  • Slide 39
  • in 1987, an academic named Andrew Tanenbaum wrote a book on Operating Systems, with a real, small, UNIX-like system (called Minix) as a working example; available free to students and educators all it needed was an IBM PC (or compatible) with two 5.25 floppy drives (360kB each) but it ran on other hardware too Bob used an IBM PC Portable he had lying around: the system was immensely popular, and versions were developed for other hardware of the time such as the Atari ST and the Apple Macintosh (not the Mac we know today) all versions came with complete source code, and the ability to modify and rebuild any part of the system History of UNIX - Part 239
  • Slide 40
  • History of UNIX - Part 2 40 Apple Macintosh Atari ST
  • Slide 41