Home > OS >  Find the rm cannot delete file
Find the rm cannot delete file

Time:11-09

One problem:
I use the following command, but unable to remove the suffix for DMP. The gz file, but can I delete the log file, could you tell me what reason be cause?
The find/oracle/backup/mtime + 3 - the name "BBX *. DMP. Gz" - the exec rm - rf {} \;

CodePudding user response:

Until the date is 29, you run it again, should be able to delete the 25,
30, 26, delete,
. .
Because - mtime parameter is + 3,
Said modified time more than 3 x 24 hours, that is, 3 days or more files, will participate in the rm command in

Look at your demand, modify - mtime or directly to remove this option, can satisfy the delete DMP. Gz file request

P.S. don't need - the exec rm
 find/oracle/backup - name "BBX *. DMP. Gz - delete" 

CodePudding user response:

You can run the find/oracle/backup/mtime + 3 - the name "BBX *. DMP. Gz see these can find gz file
Looks like - mtime + 3 this parameter, search file three days ago

CodePudding user response:

You set the time, you see the file time, don't you delete the time range
  • Related