.\" mk slides.show .de IT .if !"\\$1"" .ds BX \\$1 .if "\\$1"" .ds BX \(bu .IP \\*(BX .. .de SS .ds CH \s+2\f3\\$1\fP\s-2 .bp .LP .na .. .nr PO 0.5i .nr HM 1i .nr PS 12 .nr VS 14p .nr PD 6p .nr LL 6.5i .ds CH " .pl 15c .ds RF " .TL Intro to Plan 9 .ps -2 The future of Unix like it's authors dreamed it .ps .AU Uriel .AI uriel AT binarydream.org .PP .SS "Origins Where? Bell Labs: Invented the transistor, the laser, discovered the microwave background radiation... Computing Sciences Research Center: Ken Thompson, Rob Pike, Dennis Ritchie, Brian Kernighan, Tom Duff, Doug McIlroy, Bjarne Stroustrup, and many others... The same team that developed: .IT Unix .IT C, AWK, Newsqueak programming languages .IT Troff typesetting system .IT First window system for Unix .IT First chess playing machine that archived Master level .IT The Death Star .SS "When? Started in the late 80's. First researchers start to use it as their exclusive work environment in 1989. Four public releases .IT 1st Ed (1993): First public release, only to universities. .IT 2nd Ed (1995): First general public release, full UTF-8 support, dumpfs and and APE, ... .IT 3rd Ed (2000): First free release including source code; Brazil, rio/draw, plumbing, replaced Alef with libthread, ... .IT 4th Ed (2002): Approved Open Source license, 9p2k, secstore/factotum, fossil/venti, ... .IT Still in active development, daily ISO builds, continuous updates delivered over 9p/replica. .SS "Why? .ps +1 .cu .ce "Not only is UNIX dead, it's starting to smell really bad." .ce -- Rob Pike circa 1991 .ps Unix starts to show its age .IT Designed as an old fashion timesharing system, has trouble adapting to a world of networks and workstations. .IT The advantages of timesharing were lost in the switch to workstations: Centralized management and administration, amortization of costs and resources. .SS "Unix baggage Unix accumulated a long list of poorly integrated "features": .IT Everything is a file... except when it's not; and not all files are made equal either. .IT root and suid/guid .IT tty and typewriter oriented interface .IT symlinks .IT ioctl .IT sockets and select .IT dump .IT NFS .IT X Window system .LP Plan 9 lacks all this "features"... because it doesn't need them. .SS "The Plan 9 solution Back to the Unix roots .IT Simplicity .IT Clarity .IT Generality .LP Three major concepts .IT Resources are named and accessed like files in a hierarchical file system. .IT The 9P protocol for accessing resources independently of their location in the network. .IT The disjoint hierarchies provided by different services are joined together into a single private hierarchical file name space. .SS "System organization To build a UNIX out of a lot of little systems, not a system out of a lot of little UNIXes A typical Plan 9 network is made up of .IT Terminals .IT CPU servers .IT File storage servers .\" TODO (maybe graphic) .\".PS < network.pic .SS "Everything is a file system .IT Processes .IT Environment variables .IT Network .IT Console .IT Graphics .IT Hardware devices .IT Miscellaneous file systems: ftpfs, webfs, wikifs, cdfs, upas/fs(email), .IT and many others... .SS "9P Lightweight network filesystem.. .IT Not block oriented, byte oriented .IT Minimalistic and lightweight: Only seven core operations .IT Only depends on a reliable transport layer(has been implemented over TCP, IL, shared memory, PCI bus, ...) .IT Encompassing: used both for local and remote access .SS "Private namespaces Imagine using a programming language where all variables where global... \...that is how Plan 9 users feel like when they have to use Unix. .SS "Security .IT No root or suid/guid .IT Simplified kerberos-like authentication system .IT Namespaces provide elegant and effective isolation mechanism(A la BSD jails but as part of the system design) .IT Secstore/factotum .SS " Other System features .IT Full UTF-8 support, UTF-8 was invented for Plan 9 by Ken Thomson .IT Excellent portability: .IT - Extremely portable codebase. Ported so far to MC68020, SPARC, i386, i960, Alpha, PowerPC, ARM, AMD29000, MIPS, and others; and new ports are easy to do. - Transparent handling of various architectures binaries and cross compilation - All protocols and formats avoid any endianess ambiguities .IT Solid SMP support since day one. .SS "System components .IT fossil: Automatic filesystem archival .IT venti: Checksum based storage system .IT factotum/secstore: Authentication system .IT upas: Email system .IT ndb: Network database .SS "Applications .IT Rc shell .IT Rio and 8½ window systems .IT Sam text editor .IT Acme user interface for programmers .IT Plumber: intelligent pipes .IT Portable cross-compiler suite, Ken's C compilers \" DEMO .IT Acid debugger .IT Mk make replacement .IT APE PoSix environment .SS "Examples NAT? Just import /net from the gateway: .P1 import gatewayhost /net .P2 Remote debugging? Just import /proc from remote host: .P1 import remotehost /proc .P2 and use acid as usual .\" TODO history/yesterday .SS "Myths .IT Not production ready: Used at Bell Labs by over one hundred researchers over the last 17 years .IT Not Open Source/Free Software: OSI approved license and accepted by RMS/FSF as Free Software .IT Lack of applications: APE, vnc, ssh, ... .IT Not finished: Many components have not changed in a long time, can be considered finished, but there are always areas were more research is done .SS "If it's so great, why is it not more popular? .IT Originally kept internally at Bell Labs, only real aim was to fulfill the needs of it's developers, not world domination. .IT Parts of AT&T (mis)management was weary of repeating the Unix experienc. .IT Unix was "good enough"; and it's simple design made very easy to hack any new features even if those were no integrated properly .IT Inertia: Plan 9 broke with many Unix concepts and flaws that many people(and software) had come to depend on: (sym)links, suid, curses, etc. .IT Standards mace: approximately 90% of the time spent in Plan 9 was directly or indirectly related to implementation of various standards .SS "Running it Daily built ISO image based in the latest sources that can work both as installer and as "demo" self bootable CD. There is a Xen port of Plan 9 that can allow it to run side by side other operating systems Plan 9 (mostly) works under VMWare and images are provided that are setup out of the box. .SS "Public servers/drawterm Public servers in Japan and Europe with free accounts Tokyo Inferno and Plan 9 Users Group: http://www.tip9ug.jp Various European public servers are being setup, if you are interested we will setup an account for you and notify you as soon as the servers are accessible. Login from Unix/Windows/MacOS X using drawterm. .SS "Related projects .IT Plan9port: port of Plan 9 userspace to Unix, trying to emulate the Plan 9 environment as much as possible .IT v9fs: Add 9p support to the Linux kernel http://v9fs.sf.net .IT dtLinux: Bootable linux distribution including plan9port and drawterm(soon v9fs too) .SS "Inferno/Limbo Based in the ideas researched in Plan 9 but taking a more radical approach .IT Limbo: New GC concurrent language while keeping the C philosophy .IT Dis: Virtual machine designed for portability and JIT .SS "More information .P1 http://plan9.bell-labs.com/plan9/ .P2 Books .IT The Unix programming environment: Rob Pike and Brian Kernighan .IT The practice of programming: Rob pike and Brian Kernighan