Rotate Logs Older Than 7 days and Delete Archive [on hold]
up vote
-1
down vote
favorite
I'm trying to configure logrotate to find all the log files older than 7 days from certain directories and archive them. The archived files must be deleted. I have a structure as follows. /var/log/myapp/subfolder1/*.log (hundreds of logs) /var/log/myapp/subfolder2/*.log (hundreds of logs) /var/log/myapp/subfolder3/*.log (hundreds of logs) /var/log/myapp/subfolder4/*.log (hundreds of logs) I know I should create a configuration file in /etc/logrotate.d/ , but how can I specify the archiving of log file older than 7 days in each directory and remove the archived files?
logs logrotate
share | improve this question
edited Dec 4 at 13:...