RE: Improving the perlapp --tmpdir mechanism
by kenneth other posts by this author
May 14 2009 3:00AM messages near this date
RE: Improving the perlapp --tmpdir mechanism
|
RE: Improving the perlapp --tmpdir mechanism
Jan,
Sorry for tardiness in continuing...
> I don't know, people who like to keep their /tmp directories clean
> should probably reboot their machines more often and wipe /tmp
> totally empty on restart. Or run a cron job that deletes files older
> than 90 days from /tmp every week or something like that.
Well, this is basically the root cause I'm battling. The problem is that we
have other software which sometimes needs plenty of free space in /tmp (and
sometimes fails to clean up after itself, and/or people sometimes use /tmp
for their own great ideas). In principle, they must not ever fail due to
lack of disk there if we can help it (involves nightly builds, test runs
etc with sometimes dire consequences if we miss schedule).
Cleaning /tmp on reboot is a fine idea, but generally fails simply because
reboots are only done when we absolutely need it for service of some sort.
Instead I *have* implemented the idea of a cron job that monitors and
cleans, except it must be much, much more aggressive than your example.
Depending on the server, it cleans everything older than a few days at
most, and in some cases mere hours. Actually, there are other factors at
play also (it is dependent on a threshold, regardless of age, it doesn't
measure just individual files as leafs but calculates based on trees etc
etc etc).
So, trying to come to the point: if I could set my app to use, say
'/<something_else_than_tmp> /my_fancy_app' as the 'root' for PDK tmp files,
they simply wouldn't encroach on /tmp and even if I still used /tmp with
something like '/tmp/my_fancy_app' I could easily adjust aggressiveness for
that subtree only, and have other rules for other trees.
Obviously, playing around with globally setting TMP/TEMP/TMPDIR etc is not
a good idea as it would impact everything and everyone using those envvars.
I hope this is more understandable in what I'm looking for...I will look at
improving my cleaning script, but with more options for -tmpdir I'd be a
bit more flexible in defining 'the runtime environment' for my perlapp'ed
script.
ken1
_______________________________________________
PDK mailing list
PDK@[...].com
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
Thread:
kenneth
David Kaufman
Jan Dubois
kenneth
Jan Dubois
kenneth
Jan Dubois
kenneth
Terris Linenbach
|