]> git.sesse.net Git - backup.sh/blobdiff - backup.sh
bare tatt med en du -k etter backup
[backup.sh] / backup.sh
index dd96e1299d9b2f2c2ca426de08f6fb0b96e18527..6f67ee024b5fecc2b620f33b4f3a9f3d78a2def4 100755 (executable)
--- a/backup.sh
+++ b/backup.sh
@@ -72,8 +72,10 @@ backup()
  exf=`ssh $computer "ls ~/.backup/exclude"`
 
  #We try to run tar on the remote computer
- if `ssh $computer "cd $filesystem ;\
-     $tar cfl - . $lastcmd \
+ #    C is instead of 'cd $filesystem'
+ #    - is 'this directory'
+ #    l is 'stay in local filesystem
+ if `ssh $computer "$tar cfCl - $filesystem . $lastcmd \
       --exclude-from=$exf \
         | gzip" \
    |  dd of=$DATE.tmp 2>/dev/null` 
@@ -196,4 +198,7 @@ done
 #[ ! -z $remotestat ] && scp /tmp/report.txt $remotestat
 ###
 
+# print diskusage to logfile
+df -k
+
 date