Guest User

Untitled

a guest
Dec 13th, 2017
80
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.40 KB | None | 0 0
  1. #!/bin/bash
  2. for FILENAME in /u01/oracle/domains/custom.log
  3.  
  4. while :
  5.  
  6. do
  7. FILESIZE=$(stat -c%s "$FILENAME")
  8.  
  9. if [[ $FILESIZE > 1000000 ]] ;then
  10. echo "$FILENAME is too large = $FILESIZE bytes."
  11. > $FILENAME
  12. fi
  13. sleep 2m
  14. done
  15. exit 0
  16.  
  17. ./ScriptCustom.sh: line 4: syntax error near unexpected token `while'
  18. ./ScriptCustom.sh: line 4: `while :'
Add Comment
Please, Sign In to add comment