[net.news] squish

smk (12/26/82)

	A couple of hints on using squish.  On 4.1, don't try to squish
directories where daemons are running.  For instance, comsat starts
off by doing a
chdir("/usr/spool/mail");
If /usr/spool/mail is squished, comsat will point to a directory in limbo.
Furthermore, the old /usr/spool/mail is unlinked successfully, but
as with any UNIX file, it doesn't disappear because comsat had it open.
A fsck will find an unreferenced directory (which is the old /usr/spool/mail
and can be thrown away).  As long as you throw away the unreferenced directory,
everything is OK.  The new /usr/spool/mail is still created and is
correct, but a new comsat should be started to deal with the real (new)
/usr/spool/mail.

The moral is that squish should be run by rc before any daemons are
started.  Otherwise, you should be very careful of running squish.
One suggestion may be to mount the affected file system on another
path temporarily and do the squish.

kiessig (12/28/82)

	I, too, don't understand all this fuss about a squish program.
Recursive cp will do the trick very nicely, as follows:

cd dir_to_squish/..
mkdir temp_dir
cp -rl dir_to_squish/. temp_dir
rm -rf dir_to_squish
mv temp_dir dir_to_squish

	The "-rl" in cp says to copy r-ecursively, l-inking as you go
(as opposed to copying).  This preserves modes, owners, s-u/g-id bits,
etc.  About all that gets messed up is file "ctime"s.

Rick Kiessig
{sri-unix,harpo,megatest,dsd}!fortune!kiessig

P.S. Oops - you will have to change the mode and owner of temp_dir
     to be that of dir_to_squish (before or after the "mv").