ugh.book

(singke) #1

230 System Administration


disk pack.) According to Andy Tannenbaum, “If Unix crapped on your
rk05, you’d write to Dennis for another.”)^1

Most Unix systems come equipped with a special partition called the
“swap partition” that is used for virtual memory. Early Unix didn’t use the
file system for swapping because the Unix file system was too slow. The
problem with having a swap partition is that the partition is either too
small, and your Unix craps out when you try to work on problems that are
too large, or the swap partition is too large, and you waste space for the
99% of the time that you aren’t running 800-megabyte quantum field
dynamics simulations.

There are two simple rules that should be obeyed when partitioning disks:^2


  1. Partitions must not overlap.

  2. Each partition must be allocated for only one purpose.


Otherwise, Unix will act like an S&L and start loaning out the same disk
space to several different users at once. When more than one user uses
“their” disk space, disaster will result. In 1985, the MIT Media Lab had a
large VAX system with six large disk drives and over 64 megabytes of
memory. They noticed that the “c” partition on disk #2 was unused and
gave Unix permission to use that partition for swapping.

A few weeks later the VAX crashed with a system panic. A day or two
after that, somebody who had stored some files on disk #2 reported file cor-
ruption. A day later, the VAX crashed again.

The system administrators (a group of three undergraduates) eventually
discovered that the “c” partition on disk #2 overlapped with another parti-
tion on disk #2 that stored user files.

This error lay dormant because the VAX had so much memory that swap-
ping was rare. Only after a new person started working on a large image-
processing project, requiring lots of memory, did the VAX swap to the “c”
partition on disk #2. When it did, it corrupted the file system—usually
resulting in a panic.

(^1) Andy Tannenbaum, “Politics of UNIX,” Washington, DC USENIX Conference,



  1. (Reprinted from a reference in Life With Unix, p. 13)


(^2) Indeed, there are so many problems with partitioning in Unix that at least one ven-
dor (NeXT, Inc.) recommends that disks be equipped with only a single partition.
This is probably because NeXT’s Mach kernel can swap to the Unix file system,
rather than requiring a special preallocated space on the system’s hard disk.

Free download pdf