The Unix Philosophy - Explained and Extended

Last updated — Oct 29, 2024
First published — Oct 29, 2024
#unix #bsd #gnu #linux #history

Unix philosophy. Software tools. Simple is beautiful. DOTADIW, KISS. Minimal, simple, clear. Modular, reusable, testable, quick. Free, unrestricted, customizable.

Article Collection

This article is part of the following series:

1. Unix

Table of Contents

Introduction

Unix and its most popular branches, BSD and GNU/Linux, run on everything and everywhere – on all top 500 supercomputers (GNU/Linux), all Intel CPUs after 2015 (MINIX), all mobile phones and tablets (Android, iOS, and GNU/Linux), all architectures (PC, POWER, ARM, RISC-V…), and basically everything else related to high-tech research and development. GNU/Linux even runs on 4.5% of all desktops.

As mentioned in the History of Unix, BSD, GNU, and Linux, Unix was originally created in the early 1970s by AT&T Bell Labs’ employees Ken Thompson and Dennis Ritchie, with support from Brian Kernighan, Joe Ossanna, Robert Morris, the department head Doug McIlroy, and few others.

Prior to inventing Unix, its authors were familiar with the earlier operating systems Compatible Time-Sharing System (CTSS), Berkeley Timesharing System, Multics, Incompatible Timesharing System (ITS), and TENEX, all of which contributed novel ideas to the field of operating systems.

The authors’ past experience, skill, and insight were channeled into Unix. From the beginning Unix was intended to be complete – it included the kernel and utilities needed to make the system useful. There were also programs to support Unix’ own development – text editors, compilers, debuggers, documentation tools, etc.

Through work on Unix it became clear that its authors had exceptional talent for straightforward expression of ideas. Their approach was simple, powerful, and general. Large parts of the implementation became consequences of the underlying design. Already in the 1973 paper The UNIX Time-Sharing System, Ritchie and Thompson stated: “[Unix] offers a number of features seldom found even in larger operating systems”.

As the design of Unix had its own merit, both related and unrelated to a particular implementation, it was gradually documented and named the Unix philosophy.

This article explains the Unix philosophy in more detail, gives additional examples and clarifications, and expands the usual description with additional insights.

Unix Philosophy

The Unix philosophy was explained by its authors and notable users using roughly the following sentences:

  • Make it easy to write, test, and run programs.

  • Avoid complex interfaces. Simple is beautiful.

  • Make each program Do One Thing And Do It Well (DOTADIW). Keep it Simple, Stupid (KISS).

  • Prefer economy and elegance of design due to size constraints (“salvation through suffering”).

  • Text is a universal interface. Write programs that handle text streams. Store data in flat text files.

  • Don’t insist on interactive input. Don’t require long or unnecessary input.

  • Don’t output unnecessary information. Avoid columnar or binary output.

  • Expect the output of every program to become input to another, unknown program. The power of a system comes more from the relationships among programs than from the programs themselves.

  • Build a prototype as soon as possible. Design and build software, even operating systems, to be testable quickly, ideally within weeks. Don’t hesitate to throw away and rebuild clumsy parts.

  • Choose portability and developer time over efficiency and machine time.

  • Write support tools to help with particular tasks. It doesn’t matter that they are not the main program.

Key Words

Summarizing the Wikipedia page on Unix philosophy further, it seems the following individual words describe it best:

  • Minimal, simple, compact, clear, readable, beautiful, lean

  • Separate, modular, extensible, composable

  • Reusable, repurposable

  • Quick, dynamic, agile

  • Text-based

General Characteristics

There are a couple other, powerful properties of Unix that are usually not expressly mentioned:

  1. The design of Unix is general and independent of computing power. Most of Unix commands and concepts that existed in 1970s are still in use today. Learning and practing Unix means investing in a durable skill that is not too easily changed or made obsolete by commercial companies’ interests.

  2. Unix is both powerful and free. That makes it particularly suitable for the extremes of the user spectrum – those that want a free system, and those that want the best system. This characteristic was best described by a saying “Unix makes simple things simple, hard things possible”.

  3. Unix authors have properly recognized that text is a universal inteface, even though already in the ’70s they had access to advanced technology such as voice synthesis. Similarly to the previous characteristic mentioned, text interestingly caters to the two extremes – the simplest, and the most efficient.

  4. Unix is a modular system that facilitates prototyping, experimentation, and reuse. This was best described by a saying “In Unix a program becomes successful when it gets used for a purpose or in combination which the original authors did not anticipate”.

  5. Unix’ combination of features and ease with which they are accessed is unparalleled. Development tools or specialized programs are available as readily as other system commands. Such an environment promotes a combination of active and passive users’ expansion of knowledge and skill over time.

  6. Thanks to free and open source licenses, BSD and GNU/Linux systems have guaranteed everyone the right to use, study, modify, and share the modified software. The free, unrestricted access to source code and usually its zero cost have removed all artificial barriers to both entry and achievement.

Article Collection

This article is part of the following series:

1. Unix

Automatic Links

The following links appear in the article:

1. History of Unix, BSD, GNU, and Linux - /unix-history/
2. The UNIX Time-Sharing System - https://dl.acm.org/doi/10.1145/361011.361061
3. AT&T Bell Labs - https://en.wikipedia.org/wiki/Bell_Labs
4. Berkeley Timesharing System - https://en.wikipedia.org/wiki/Berkeley_Timesharing_System
5. Brian Kernighan - https://en.wikipedia.org/wiki/Brian_Kernighan
6. Compatible Time-Sharing System (CTSS) - https://en.wikipedia.org/wiki/Compatible_Time-Sharing_System
7. Dennis Ritchie - https://en.wikipedia.org/wiki/Dennis_Ritchie
8. Doug McIlroy - https://en.wikipedia.org/wiki/Doug_McIlroy
9. Incompatible Timesharing System (ITS) - https://en.wikipedia.org/wiki/Incompatible_Timesharing_System
10. Joe Ossanna - https://en.wikipedia.org/wiki/Joe_Ossanna
11. Ken Thompson - https://en.wikipedia.org/wiki/Ken_Thompson
12. Kernel - https://en.wikipedia.org/wiki/Kernel_(operating_system)
13. Multics - https://en.wikipedia.org/wiki/Multics
14. Robert Morris - https://en.wikipedia.org/wiki/Robert_Morris_(cryptographer)
15. TENEX - https://en.wikipedia.org/wiki/TENEX_(operating_system)
16. Top 500 Supercomputers - https://en.wikipedia.org/wiki/TOP500
17. Unix Philosophy - https://en.wikipedia.org/wiki/Unix_Philosophy
18. 4.5% of All Desktops - https://www.tomshardware.com/software/linux/linux-market-share-approaching-45-for-first-time-could-hit-5-by-1q25