The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM


Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts here.

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
How to list files that were added or modified on a certain date? thoughts UNIX for Dummies Questions & Answers 8 02-19-2008 09:44 PM
greping certain modified date ali560045 Shell Programming and Scripting 2 02-08-2008 03:54 AM
Create a list of files that were modified after a given date. rkka UNIX for Dummies Questions & Answers 4 01-22-2008 01:12 AM
Last Modified Date cengiz Shell Programming and Scripting 12 06-27-2005 11:05 PM
How do I get the last modified date of a file? akpopa UNIX for Dummies Questions & Answers 2 08-29-2001 12:08 PM

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 01-03-2007
Registered User
 

Join Date: Aug 2005
Posts: 37
search by modified date

Hello,
How can i search for all the files in a particular directory which are not updated from past 5 days.

Thanks,
Sateesh
Reply With Quote
Forum Sponsor
  #2 (permalink)  
Old 01-03-2007
Registered User
 

Join Date: Dec 2006
Posts: 55
find

use the following option

find / -mtime -5 -print
Reply With Quote
  #3 (permalink)  
Old 01-03-2007
Registered User
 

Join Date: Aug 2005
Posts: 37
Thanks for your reply. how can i get these file in to an array so that i can zip them.
Reply With Quote
  #4 (permalink)  
Old 01-03-2007
Registered User
 

Join Date: Dec 2006
Posts: 55
u can send the stream into tar using the pipe

find / -mtime -5 -print | tar cvf test.tar
Reply With Quote
  #5 (permalink)  
Old 06-24-2008
Registered User
 

Join Date: Nov 2007
Posts: 20
use '/' in find only if u want to search from Root dir

to find files in a particular dir. use this command -

find . -type f -mtime +5 -print
Reply With Quote
Google UNIX.COM
Reply

Thread Tools
Display Modes




All times are GMT -7. The time now is 03:57 PM.


Powered by: vBulletin, Copyright ©2000 - 2006, Jelsoft Enterprises Limited.
The UNIX and Linux Forums Content Copyright ©1993-2008 The CEP Blog All Rights Reserved -Ad Management by RedTyger Visit The Global Fact Book

Content Relevant URLs by vBSEO 3.2.0