Gerard Beekmans gerard at
Sun Jun 11 12:14:27 PDT 2000

> > /tmp get cleaned out every time you boot. /var/tmp doesn't- but I'd 
> > be careful how you told it to be cleaned out- you'd hate to clean out 
> > a temp file that some program was using.
> According to my brand new LFS-Installation - it doesn't. Erasing a

Nope, you're right. Cleaning out /tmp and other directories every time
you boot the computer isn't part of any standard I'm awarey of.

> temp file which someone had open doesn't hurt - unless the file was
> closed and will still be needed.
> Btw. what command should be used to clean out tmp? rm -rf /tmp?
> Doesn't follow symlinks, does it? What about hardlinks?
> Hmm... wondering. Maybe rm -d, but that damages the filesystem.

I do it simply like this. At some point a cleandirs script is run
containing nothing more than:
/bin/rm -r /tmp; mkdir /tmp; chmod 1777 /tmp

and repeat these lines for /var/lock and /var/run

Gerard Beekmans

-*- If Linux doesn't have the solution, you have the wrong problem -*-
Mail archive:
IRC access: server: port: 6667 channel: #LFS
News Reader access:
Unsubscribe: email lfs-discuss-request at and put
"unsubscribe" (without the quotation marks) in the body of the message
(no subject is required)

More information about the lfs-dev mailing list