Limit Time Machine Backup Size

Backup and restore solutions, issues, experiences
Locked
User avatar
StephenM
Posts: 69
Joined: 11 Jan 2021, 21:55

Limit Time Machine Backup Size

Post by StephenM »

Is there any way I can limit the size of the time machine backups either as a total or per user?
User avatar
StephenM
Posts: 69
Joined: 11 Jan 2021, 21:55

Re: Limit Time Machine Backup Size

Post by StephenM »

So I started from scratch.

For info: F4-210, with btrfs

I scrapped the shared folders and added one share for each Time Machine backup vault per Mac.

On the shared folder I set the quota to a suitable size.

I then set up the time machine in Backup and selected the folders to be used.

I then, on a Mac, selected one of the shared folders as a backup disk.

However, Time Machine sees that folder as the full size of the volume the shared folders are in. I suspect that will cause a time machine backup to fail if the NAS enforces the quota, but I don’t even know if the quota is applied to the folder.

How do I verify that the quota has been applied?

How do I make the quota size visible as the size that Time Machine has available to it?
User avatar
StephenM
Posts: 69
Joined: 11 Jan 2021, 21:55

Re: Limit Time Machine Backup Size

Post by StephenM »

I’ve also tried adding a vol size limit in etc/afp.conf

I know that this get overwritten when afp starts but I tinkered with some of the scripts in /etc/init.d to stop this from being overwritten.

This time the Time Machine on the Mac reported the size of the drive as set by the vol size limit.

However, as the backup continued the available space didn’t decrease. This could be because I’m running Catalina and it doesn’t save a backup as a sparsebundle but as a backupbundle instead.

Next test is to either symlink or hardlink a file name of type sparsebundle to see if that reports the correct free space.

I’d rather not have to break the init scripts to do this though. They’ll need breaking again after each TNAS update.

Can I put in a request that there is an option in setup to present to Time Machine a volume size.

Otherwise Time Machine will start failing backups using an unreported quota setting or if left unchecked the backups will fill up the whole of the hard drive over extended time.
User avatar
StephenM
Posts: 69
Joined: 11 Jan 2021, 21:55

Re: Limit Time Machine Backup Size

Post by StephenM »

This is a much needed feature and I can tell the developers what needs to be done - it should be relatively simple:

Use quota that is set on a share to populate the vol size limit parameter in afp.conf

Or

Have the option in the Time Machine setting in the Backup App to add a size limit there.

Modify /sbin/svrcfg-all -c afp to add the size limit into afp.conf.

Have an occasional cronjob that looks for .backupbundle in the Time Machine directories and make a symlink to for every backupbundle to a sparsebundle if the sparse bundle doesn't exist.

Happy to start a dialogue
User avatar
TMzethar
TerraMaster Team
Posts: 1127
Joined: 27 Oct 2020, 16:43

Re: Limit Time Machine Backup Size

Post by TMzethar »

We shall be glad to refer to your ideas and methods. Thank you!
To contact our team, please send email to following addresses, remember to replace (at) with @:
Technical team: support(at)terra-master.com (for technical support)
Service team: service(at)terra-master.com (for purchasing, return, replacement, RMA service)
User avatar
macmpi
Posts: 120
Joined: 07 Jan 2020, 02:52

Re: Limit Time Machine Backup Size

Post by macmpi »

{L_BUTTON_AT}StephenM
FYI, this feature has been discussed here for a while. Was expected for 4.2
TerraMaster F2-210 under TOS 4.2.43, RAID1, Btrfs, serving Mac, Linux & Windows clients
Locked