How to find recently modified files in Linux

  
 

If there is any problem with the website or server, first think about whether the file on the server has been modified. The search will use the find command, as follows:

Find the current directory under the .php file, the last 30 A modified file within minutes.

find . -name ‘*.php’ -type f -mmin -30 Find the details of the files that have been modified in the last 30 minutes in the .html file in the current directory.

find . -name ‘*.html’ -type f -mmin -30 -ls Find regular files that have been modified in the current directory for the last 1 day.

find . -type f -mtime -1


Find regular files that have been modified in the current directory, the last day (2 days).

find . -type f -mtime +1

If you want to find the changes to the files in the /home directory, cd /home and then run the search, so if you encounter problems It's easy to troubleshoot the problem.

Copyright © Windows knowledge All Rights Reserved