November 1, 20214 yr I got a new M1x macbook pro. I want to setup my Unraid server as a time machine target. I used the following guide I enabled Enhanced Mac OS interoperability, then I created a new share and created the tm share with the time machine capacity limit. When I connect to the SMB share then open the time machine app I see no offer to use the share as a time machine target... I tried to manually add it from the CLI and also no dice: flinte@Flintes-MBP ~ % sudo tmutil setdestination "/Volumes/tm-tony/" /Volumes/tm-tony: Disk does not support Time Machine backups. (error 45) The backup destination could not be set. Anyone out there using Unraid as a TM target with Mac os 12? Anyone have any thoughts on something I have missed in the config or maybe is this a regression/bug in Mac os 12? Edited November 1, 20214 yr by flinte
November 1, 20214 yr Author I didnt find a solution to this problem with the SMB share, but I have found a work around for now. on my Mac I had to go into Settings --> Security & Privacy --> Full Disk Access and approve Terminal.app. That is in prep for the next part. Mount your Unraid SMB share ("SMB-TM-UNRAID" in this example) to the Mac client. open terminal and run: sudo hdiutil create -size 300g -type SPARSEBUNDLE -nospotlight -volname "SMBTimeMachine" -fs "Case-sensitive Journaled HFS+" -verbose /Volumes/SMB-TM-UNRAID/$HOST_TimeMachine.sparsebundle Navigate to the directory /Volumes/SMB-TM-UNRAID/ in finder and click the .sparcebundle file to mount it as a disk. This will mount a new disk called SMBTimeMachine to your Mac. open terminal and run: sudo tmutil setdestination -a "/Volumes/SMBTimeMachine/" open Time Machine utility and configure. Youll need to configure Mac to remount these shares at boot. Settings --> Users & Groups --> Your User --> Login Items. Drag the mounted drives SMB-TM-UNRAID and SMBTimeMachine into the login items window.
December 12, 20214 yr You're a life saver! Running the first backup now, but looks like it all worked great.
January 12, 20224 yr On 11/1/2021 at 4:55 PM, flinte said: I didnt find a solution to this problem with the SMB share, but I have found a work around for now. on my Mac I had to go into Settings --> Security & Privacy --> Full Disk Access and approve Terminal.app. That is in prep for the next part. Mount your Unraid SMB share ("SMB-TM-UNRAID" in this example) to the Mac client. open terminal and run: sudo hdiutil create -size 300g -type SPARSEBUNDLE -nospotlight -volname "SMBTimeMachine" -fs "Case-sensitive Journaled HFS+" -verbose /Volumes/SMB-TM-UNRAID/$HOST_TimeMachine.sparsebundle Navigate to the directory /Volumes/SMB-TM-UNRAID/ in finder and click the .sparcebundle file to mount it as a disk. This will mount a new disk called SMBTimeMachine to your Mac. open terminal and run: sudo tmutil setdestination -a "/Volumes/SMBTimeMachine/" open Time Machine utility and configure. Youll need to configure Mac to remount these shares at boot. Settings --> Users & Groups --> Your User --> Login Items. Drag the mounted drives SMB-TM-UNRAID and SMBTimeMachine into the login items window. Thanks for this, I hope this gets less hacky, but this fixed my issue. Would you happen to know if this is able to be encrypted?
January 16, 20224 yr I think there might be a solution though because I was able to do it in Proxmox after this date of posting (late Dec) - now I'm on unraid and having this same problem.
January 20, 20224 yr I've been having issues with backups taking forever and/or cleaning up never finishing. I tried to make an AFPS formatted sparse bundle instead and it is much faster and seems to be working "better". Interestingly, during this process my NAS Time Machine folder actually showed up as a destination and allowed me to make a backup there without creating a sparse bundle. I am on macOS 12.0.1.
April 17, 20224 yr I'm able to create the first backup without issues, but any backup afterwards just ends up "Preparing Backup" and then Stopping... macOS 12.3.1, unRAID 6.9.1
May 7, 20224 yr On 11/1/2021 at 8:55 PM, flinte said: I didnt find a solution to this problem with the SMB share, but I have found a work around for now. on my Mac I had to go into Settings --> Security & Privacy --> Full Disk Access and approve Terminal.app. That is in prep for the next part. Mount your Unraid SMB share ("SMB-TM-UNRAID" in this example) to the Mac client. open terminal and run: sudo hdiutil create -size 300g -type SPARSEBUNDLE -nospotlight -volname "SMBTimeMachine" -fs "Case-sensitive Journaled HFS+" -verbose /Volumes/SMB-TM-UNRAID/$HOST_TimeMachine.sparsebundle Navigate to the directory /Volumes/SMB-TM-UNRAID/ in finder and click the .sparcebundle file to mount it as a disk. This will mount a new disk called SMBTimeMachine to your Mac. open terminal and run: sudo tmutil setdestination -a "/Volumes/SMBTimeMachine/" open Time Machine utility and configure. Youll need to configure Mac to remount these shares at boot. Settings --> Users & Groups --> Your User --> Login Items. Drag the mounted drives SMB-TM-UNRAID and SMBTimeMachine into the login items window. Thank you for this. I know it's a slightly older thread but googling my problem this post came up and it worked for me on my Mac Mini 2018 running Monterey.
May 12, 20224 yr On 4/16/2022 at 8:44 PM, joshbgosh10592 said: I'm able to create the first backup without issues, but any backup afterwards just ends up "Preparing Backup" and then Stopping... macOS 12.3.1, unRAID 6.9.1 Having the same issue. First backup runs without issue. After that all attempts fail. Logs show that time machine couldn’t unmount the disk. Have you had any luck fixing this?
May 27, 20224 yr For anyone having issue with Time Machine backups I just wanted to point out that there is a new docker available in unRAID. timemachine. Since the sole purpose of this docker is stable TM backups it’s likely a better choice than the default unRAID compatibility. Edited May 27, 20224 yr by wgstarks
September 11, 20232 yr tmbackup.sh The above script is based on https://community.jamf.com/t5/jamf-pro/scripts-for-timemachine-backups-over-smb-with-automounting-on/td-p/277978 It has to be run only once, as a regular user, but will ask for password for commands that require sudo, so make sure the user has Admin privileges set. Basically it will set up autofs to mount the SMB share and respective sparsebundle. Obviously, modify the script if required. Edited March 26, 20242 yr by yp_1 updated script
March 26, 20242 yr Also, you will need to give cron Full Disk Access for the cron entry created by the above script to work: https://osxdaily.com/2020/04/27/fix-cron-permissions-macos-full-disk-access/ Edited March 26, 20242 yr by yp_1
March 26, 20242 yr As of now I have the backup against an SMB share (created using the above script) working on Sonoma. No issues.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.