I've setup a little cron to compress log files of my application. Generally I need todays logs, so I can compress everything that is one day old or older.
Why do the two following commands behave different?
mtime is not finding anything at all, while using msec yields the desired result?
find /var/log/myapp/cronjobs/ -type f -mtime +1 -exec gzip {} \;
find /var/log/myapp/cronjobs/ -type f -msec +86400 -exec gzip {} \;
the mtime option does not yet compress files, which are now exactly 48 hours old...
any suggestions?
Edit: Ah, no, just noted: Oldest File is 1 day, 23.xx hours - so I assume that does not yet count as "older than 1 day", cause its rounded down to 1 day - and then not considered OLDER THAN, cause its "equal to".