ugh.book

(singke) #1
Error Messages and Error Checking, NOT! 33

Do I need to waste another 30 minutes retrieving the file from
Europe?
Of course, this is Unix.

It’s amazing. I’m sure this misfeature has bitten many people. There
are so many simple ways of avoiding this lossage: error reporting,
file version numbers, double checking that the user means to over-
write an existing file, etc. It’s like they have to work hard to create
this sort of lossage.

This bug strikes particularly hard those system administrators who use tar
to back up their systems. More than one sysadmin has put “tar xf...” into
the backup script instead of “tar cf...”


It’s an honest mistake. The tapes spin. Little does the sysadmin suspect that
tar is trying to read the specified files from the tape, instead of writing
them to the tape. Indeed, everything seems to be going as planned until
somebody actually needs to restore a file. Then comes the surprise: the
backups aren’t backups at all.


As a result of little or no error checking, a wide supply of “programmer’s
tools” give power users a wide array of choices for losing important infor-
mation.


Date: Sun, 4 Oct 1992 00:21:49 PDT
From: Pavel Curtis <[email protected]>
To: UNIX-HATERS
Subject: So many bastards to choose from...

I have this program, call it foo, that runs continuously on my
machine, providing a network service and checkpointing its (mas-
sive) internal state every 24 hours.

I cd to the directory containing the running version of this program
and, since this isn’t the development directory for the program, I’m
curious as to exactly what version of the code is running. The code is
maintained using RCS, so, naturally, I attempt to type:

% ident foo

to see what versions of what source files are included in the execut-
able. [Never mind that RCS is obviously the wrong thing or that the
way “ident” works is unbelievably barbaric; I have bigger fish to
fry...]
Free download pdf