achive and remove old files

pascal francois coppernrh at yahoo.fr
Wed Jan 5 16:27:11 UTC 2005


As Steve already said, here is an example of script (lightly better) :
You can work only with files not on sub directories.
find  /somedir  \(  -type  f  -a  -mtime  +730  \)  -exec  mv  -f  {}  /anydir  \;
 
Patrick - rhce


Jianping Zhu <jzhu at fisher.forestry.uga.edu> wrote:
S redhat 9.0
I have a huge direcory (more than 30 GB) I want to take all the files
and sub-dirctries which have not been modified or used for more than
two year out of the diretory and achive it then delete them them from
the original direcoty. Does anyone have a script to do this kind of
work?
Thank


-- 
redhat-list mailing list
unsubscribe mailto:redhat-list-request at redhat.com?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/redhat-list

		
---------------------------------
 Découvrez le nouveau Yahoo! Mail : 250 Mo d'espace de stockage pour vos mails !
Créez votre Yahoo! Mail


More information about the redhat-list mailing list