How to clean 3 days before files, from a directory?


 
Thread Tools Search this Thread
Top Forums Shell Programming and Scripting How to clean 3 days before files, from a directory?
# 8  
Old 01-29-2014
In case it's germaine, be aware that rm.log logs attempted deletions, not just successful deletions.

Regards,
Alister
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Linux

Finding files older than x days within directory with spaces

Hi, I am trying to run a command that finds all files over x amount of days, issue is one of the directories has spaces within it. find /files/target directory/*/* -type f -mtime +60 When running the above the usual error message is thrown back + find '/files/target\' 'directory/*/*' -type... (1 Reply)
Discussion started by: Ads89
1 Replies

2. Shell Programming and Scripting

How to move the files older than x days with similar directory structure?

Hello, I need to move all the files inside /XYZ (has multi-depth sub directories) that are older than 14 days to/ABC directory but with retaining the SAME directory structure. for example: /XYZ/1/2/3/A/b.txt should be moved as /ABC/1/2/3/A/b.txt I know about find /XYZ -type f -mtime +14... (3 Replies)
Discussion started by: prvnrk
3 Replies

3. AIX

Want to delete directory, subdirectories and all files which are older than 7 days

how do i remove sub directories of a directory and all files which are older than 7 days by a single command in AIX. pls help me. I am using command as #find /gpfs1/home/vinod/hpc/ -depth -type d -mtime +7 -exec rm -rf {} \; so i want to delete all sub directories and all files from the... (1 Reply)
Discussion started by: vinodkmpal
1 Replies

4. Shell Programming and Scripting

Delete files older than 10 Days in a directory

Hi All I want to remove the files with name like data*.csv from the directory older than 10 days. If there is no files exists to remove older than 10 days, It should not do anything. Thanks Jo (9 Replies)
Discussion started by: rajeshjohney
9 Replies

5. UNIX for Dummies Questions & Answers

Need Help in reading N days files from a Directory & combining the files

Hi All, Request your expertise in tackling one requirement in my project,(i dont have much expertise in Shell Scripting). The requirement is as below, 1) We store the last run date of a process in a file. When the batch run the next time, it should read this file, get the last run date from... (1 Reply)
Discussion started by: dsfreddie
1 Replies

6. Shell Programming and Scripting

ls latest 4 days or specify days of files in the directory

Hi, I would like to list latest 2 days, 3 days or 4 days,etc of files in the directory... how? is it using ls? (3 Replies)
Discussion started by: happyv
3 Replies

7. Shell Programming and Scripting

Searching for files over 30 days old in current directory

May be a simple question for experts here.... I need to get the list of files older than 30 days in the current folder. I tried "find", but it searches recursively in all the sub directories. Can I restrict the recursive search and extract the files only from current directory ? (18 Replies)
Discussion started by: cxredd4
18 Replies

8. Shell Programming and Scripting

How to zip a modified file 15 days before but not scanning my sub directory files

I am using zip -m option to zip my files, but i dont want my sub directories files to be zipped (1 Reply)
Discussion started by: skrish70
1 Replies

9. Shell Programming and Scripting

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... (7 Replies)
Discussion started by: justinb_155
7 Replies

10. AIX

Directory clean up

I want to write a script in ksh that will delete file that are more than 2 weeks old. (4 Replies)
Discussion started by: jango
4 Replies
Login or Register to Ask a Question
TALLY.CONTROL(8)					    InterNetNews Documentation						  TALLY.CONTROL(8)

NAME
tally.control - Keep track of newsgroup creations and deletions SYNOPSIS
tally.control < logfile DESCRIPTION
tally.control is normally daily invoked by scanlogs. It reads its standard input, which should be the newgroup.log and rmgroup.log control log files. They contain a summary line describing the control message and the action taken by controlchan, followed by the article indented by four spaces, and a blank line. Then, tally.control updates the cumulative list of newsgroup creations and deletions which is kept in control.log. All these log files reside in the pathlog directory set in inn.conf. In order to generate them, you need to enable control articles logging in control.ctl(5), as explained in the control.log entry of newslog(5). FILES
pathbin/tally.control The Shell script itself used to tally newsgroup creations and deletions up. pathlog/control.log This file maintains a count of the number of newgroup and rmgroup control messages seen for each newsgroup. The count is of the number of control messages with the indicated arguments, regardless if they were actually processed. All control arguments, including invalid ones, are counted. An example of lines which can be found in that log file is: 3 Control: newgroup foo.bar moderated 3 Control: rmgroup misc.removed 1 Control: newgroup misc.created HISTORY
Written by Landon Curt Noll <chongo@toad.com> and Rich $alz <rsalz@uunet.uu.net> for InterNetNews. Rewritten and converted to POD by Julien Elie. $Id: tally.control.pod 8357 2009-02-27 17:56:00Z iulius $ SEE ALSO
control.ctl(5), news.daily(8), newslog(5), scanlogs(8). INN 2.5.2 2009-05-21 TALLY.CONTROL(8)