|
|
Mount / unmount external drive for Backup use
I have been working on an rsync script and I believe you will find that the device name will change depending on the circumstances. We have automount to thank for that. I am not yet mounting/unmounting my disk but I am using
`/usr/sbin/diskutil info /Volumes/ROCSTOR | grep UUID | awk '{print $2}' | grep xxxx-xxxxxx-xxxxxx-xxxxxx` to verify the script only runs when the exact disk volume needed is there. I found that without a good sanity check rsync would mirror my directory back onto the local disk in "/Volumes" because automount sometimes leaves a directory behind after the volume is unmounted. And if that happens at the same time another device is using the same device name you have a problem. So I look for the disk UUID, and that the target directory is present. I will probably be adding mount/unmount at some point. More importantly, I need a "busy" UI that a) informs when the sync is running and b) allows one to interrupt when needed. Unmounting between syncs also allows the user to yank the firewire (or USB) cable without ejecting the disk. This lessens the likelihood of disk corruption.--- |
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.09 seconds |
|