find and delete older file

Agi Subagio agi.subagio at saranaasiaraya.com
Fri May 21 04:33:10 UTC 2004


I have a script that create a backup file in regular schedule (run everyday
at 2 AM).
But after several weeks, my harddisk is getting full.
I want to delete older backup file that not modified/create after 30 days
ago.

I have used command;
$ find ./test -mtime +30 -exec 'rm -f *'
But it seems, the rm command is not work.

How to do that?

---
This email is protected by Clam AntiVirus and SpamAssassin





More information about the redhat-list mailing list