Your favourite rm in /tmp (was: Your favourite UNIX-pipe (...))

Andy Sherman andys at ulysses.att.com
Wed Aug 22 22:58:55 AEST 1990


In article <7249 at star.cs.vu.nl> maart at cs.vu.nl (Maarten Litmaath) writes:
>``On the other hand, adding '-r' makes some sense, unless you'd really like to
>leave a subdirectory of /tmp around forever.''  Sic!
>Also:
>	$ rm -r . ..
>	rm: cannot remove `.' or `..'
>	rm: cannot remove `.' or `..'
>
>Whatever:
>
>	$ rm .??* .[!.]		# not portable to every UNIX version

Umm, be careful.  We had a mysterious problem here with X11, where
after about 3 days new clients could not be started up to
DISPLAY=unix:0.0.  I finally figured out that our /tmp cleanup script,
which gets rid of trash which has not been accessed for 3 days, was
removing the UNIX(R) domain socket from /tmp/x11-unix.  :-(.
(Hint, only trash real files, and then remove empty directories.)

Andy Sherman/AT&T Bell Laboratories/Murray Hill, NJ
AUDIBLE:  (201) 582-5928
READABLE: andys at ulysses.att.com  or att!ulysses!andys
What? Me speak for AT&T?  You must be joking!



More information about the Comp.unix.questions mailing list