Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the 'Free drive space by deleting miscellaneous excess files' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
Free drive space by deleting miscellaneous excess files
Authored by: cjmilne on Oct 31, '03 12:18:14PM

Of potential concern with this hint is if one of the directories is older then the mtime chosen, the directory will be deleted along with the files. Some programs won't handle this cleanly & may end up causing headaches. There's probably a find flag that can avoid this problem, or perhaps cd into the directory in question using the script then perform the find on the local directory :
cd /var/spool/clientmqueue
/usr/bin/find . -mtime +7 -delete
this works OK for me ('delete' has some restrictions on what it can & can't delete - it doesn't like paths with '/' & '.' in them) but you'd want to make SURE you were in the right directory.



[ Reply to This | # ]
Free drive space by deleting miscellaneous excess files
Authored by: LC on Jan 15, '04 10:00:53PM
To clean files, at least one should restrict find scope using -type f

[ Reply to This | # ]
Free drive space by deleting miscellaneous excess files
Authored by: tb on Apr 05, '05 10:23:48PM

If you are using IP printing, then be careful that you do not delete /var/spool/cups/tmp using this hint. Files are created in this subdirectory while printing, but if it is not present, tmp is not created when needed (at least with 10.2.8).

Use "-type f" as suggested.



[ Reply to This | # ]