Latest commit 7634e2d …
… for fusion systems. Changed method to tar based on suggestion from Per Olofsson, fixes sub Users folder in Users. Adding quote to in USERZ basename to better support directories with spaces or special charachters suggested by Ryan Butler.
BackupRestore Scripts Current Version - 0.7.4 ## Intro ## See post here: http://rustyisageek.blogspot.com/p/backuprestore-scripts.html ## Please add your feature requests and code to GitHub or by emailing me! I still need to get alternate backup methods working. Rsync and ditto have been failing in my tests. ## ## Known Issues ## 1) -e flag to exclude users has been know to not work properly. If used, you must specify all of the default options ( "shared" "guest" "deleted users" ), as well as your additions! 2) The method to determine the internal drive has recently changed, due mainly to CoreStorage Fusion volumes. Always test the script before using it in production! Please file a bug or email me with any issues. ## Basic Usage ## Usage: DS_BACKUP_DATA [ -e "guest admin shared" ] [ -v "/Volumes/Macintosh HD" ] [ -u /Users ] [ -d "/Volumes/External Drive/" ] [ -t tar ] Variables can be set in DeployStudio variables window when running script. BackupRestore Variables: -q Unique Identifier Should be left empty. Can be used to specify your own identifier for backups. Default is Serial Number. -c Remove User Cache. Will delete the Users /Library/Cache folder before backing up the data. -e Users to Skip - Doesn't Work. Must use quotes for multiple users Default is "guest" and "shared" You must specify "guest" and "shared" if your use the argument -v Target volume Specify full path to mount point of volume Default is the internal volume e.g. /Volumes/Macintosh HD -u User path on target Set to path of users on volume Default is /Users -d Backup destination Specify full path to the backup volume Default is /tmp/DSNetworkRepository -t Backup tool (tar) - Still working on this one! Select backup software, Default tar tar = Use tar with gzip to backup. ditto and rsync NOT WORKING, yet! -removed- ditto = Use ditto with gzip to backup -removed- rsync = Use rsync to backup Usage: DS_RESTORE_DATA [ -e "guest admin shared" ] [ -v "/Volumes/Macintosh HD" ] [ -u /Users ] [ -d "/Volumes/External Drive/" ] [ -t tar ] Variables can be set in DeployStudio variables window when running script. BackupRestore Variables: -q Unique Identifier. Enter the Serial Number of the backup you want to restore. For example, if you backup a computer and its Serial Number was: W8FGTV01TZZ. You can then specify that Serial as the variable to restore the backup to a different computer. -v Target volume Specify full path to mount point of volume Default is the \$DS_LAST_RESTORED_VOLUME volume e.g. "/Volumes/Macintosh HD" -u User path on target Set to path of users on volume Default is /Users -r Backup Repository Path Set to path of the backup volume Default is the DS Repository e.g. "/Volumes/NFSDrive/Backups" ## Advanced Usage ## Unique Identifier Usage: If you'd like to backup from one computer and restore to another, you can specify the Serial Number as the UNIQUE_ID (-q) when restoring. This tells the restore scripts to pull the backup from the old computer (by Serial Number) rather than look for a backup from the same computer (same Serial Number). Alternatively, you can specify a UNIQUE_ID (-q) for both backup and restore. This way, the scripts will ignore the Serial Number of the machines and backup and restore the data using a folder named with the the specified variable. Be sure to set the target volume (-v) for the Backup and Restore so the scripts know where to pull the backup from and where to restore it to. Otherwise, the BackupRestore scripts will use the internal drive of that machine as the backup and restore destinations.