Thanks david I got it working. I dont know what was really wrong but I deleted the files and riped them off my CDS again and then I copyed them to the destination dir and then ran rsync just to synce the two. It workd fine. Since I have your attention now can you tell me how to do this scrip. Also at the end of a Scrip how do I tell the puter that it id finished. I made a script just to mount the drives and it mounts them, but never brings me back to the command prompt. I use chmod 777 file name after using VI I store this is /sbin
#THIS SCRIP AUTO MOUNTS ALL DRIVES AND BACKS UP G DRIVES
#mounts NTFS drive on notes09
mount -t smbfs -o username=bob,password=bob //bobserver/g /mnt/bobserverg
#LOGS INTO REMOTE BACKUP SERVER
ssh rmotebobserver
#MOUNTS DRIVES ON REMOTE SERVER
mount -t smbfs -o username=bob,password=bob //bobserver/g /mnt/bobserverg
#LOGS OUT OF REMOTE SERVER
logout
#SYNC'S THE DIRESTORIES
rsync -e ssh -avz --delete-after --progress /mnt/gnotes09g root@server:/mnt/gnotes09g/./
umount /mnt/bobserverg
ssh rmotebobserver
umount /mnt/bobserverg
logout
I tried it like this, but it didn't work right. Can you tell me a better way?
Should I have cron mount the drives 30 min before and the have cron run the rsync command?
Also I have never used cron so if you could explain to me what I should to it would be helpful
Last edited by phatboyz; 07-02-2004 at 09:36 AM.
|