Page 1 of 1

Find list of files modified in the last X days

Posted: Mon Jul 16, 2012 8:54 am
by a24uall
Get in to the directory that you want the files to be checked.
cd /home/username/public_html
Below command displays all files recursively that have been modified in the past 6 days.
find . -mtime -6

Re: Find list of files modified in the last X days

Posted: Wed Dec 25, 2013 11:59 am
by a24uall
How to move files older than X days to a new folder
find /source/folder/path/ -mtime +X -exec mv {} /destination/folder/path/ \;
Example
cd /home/arun/mail/arunp.in/
find cur/ -mtime +365 -exec mv {} /home/arun/mail/arunp.in/arun/.2012/cur/ \;