Re: temporary files and subsequent cleanup
Re: temporary files and subsequent cleanup
- Subject: Re: temporary files and subsequent cleanup
- From: Chris Heimark <email@hidden>
- Date: Fri, 26 Oct 2007 11:06:15 -0400
- Resent-date: Fri, 26 Oct 2007 11:14:15 -0400
- Resent-from: Chris Heimark <email@hidden>
- Resent-message-id: <email@hidden>
- Resent-to: cocoadev <email@hidden>
On Oct 26, 2007, at 10:20 AM, Alastair Houghton wrote:
On 26 Oct 2007, at 15:11, Brian Stern wrote:
On Oct 26, 2007, at 7:50 AM, Chris Heimark wrote:
My question is this though. If my application fails, which I am
certain it will never do - hah ;-) - I will have some temp files
left over. Does Tiger+ have a daemon for temporary file removal
that will care of these files from NSTemporaryDirectory() rooted
temporary space here: /private/var/tmp/folders.501/
temporaryitems/ and if so, when and how often does it run to take
care of this?
There are three scripts
/private/etc/daily
/private/etc/weekly
/private/etc/monthly
I knew of these jobs. And upon (finally) examining them for the first
time, I see that they reach into /tmp and other directory structures.
I tried to trace how /tmp --> private/tmp ultimately points into /
private/var/tmp/folders.501/temporaryitems/ and I gave up... Maybe
that is why I stopped programming in Unix years ago...
But I still wonder why, after running "sudo /private/etc/daily" (and
later "sudo /private/etc/weekly") I still have files/directories
older than 3 days present.
Is it possible that other daemons are (or will be) at work here?
After all this directory doesn't have any terribly old entries
If the computer is sleeping or turned off, of course, the scripts
won't run.
You can view the log files generated by these scripts in the
Console utility application.
You can execute the scripts yourself by just typing their names in
the Terminal if you like.
It looked like launchd was going to start doing this itself, so I
don't know (yet) whether this is necessary for Leopard.
Isn't it launchd that makes the daily/weekly/monthly jobs run? Or is
it entries in crontab that lead to their execution?
Kind regards,
Alastair.
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden