Disk Partitions and Backups 227 swapped out, no doubt). Spiffy. So I used that king of high perfor- mance featureful debugging tools (adb) to goose maxslp up to some- thing more appropriate (like 2,000,000,000). Damnit, if the system is not out of memory, then it shouldn’t page or swap! Period! Why doesn’t someone tell Sun that their workstations aren’t Vaxen with 2MB of RAM, it’s not 1983, and there is absolutely nothing to be gained by summarily paging out stuff that you don’t have to just so you have a lot of empty memory lying around? What’s that, you say? Oh, right, I forgot—Sun wants their brand new spiffy fast work- stations to feel like a VAX 11/750 with 2MB of RAM and a load fac- tor of 6. Nothing like nostalgia, is there? feh. Disk Partitions and Backups Disk space management is a chore on all types of computer systems on Unix, it’s a Herculean task. Before loading Unix onto your disk, you must decide upon a space allocation for each of Unix’s partitions. Unix pretends your disk drive is a collection of smaller disks (each containing a complete file system), as opposed to other systems like TOPS-20, which let you cre- ate a larger logical disk out of a collection of smaller physical disks. Every alleged feature of disk partitions is really there to mask some bug or misdesign. For example, disk partitions allow you to dump or not dump certain sections of the disk without needing to dump the whole disk. But this “feature” is only needed because the dump program can only dump a complete file system. Disk partitions are touted as hard disk quotas that limit the amount of space a runaway process or user can use up before his program halts. This “feature” masks a deficient file system that provides no facilities for placing disk quota limits on directories or portions of a file system. These “features” engender further bugs and problems, which, not surpris- ingly, require a sysadmin (and additional, recurring costs) to fix. Unix commonly fails when a program or user fills up the /tmp directory, thus causing most other processes that require temporary disk space to fail. Most Unix programs don’t check whether writes to disk complete success- fully instead, they just proceed merrily along, writing your email to a full disk. In comes the sysadmin, who “solves” the problem by rebooting the
228 System Administration system because the boot process will clear out all the crud that accumulated in the /tmp directory. So now you know why the boot process cleans out /tmp. Making a “large” partition containing the /tmp directory, for the times when a program may actually need all that space to work properly, just moves the problem around: it doesn’t solve anything. It’s a shell game. That space so carefully reserved in the partition for the one or two times it’s needed can't be used for things such as user files that are in another par- tition. It sits idle most of the time. Hey, disks are cheap these days. But no matter how big you make /tmp, a user will want to sort a file that requires a a temporary file 36 bytes larger than the /tmp partition size. What can you do? Get your costly sysadmin to dump your whole system to tape (while it is single-user, of course), then repartition your disk to make /tmp bigger (and something else smaller, unless buying an additional disk), and then reload the whole system from tape. More downtime, more cost. The swap partition is another fixed size chunk of disk that frequently turns out not to be large enough. In the old days, when disks were small, and fast disks were much more expensive than slow ones, it made sense to put the entire swap partition on a single fast, small drive. But it no longer makes sense to have the swap size be a fixed size. Adding a new program (espe- cially an X program!) to your system often throws a system over the swap space limit. Does Unix get unhappy when it runs out of swap space? Does a baby cry when it finishes its chocolate milk and wants more? When a Unix system runs out of swap space, it gets cranky. It kills processes without warning. Windows on your workstation vanish without a trace. The system gives up the ghost and panics. Want to fix the vanishing process trick prob- lem by increasing swap space? Get your costly sysadmin to dump your whole system to tape (while it is single-user, of course), then repartition your disk to make /swap bigger, and then reload the whole system from tape. More downtime, more cost. (Sound familar?) The problem of fixed size disk partitions still hurts less now that gigabyte disks are standard equipment. The manufacturers ship machines with disk partitions large enough to avoid problems. It’s a relatively expensive solu- tion, but much easier to implement than fixing Unix. Some Unix vendors now swap to the file system, as well as to a swap partition, which helps a bit, though swapping to the file system is much slower. So Unix does progress a little. Some Unix venders do it right, and let the paging system dynamically eat into the filesystem up to a fixed limit. Others do it wrong and insist on a fixed file for swapping, which is more flexible than refor- matting the disk to change swap space but inherits all the other problems. It also wreacks havoc with incremental nightly backups when using dump,
Previous Page Next Page