[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [K12OSN] scripting trash removal

I did consider that, But I have a backupPC running with 9 days of incrimental backups and 2 full backups, so it isn't anything I couldn;t pull back in two shakes (and the backup happens before the dump). Even though they are told to clear their cache and dump their trash, I still get trouble tickets in my IRM ticket system that are the result of wacking their quota because of cache and trash.
Mike Ely wrote:

Toshio Kuratomi wrote:

On Fri, 2006-01-27 at 13:22 -0500, Mark Gumprecht wrote:

Dave was nice to send me this for clearing cache

for x in `ls /home`; do
echo "Doing $x ..."
cd /home/${x}/.mozilla/firefox/*.default/Cache
rm -Rf *

Ok that works just fine. Soooo, If that works for cache, with a little mod like this

for x in `ls /home`; do
echo "Doing $x ..."
cd /home/${x}/.Trash
rm -Rf *

You've probably already considered this but just in case:

Deleting cache files should be relatively transparent to an end-user (It
affects their performance somewhat but they shouldn't lose data.)
Deleting the contents on .Trash is unexpectedly circumventing the way
the Trash works (to be able to recover deleted files.)

If you hadn't already considered that, you might want to implement aging
of the Trash (like the tmpwatch program for /tmp) or user quotas (so the
user has to empty the Trash themselves in order to stay under quota.)


That's a good point. However, the vast majority of users do not use their Trash (or Recycle Bin) correctly at all. I'm sure many in here can recount numerous times where they found a user with a couple of gigs of general rubbish in their trash. Most people delete stuff and never ever empty. Yeah, there was that one lady who freaked when I emptied her trash (it's almost a nervous habit for me when sitting down at a desktop). Apparently she was actually using it as a folder to store stuff. D'oh!


K12OSN mailing list
K12OSN redhat com
For more info see <http://www.k12os.org>

Mark Gumprecht
Data Systems Specialist
Unity, ME
gumprechtm msad3 org

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]