Advertisement
Guest User

Untitled

a guest
Feb 19th, 2019
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. for file in `cat filelist`; do
  2. PROTOCOLS1=`egrep -i 'rsh|rsync|remsh' "$file" | egrep -v '^[ | ]*#'`
  3. FIELDS=`echo $PROTOCOLS1|wc -l`
  4. if [[ $FIELDS -gt 1024 ]]; then
  5. echo $file >> $debuglog
  6. else
  7. set -A myarray $PROTOCOLS1
  8. do stuff.....
  9. fi
  10. done
  11.  
  12. myserver-v1> echo $variable
  13. myserver-v1> /usr/bin/echo: too many args
  14.  
  15. echo $variable
  16. if [[ $? -ne 0 ]]; then
  17. write to error log
  18. fi
  19.  
  20. [[ ! `echo $variable ]]
  21. [[ `echo $variable ]]
  22.  
  23. FIELDS=`echo $PROTOCOLS1|wc -l`
  24.  
  25. FIELDS=1
  26.  
  27. FIELDS=$(echo "$PROTOCOLS1" | wc -l)
  28.  
  29. FIELDS=$(egrep -i 'rsh|rsync|remsh' "$file" | egrep -c -v '^[ | ]*#')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement