Linux / UNIX Tech Support Forum
This is a discussion on /tmp clean directory automatically using tmpwatch within the Getting started tutorials forums, part of the Linux Getting Started category; is it ok to clean up all directory n files on /tmp? from someone who need a little space cheers, ...
|
|||||||
| Getting started tutorials So much to read, so little time! If that is your problem, we have solution. Read our FAQ and tutorials to help you cut through the clutter of information overload. Only members of "contributors" group can post new tutorials. Other members can just reply to thread. |
![]() |
|
|
LinkBack | Thread Tools | Display Modes |
|
|||
|
is it ok to clean up all directory n files on /tmp?
from someone who need a little space cheers, chikatambun |
| Sponsored Links | ||
|
|
|
||||
|
You may need to use a command called tmpwatch which removes files which haven’t been accessed for a period of time. Normally, it’s used to clean up directories which are used for temporary holding space such as /tmp.
Following code will remove all files/dirs from /tmp if they are not accessed in last 2 weeks (24 * 14 days = 336) Code:
tmpwatch --mtime --all 336 /tmp
__________________
Vivek Gite Linux Evangelist |
|
|||
|
I run tmpwatch command at root, and it's saying "command not found". I am running SuSe10. So, is there a package that I need to install before I can use tmpwatch on SuSe? Please help. Thanks a lot.
|
|
|||
|
Use yast/yast2 and install tmpwatch package / rpm
|
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to start Apache2 automatically at boot | satimis | Web servers | 2 | 03-02-2008 06:03 PM |
| run a command automatically after every 10 mins | vikas027 | Shell scripting | 1 | 01-11-2007 07:24 PM |
| Automatically restart unix daemon | raj | Linux software | 2 | 16-12-2006 11:29 AM |
| Dynamic DNS , should get updates automatically from DHCP | sonaikar | Linux software | 1 | 28-03-2005 12:14 PM |
| How to update DNS through DHCP automatically | sonaikar | Shell scripting | 1 | 16-03-2005 06:42 PM |