Friday, August 19, 2016

Auto-mount of .Sparsebundle Image (Network Share)

Friday, August 19, 2016
Today i was at client site. Had to set the .sparsebundle used by Time Machine Backup to be auto-mounted after server reboot on Mac OS X. I referred to the tutorial below;
Quick Tip: How to Mount a Time Machine Network Drive at Login
When i used the script exactly the same (of course the path has to be changed accordingly), it was throwing out errors like directory not found, image not recognized etc. What i did was i went back to basically running the script one by one the terminal and saw how it came about. So here below is the final script to make it happen:
mount volume "smb://servername/dir"
end try
do shell script "hdiutil attach /Volumes/dir/filename.sparsebundle"
Then, do these;

Applescript Editor -> Export as App to Documents -> Drag and drop to Login Items

Try restarting the server and verify if the .sparsebundle is mounted automatically.


Post a Comment

@Chiq & Stuff © 2008. Design by Pocket