hi
i need to housekeep log files over a certain age, the script currently running reads a properties file that has entries such as -
/dir1/dir2/dir3/*txt 5
/dir1/dir2/dir3/*.txt 5
currently the script uses find i.e.
find /dir1/dir2/dir3/*txt -type f -mtime +5 -exec rm -e {} ;
the find is failing due to the arg list being too long. i cannot change the properties file as there is hundreds of entries in each and hundreds of servers !! can someone suggest a way (i guess using xargs) to get around this.
thanks in advance (i am using AIX)
i need to housekeep log files over a certain age, the script currently running reads a properties file that has entries such as -
/dir1/dir2/dir3/*txt 5
/dir1/dir2/dir3/*.txt 5
currently the script uses find i.e.
find /dir1/dir2/dir3/*txt -type f -mtime +5 -exec rm -e {} ;
the find is failing due to the arg list being too long. i cannot change the properties file as there is hundreds of entries in each and hundreds of servers !! can someone suggest a way (i guess using xargs) to get around this.
thanks in advance (i am using AIX)