Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Is there a simple way to delete files > 90 old? 1

Status
Not open for further replies.

bjdobs

Programmer
Mar 11, 2002
261
CA
Sorry this may be a double post as I clicked on the wrong forum ... I am writing a script in AIX and need a way to delete files older then 90 days ... currently we were using a LIFO of numbered files ... this doesn't work anymore because the number of files is no longer constant.
 
This is an automated script and does not have root privileges ... I did a man skulker and it does have very much info on how to do this ... I could throw another script into the root cron but could I please trouble you for an example of how to use skulker to remove files older then 90 days from a specific directory

Thx
 
/usr/bin/find /mydir/ -xdev -mtime +90 -type f -exec rm {} \;

Try this.

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top