{"id":14859,"date":"2021-12-17T10:25:53","date_gmt":"2021-12-17T10:25:53","guid":{"rendered":"https:\/\/lgildv5i97.onrocket.site\/answers\/?post_type=question&#038;p=14859"},"modified":"2021-12-17T10:26:30","modified_gmt":"2021-12-17T10:26:30","slug":"script-to-check-files-older-than-1-hour","status":"publish","type":"question","link":"https:\/\/computing.net\/answers\/solaris\/script-to-check-files-older-than-1-hour\/5244.html","title":{"rendered":"Script To Check Files Older Than 1 Hour"},"content":{"rendered":"<p>The find command on Solaris makes it hard to find files that are older than 1 hour&#8230;I can easily find those that are older than 1 day, but I need more granularity. Other than switching to Linux, which is not an option, any ideas?<\/p>\n<p>From the command line, I can ls -l and awk the time element out, but what can I compare it to? Say the ls -l command shows a file &#8216;myfile&#8217; with a last-modified time of &#8217;10:30&#8217;&#8230;Now, how do I get a &#8216;now&#8217; time so I can do a comparison for 10:30 &lt; now &#8211; 1 hour ?<\/p>\n<p>Thanks!<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"inline_featured_image":false,"iawp_total_views":14},"question-category":[63],"question_tags":[],"class_list":["post-14859","question","type-question","status-publish","hentry","question-category-solaris"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question\/14859","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question"}],"about":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/types\/question"}],"author":[{"embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/comments?post=14859"}],"wp:attachment":[{"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/media?parent=14859"}],"wp:term":[{"taxonomy":"question-category","embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question-category?post=14859"},{"taxonomy":"question_tags","embeddable":true,"href":"https:\/\/computing.net\/answers\/wp-json\/wp\/v2\/question_tags?post=14859"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}