Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/sh -e
- #
- # Basic Backup to my Fritz!Box
- #
- DATER=`date +%b%_3d%_9T`
- #
- # Mount the Box
- #
- echo $DATER fritzcopy: creating local folder
- if [ ! -d /mnt/fritzcopy ]
- then
- mkdir /mnt fritzcopy
- fi
- echo $DATER fritzcopy: mounting remote folder
- if !(/bin/mount -t cifs -o user=ftpuser,password=tiger123,workgroup=WORKGROUP //fritz.box/fritz.nas/Initio-INI-T640-01/Music /mnt/fritzcopy)
- then
- echo $DATER fritzcopy: mount failed: could not mount remote share
- echo $DATER fritzcopy: terminated with error 1
- exit 1
- fi
- echo $DATER fritzcopy: syncing Music folder
- mkdir /mnt/fritzcopy/iTunes
- rsync -rlptDv –modify-window=1 --dry-run ~/Music/iTunes /mnt/fritzcopy/iTunes
Add Comment
Please, Sign In to add comment