[16631] in Athena Bugs
Re: cache quota warning
daemon@ATHENA.MIT.EDU (t. belton)
Thu Jan 21 14:55:28 1999
Date: Thu, 21 Jan 1999 14:55:26 -0500 (EST)
From: "t. belton" <tbelton@MIT.EDU>
To: Marc Horowitz <marc@MIT.EDU>
Cc: bug-infoagents@MIT.EDU
In-Reply-To: <199901200312.WAA10367@steve-dallas.mit.edu>
I've changed the wrapper script to use the code below, with the exception
that the threshold is 5K rather than 10K.
(The method I wanted to use, to only fuss if the .netscape/cache directory
was non-empty, didn't seem to work right. I'm probably missing a trick
somewhere.)
Sorry if 5K seems too low to you. Remember that the idea here is to
discourage caching into AFS space in general. I would rather warn too many
times than not enough.
-Todd
On Tue, 19 Jan 1999, Marc Horowitz wrote:
> Ignore that last diff. Use this one.
> # Warn if cache in wrong place
> if [ -d ${HOME}/.netscape/cache ]; then
> ! warn=`${gnubin}/gdu -sk ${HOME}/.netscape/cache | \
> ! awk '{if ($1>10) { print $1 } else { print "nowarn"}}'`
> ! case "$warn" in
> ! nowarn)
> ! ;;
> ! *)
> ! echo ""
> ! echo ' **** Netscape is eating '$warn'K of your quota! ****'
> ! echo "To correct, this situation, quit Netscape, and then run"
> ! echo " add infoagents"
> ! echo " netscape-fix"
> ! echo " cd"
> ! echo " rm -rf .netscape/cache"
> ! ;;
> ! esac
> fi