Messages in this thread | | | Date | Thu, 4 Mar 1999 11:20:53 +1100 | From | Richard Gooch <> | Subject | Re: EXT2_UNRM_FL |
| |
Theodore Y. Ts'o writes: > Date: Thu, 4 Mar 1999 10:46:59 +1100 > From: Richard Gooch <rgooch@atnf.csiro.au> > > I don't understand why you even want to poll. My approach was to clean > up at safe-delete time: I just do a stat(2) to see if there is enough > space left. If not, I start purging. And in your ~/.logout you can > call the command to empty the wastebasket. > If you want to get more fancy, set up a cron job or add something to > the boot scripts to clean up. > > Someone deletes a large number of files on the system. Sometime > later, some other user starts unpacking a kernel tree, and needs > space. It would be nice for a daemon to notice that free space was > getting critical, and for it to start really deleted files that were > in the "trashcan" in order to make space. After all, when the user > deleted the files, they're effectively stating that they don't want > them anymore, and the undelete option is just as a saving throw. If > they then logout for three months, if the space is needed for > something more worthy, there should be a way for that space to be > reclaimed automatically.
I understand most of that, but I'm still missing why the polling is needed. Why not have the utility check for low space, purge the user's files and if space is still too low, contact the daemon to purge other users' files?
With polling you preemptively purge. I'm suggesting that you only purge when you run out of space.
Hm. Wait a minute. Now I see what you're driving at. You're referring to the case where space is needed when putting new files on the FS. OK. Yeah, regular polling by the daemon could be used to see if you run out of space. Yep. Let's first see if a polling daemon is effective before hacking the kernel. The cost of polling should be really cheap, so doing it once a second or more should be OK.
Regards,
Richard....
- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/
| |