2013-12-12 07:39:37 +00:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
set -x
|
|
|
|
~nico/bin/backup-marker
|
|
|
|
|
|
|
|
dsthost="$1"; shift
|
|
|
|
case "$dsthost" in
|
|
|
|
42)
|
|
|
|
dst=42:/home/services/backup/bento
|
|
|
|
;;
|
|
|
|
loch)
|
|
|
|
dst=root@loch:/home/services/backup/bento-manuell
|
|
|
|
;;
|
2014-02-26 13:24:29 +00:00
|
|
|
luchsingen)
|
|
|
|
dst=root@luchsingen.schottelius.org:/home/services/backup/bento-manuell
|
2013-12-12 07:39:37 +00:00
|
|
|
;;
|
|
|
|
*)
|
|
|
|
echo "Unknown $1" >&2
|
|
|
|
exit 1
|
|
|
|
;;
|
|
|
|
esac
|
|
|
|
|
|
|
|
start=$(date)
|
2013-12-21 08:25:53 +00:00
|
|
|
rsync -avS --delete --progress \
|
2013-12-12 07:39:37 +00:00
|
|
|
--exclude '/proc/*' \
|
|
|
|
--exclude '/tmp/*' \
|
|
|
|
--exclude '/sys/*' \
|
|
|
|
--exclude '/dev/*' \
|
2014-02-26 13:24:29 +00:00
|
|
|
--exclude '/run/*' \
|
|
|
|
--exclude '/home/services/usbhd' \
|
|
|
|
--exclude '/home/users/nico/.cache/chromium/' \
|
2013-12-12 07:39:37 +00:00
|
|
|
--exclude '/home/users/nico/.bitcoin/blocks/' \
|
|
|
|
--exclude '/home/users/nico/.bitcoin/chainstate/' \
|
|
|
|
"$@" \
|
|
|
|
/ "$dst"
|
|
|
|
end=$(date)
|
|
|
|
|
|
|
|
echo $start
|
|
|
|
echo $end
|