![]() |
|
|
google unix.com
|
|||||||
| Forums | Register | Forum Rules | Links | Albums | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| Shell Programming and Scripting Post questions about KSH, CSH, SH, BASH, PERL, PHP, SED, AWK and OTHER shell scripts and shell scripting languages here. |
More UNIX and Linux Forum Topics You Might Find Helpful
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Removing files older than 7 days | texasoeb | UNIX for Dummies Questions & Answers | 3 | 04-20-2007 05:04 PM |
| ls latest 4 days or specify days of files in the directory | happyv | Shell Programming and Scripting | 3 | 01-22-2007 07:16 AM |
| Searching for files over 30 days old in current directory | cxredd4 | Shell Programming and Scripting | 18 | 06-11-2006 03:16 AM |
| How to zip a modified file 15 days before but not scanning my sub directory files | skrish70 | Shell Programming and Scripting | 1 | 10-10-2005 04:41 PM |
| removing files that are 60 days old | aojmoj | Shell Programming and Scripting | 5 | 01-26-2004 02:45 PM |
|
|
LinkBack | Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
||||
|
Removing files automatically from a directory after 30 days.
Hello;
I have a directory that is collecting log and act files. I need to write a script that will remove these files once they are 30 days old. I have read through a number of threads on this site that have given me a great deal of information. However I have what seems to be a unique situation. I can't use the -atime or the -mtime commands because not all the files that haven't been modified or accessed can be deleted. There are non log or act files in this directory. One thing that may help is that the log and act files use yyyymmdd.log or yyyymmdd.act file naming system. IE 20050623.log or 20050623.act. How can I use this to generate my script? Thank you very much in advance for your knowledge and help. |
| Bookmarks |
| Tags |
| mtime |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|