Finding files that have been modified within X days


Enter Your Query:
Use '%' for wildcards and quotes for "exact phrases"


Top Level » System Level » File System

Finding files that have been modified within X daysLast Modified: Dec 18, 2011, 5:43 pm
If you need to find files that have been modified within a certain number of days (eg: files newer than X days), you can use the find command. In this example, we'll list all files under /home/admin which have been modified within the last 2 days:

cd /home/admin
find -mtime -2

This might be useful if you're looking for any recent changes in the account.

Along the same times, you can list files which are older than a certain time by using + instead of - on the number.  For example, any files older than a year can be listed with

find -mtime +356


Other useful find commands
 
Related Helpfiles
Automatically purge inbox and other IMAP folders

© 2018 JBMC Software, Suite 173  3-11 Bellerose Drive, St Albert, AB  T8N 1P7  Canada.  Mon-Fri 9AM-5PM MST