I've been trying to get Time Machine to stop filling up my NAS with backups, but so far it seems determined to do-so no matter what.

Since Time Machine fails spectacularly with Linux disk quotas, using partitions isn't an option (even if my NAS let me, it's too late to set it up now), I decided to try resizing the disk image using hdiutil resize, which seems to be a common suggestion.

This did seem to work for a while, but as of today Time Machine has inexplicably decided that it knows better than me, and as such the first thing it does is immediately resize the image so that it will inevitably fill all free space on the drive.

As you can imagine this is infuriating, as I'm trying to backup multiple machines on my NAS, but it also runs a few services and other things as well, so I can't have it running out of space.

Is there some way to limit the size of Time Machine's sparse bundle, such that it won't just immediately resize it again?

2 Answers 2


There is a preference setting for that. All you need to do is specify, in megabytes, your desired maximum space limit. In Terminal, enter the following command and replace xxx with your desired size limit.

sudo defaults write /Library/Preferences/com.apple.TimeMachine MaxSize xxx

  • Does this apply to all backup destinations? I also have a direct attached backup drive, in addition to my NAS, but the NAS has more limited space as it's shared between multiple machines.
    – Haravikk
    Commented Jul 31, 2019 at 22:23
  • I can't say for certain. However, it is a preference setting that is global to the app. So my guess would be that the size limit would apply to all backup destinations. If you need different limits depending on the destination, then you are going to have to set the limit at the destination itself. If you have a Synology NAS then maybe you could set up a shared folder as outlined here: dongknows.com/…
    – user128998
    Commented Aug 1, 2019 at 19:25
  • Unfortunately the quota system on Synology DSM is unsuitable for this, as Time Machine somehow exceeds it then fails to clear up space. This is why I've been trying to set limits on the image size instead. I guess the next thing I'll try is adding a tiny non-HFS partition to the end of the image, so it shouldn't be able to be resized.
    – Haravikk
    Commented Aug 2, 2019 at 11:33
  • That will be a clever solution if it actually works. Here’s hoping!
    – user128998
    Commented Aug 2, 2019 at 21:02

For Mac OS Catalina, as suggested by @Haravikk, I've confirmed that if you modify the disk image created by Time Machine to have a size limit and a small extra partition, Time Machine will not be able to expand the disk image.

Here are the steps:

  • Mount a network disk using AFP to be your Time Machine volume. (Use afp://yourothercomputer.local from Finder menu Go->Connect To Server)
  • In Time Machine preferences, choose this volume as your Time Machine disk
  • Wait for Time Machine to create the disk image file (ComputerName.backupbundle) and start backing up to it
  • You can now stop Time Machine (skip this backup and turn off automatic backups for now)
  • Resize the disk image to 1000GB or whatever you want: run this command in terminal:

hdiutil resize -size 1000g /Volumes/<YourTMBackupDisk>/<Computer Name>.backupbundle

  • To prevent Time Machine from resizing it again, double click on the .backupbundle file to mount it (on a Catalina machine)
  • Open Disk Utility and select the "Time Machine Backups" disk image and click the "Partition" button
  • Now you want to add a small partition by clicking the "+" and make the new Untitled partition small like 10 MB
  • Change the Untitled partition format to MS-DOS (FAT) then hit Apply
  • Once saved, eject the "Time Machine Backups" disk
  • Start time machine again and now this should work to prevent time machine from expanding

Now I have my encrypted time machine backup images limited to the size I want!

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .