ciphermethod.com

20100913: adddirs.sh

by on Sep.13, 2010, under Linux, Scripts

#!/bin/sh
#20100913 – Add log directories to get total log space

for x in `cat linux.servers`
do
  echo $x:
  R=`ssh $x sudo du -h /var/log | tail -1`
  N=`echo $R | cut -f1 -dM`
sum=$(($COUNT + $N))
  COUNT=$sum
  echo $COUNT $N

  echo
done

No comments for this entry yet...

Leave a Reply

You must be logged in to post a comment.

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

But Wait, There's More!

A few highly recommended friends...