Commits

Radu Potop committed 9ef4680

bak

Comments (0)

Files changed (2)

 # Full System Backup with rsync
 # https://wiki.archlinux.org/index.php/Full_System_Backup_with_rsync
 
-DEST=/media/backup
+DEST=$1
 LIST=/home/radu/bin/bak_list
 
 if [ -z $DEST ]; then
 fi
 
 sudo sh -c "
-    mount $DEST
     rsync -av --delete-excluded --exclude-from=$LIST / $DEST
     date -R > $DEST/BACKUP
-    umount $DEST
 "
 #!/bin/bash
 # Get temperature for CPU, MOBO, GPU, HDD
 
-echo -e 'DATE\tCPU\tMOBO\tGPU\tHDD'
+echo -e 'DATE\tCPU\tMOBO\tGPU\tHDD1'
 
 while (true) do
 
     CPU=`sensors|egrep 'CPU Temperature'|awk '{print $3}'| sed 's/°C//'|sed 's/+//'`
     MOBO=`sensors|egrep 'MB Temperature'|awk '{print $3}'| sed 's/°C//'|sed 's/+//'`
     GPU=`nvidia-settings -q GPUCoreTemp 2> /dev/null | egrep 'Attribute'|awk '{print $4}'|sed 's/\.//'`
-    HDD=`sudo hddtemp /dev/sda | awk '{print $4}' | sed 's/°C//'`
+    HDD=`sudo hddtemp /dev/sdb | awk '{print $4}' | sed 's/°C//'`
 
     echo -e "$DATE\t$CPU\t$MOBO\t$GPU\t$HDD"