UNIX

From Mac Guides

Jump to: navigation, search

UNIX in all of its various forms is one of the most popular operating systems in the world (behind Microsoft Windows). Indeed, Mac OS X is based off of a UNIX variant developed by Apple (and derived from NeXTSTEP) called Darwin.


Contents

Components

The Unix system is composed of several components that are normally packaged together. This unified system amounted to more than the sum of its parts. By including -- in addition to the "kernel" of an operating system (Mac OS X uses the XNU kernel) -- the development environment, libraries, documents, and the portable, modifiable source-code for all of these components, Unix was a self-contained software system. This was one of the key reasons it emerged into an important teaching and learning tool and had such a broad influence.

Inclusion of these components did not make the system large -- the original V7 Unix distribution, consisting of copies of all of the compiled binaries plus all of the source code and documentation occupied less than 10Mb, and arrived on a single 9-track magtape. The printed documentation was contained in two fairly thin books.

The names and filesystem location of the Unix components has changed substantially across the history of the system. Nonetheless, the V7 implementation is considered by many to have the canonical early structure:

  • Kernel -- originally found in /usr/sys, and composed of several sub-components:
    • conf -- originally found in /usr/sys/conf, and composed of configuration and machine-dependent parts, often including boot code
    • dev -- Device drivers (originally /usr/sys/dev) for control of hardware (and sometimes pseudo-hardware)
    • sys -- The "kernel" of the operating system, handling memory management, system calls, etc
    • h (or include) -- Header files, generally defining key interfaces within the system, and important system-specific invariables
  • Development Environment -- Most implementations of Unix contained a development environment sufficient to recreate the system from source code. The development environment included:
    • cc -- The C language compiler
    • as -- The machine-language assembler for the machine
    • ld -- The linking loader for combining object files
    • lib -- Libraries. Originally libc, the C runtime library, was the primary library, but there have always been additional libraries for (e.g.) floating-point emulation (libm) or a database implementation. V7 Unix introduced the first consistent "Standard I/O" library stdio. Later implementations multiplied the number and type of libraries significantly.
    • include -- Header files for software development, defining standard interfaces and system invariants
    • Other (secondary) languages -- V7 Unix contained a Fortran-77 compiler, and other versions and implementations have or now contain many other language compilers and toolsets.
    • ... and a number of other tools, including an object-code archive manager (ar), symbol-table lister, compiler-development tools (e.g. yacc), make, and debugging tools.
  • Commands -- Most Unix implementation make little distinction between commands (user-level programs) for system operation and maintenance (e.g. cron), commands of general utility (e.g. grep), and more general-purpose applications such as the text formatting and typesetting package. Nonetheless, some major categories are:
    • sh -- The Shell, the primary user-interface on Unix before window systems appeared, and the center of the command environment. To degrees that varied in different shell implementations, external programs (such as expr) were relied on by the shell.
    • Utilities -- the core of the Unix command set, including ls, grep, find and many others. This category could be subcategorized:
      • System utilities -- such as mkfs, fsck, and many others; and
      • User utilities -- passwd, kill, and others
    • Runoff -- Unix systems never lost their heritage as early document preperation and typesetting systems, and included many related programs such as 'troff, tbl, neqn, refer, plot
    • Communications -- early Unix systems contained no inter-system communication, but did include the inter-user communication programs mail and talk. V7 introduced the early inter-system communication system UUCP, and systems beginning with the BSD release included TCP/IP utilities
  • Documentation -- While not strictly part of the operating system, Unix was unique in its time for including all of its documentation online in machine-readable form. The documentation included:
    • man -- Manual pages for each command, library component, system call, header file, etc
    • doc -- Longer documents detailing major subsystems, such as the C language, troff, and other systems.


Other Notes

  • SCO group claims it owns all of the rights to UNIX, although that is currently in dispute with Novell (see SCO v. Novell on Wikipedia)

Current Unixes

See Also

External Links