How to use TrueNAS as windows TimeMachine !? :(

I try to define a TrueNas (Scale) SMB-share as Windows TimeMachine. However I only partly manage that :sleepy:

I took the following steps:

  • defined a share (with a max quota)
  • defined a share-user-group in favor of the share
  • defined the users which should have access to the share and put them in the share-user-group
  • changed the dataset authorization to owner= share owner and group = share group both with full authorization. Others no authorization at all
  • created the SMB as Multi-user time machine
  • no ACL’s
  • limit access to certain VLAN’s (IP-ranges)
  • defined recursive periodic snap-shot-tasks on the dataset with interval times of 10min (expires 2hours), 1hour (expires (1day) and 1day (Expires 2 weeks) that does not work as hoped for.
  • when accessing from the windows side, the user have to login via its TrueNas name and password. A child dataset is created and other users can not see the content (exactly as intended).
  • when selecting a file from windows, you can select previous versions as long as related snapshot is present.

This behavoir is largely as intended, which one important exception …
the snapshot mechanism …

  1. does not work as intended and
  2. even if it would work it is not ideal

So is there a better way to implement a windows time machine !!??
And if so … how !!

What do you mean by a Windows Time Machine? Is your client Windows or MacOS?

I understand that the goal is to have a Time Machine equivalent for Windows clients. The pre-set “multi-user Time Machine” is probably not the most appropriate, since this is actually not Time Machine.

What I cannot guess is how it does not work as intended.
@louis, do not have us guess.

As the title already indicates, the intention is to create a TimeMachine in favor of Windows clients

The described setup does not make a snapshot of each change (no idea how to do that !! ), but does create regular snapshots each 10 minutes, so that you never lose more than 10 minutes of changes.

The problem is that you can not endlessly create snapshots each 10 minutes. For that reason I did create not one but three snap shot tasks. However that is far from ideal.

As example at the moment the 10 minutes snapshots expire, you lose all changes made in the 10 minute interval.

A better solution would be to only use 10 minute snap shots … but that would raise the number of snapshots to a far too high number. I know that you could in
that case use the option not to take empty snapshots, which would compensate for the high number of snapshots …

But assume you have five users => 5 child datasets + the main data set = in theorie max 6 snapshots per 10 minutes. If you want to hold the changes for two days => max 6 * 6 (per hour) * 24 (per day) * 2 (two days) => a lot of snapshots.

I know much less given the not taken empty snapshots … So if there is not a better solution :() , I will probably try a recursive 10 minutes snapshot task with an expiry time of 2 or 3 days.

As the title already indicates, the intention is to create a TimeMachine in favor of Windows clients

That’s not how these presets work. TimeMachine is MacOS-specific. The share snapshot is triggered specifically when a macos client adds a new completed backup entry to its plist file in a sparsebundle file.

The functionality you’re referring to was developed in response to historical issues with time machine sparsebundle corruption.

1 Like

I use urbackup in docker that can be configured more or less like Time Machine with hourly incremental backups and weekly full backups etc. The is a windows client. The server is in docker container. I’m on the latest scale.

Technically, VEEAM has a free windows backup agent that works very well with SMB shares. We don’t have any special integration in this case with snapshots, but generally there haven’t been any reports of corrupted VEEAM backups.

Perhaps try something like in this video

And look at the Veeam Windows Agent targeting a TrueNAS SMB share.