PDA

View Full Version : [REQ] Auto-delete script


Pharaoh
10-19-2003, 10:56 AM
I am in need for a script which will automatically delete old releases from a dir (and its' subdirs) when this dir (including its' subdirs) reach a specific size.

For example:
let's say I have the following dirs:

DIR1
--SUBDIR1
----CD1
----CD2
--SUBDIR2
--SUBDIR3

and I want that the total size of DIR1 (including all the other subdirs, and CD1/CD2) not exceed 10g.
I need a script which will check all the subdirs below DIR1 for the oldest release and delete it to free enough space so the total size will never exceed 10g.

Thanks in advance for any assistance! :)

Bratell
10-19-2003, 11:11 AM
Originally posted by Pharaoh
I am in need for a script which will automatically delete old releases from a dir (and its' subdirs) when this dir (including its' subdirs) reach a specific size.

Thanks in advance for any assistance! :)
Aren't there already scripts for this? ioByteKiller and Warchive or somthing like that.

Mouton
10-19-2003, 11:11 AM
WarChive can almost do that...
The only difference is that you need to specify the ammount of free space you want to leave free on that drive, not the total size of the folder.

Maybe ioByteKiller does that. Can't recommend, never tried.

Pharaoh
10-19-2003, 11:23 AM
Originally posted by Mouton
WarChive can almost do that...
The only difference is that you need to specify the ammount of free space you want to leave free on that drive, not the total size of the folder.

Maybe ioByteKiller does that. Can't recommend, never tried.

WarChive doesn't help in this case because it is checking for free space on drive as u said and not used space in directory...it is totally different...