cancel
Showing results for 
Search instead for 
Did you mean: 

/var/tmp

cedrichiu
Frequent Advisor

/var/tmp

Just curious to ask is anyone know or aware that Linux will have automated script to purge or housekeep any files within.

Thanks

Regards,
4 REPLIES
Goran Koruga
Honored Contributor

Re: /var/tmp

Hello.

Not for /var/tmp, but for other dirs there is /lib/init/bootclean.sh in some distributions (i.e. Debian).

/var/tmp is preserved intentionally, it's declared as such in FHS.

Regards,
Goran
cedrichiu
Frequent Advisor

Re: /var/tmp

hi goran,

Are you aware of RHEL whether perform such operation ?

Goran Koruga
Honored Contributor

Re: /var/tmp

Hi.

I just did a quick check and I can't see it doing that.

Regards,
Goran
s. vater
Advisor

Re: /var/tmp

In RHEL there is a script called tmpwatch in /etc/cron.daily, which calls the tool tmpwatch

If you do "man tmpwatch" you can read, that tmpwatch recursively removes files which haven't been accessed for a given number of hours.

So look, which directories are configured in your file /etc/cron.daily/tmpwatch