07-27-2012 08:14 PM
I have a directory with lots of subdirectories created by a Software.
Many files are created in these sub directories and picked by another software.
I want to write a cron job to list the files which are not being picked up in last 15 minutes .
How can I use the find command to list down the files which have a timestamp of more than 15 minutes.
ie: . SYSTEM TIME-File TImestamp > 15 mins
Please help with find command or any other script.
07-27-2012 08:47 PM
Unfortunately HP-UX's find only has granularity of days. To get smaller, you need a reference file and you must be able to do date arithmetic to figure out what's 15 minutes ago.
touch MMDDhhmm ref_file
find path -type f ! -newer ref_file