Need some hints on my first shell-script using rsync. I use rsync, because I had some trouble with a graphical Backup that ran twice and now I want this example as shown below to work on two external hard disks, including the cron job, every ten minutes. I read many examples of rsync-scripts and downloaded some, but this one I'm trying to create comes close to what I need. So I'd like to know if there is something to improve here? And do I need to mention exit=0 ?
#!bin/bash # bash check if directory exists if [ -d $/home/andi/Desktop/12tilt.txt ]; then echo "Directory exists" else echo "Directory does not exists" fi exit rsync -avi --progress --delete --iconv -t --stats --compress-level=0 /home/wurzel/ /mnt/usb1/home/wurzel/holz1 rsync -avi --progress --delete --iconv -t --stats --compress-level=0 /home/wurzel/ /mnt/usb2/home/wurzel/holz1