Setup a size limit for Time Machine backup volumes

Time Machine will standard use all the available disk space on an external drive or a external server volume. You can setup a limit how much disk space Time Machine may use. Use this defaults write Terminal command:

defaults write /Library/Preferences/com.apple.TimeMachine MaxSize 405600

Where MaxSize 405600 is the MB equivalent of 400GB (400 * 1024)

To remove the limit:

defaults delete /Library/Preferences/com.apple.TimeMachine MaxSize

12 thoughts on “Setup a size limit for Time Machine backup volumes”

  1. Thanks for the opportunity to ask some questions.

    I am familiar with Linux but am totally unfamiliar with writing command line instructions to my MacBook Pro (vintage mid-2010). It is running 10.8.2.

    I recently installed an Iomega EZ 2TB NAS (of sorts). It does not provide for partitions on the drive. I wish to also backup my Dell running XP SP3 to this same drive, but am concerned that eventually the Mac will chew up all available space.

    Reluctantly, and with great trepidation, I copied your command line instruction to set maxsize and pasted it onto my command line, after changing directory to /.

    I got back the following: defaults[600:707] Could not write domain /Library/Preferences/com.apple.TimeMachine; exiting

    1. It appears the system did not like what I entered.

    2. Did I do any damage, leave in bad vibes?

    3. What should I have done?

    Many thanks,
    Steve

    • Same here.

      The command no longer works with 10.8.x … the pref file does not exist anymore.

      Any ideas how to set the limit anyway?

      Bests

  2. The command does work with 10.8.
    I’ll wait and see what my TM does 😉

    Tried using sudo?

    Regards.

  3. I got the same error as above (I have 10.7), but adding sudo to the beginning of the line appears to have gotten the job done. Like Daniel says, now it’s time to just see what TM does.

  4. there is easier way (in my point of view). i got also nas with over 4 tb space. i created user mac-backup on my nas. in user preferences i limited disk usage to 300gb. when time maschine connected to my nas using mac-backup as login it said that there is only 300gb free space.

    to be honest this post took me more time than configure my nas.

    Regards.

    • This is most certainly the easiest way to do it if you can assign disk quotas to users. Cheers!

  5. I do not believe this works. I’m testing under 10.8.3. I have the value set to 307200 (which should be 300 GB):

    $ defaults read /Library/Preferences/com.apple.TimeMachine MaxSize
    307200

    However, the Finder reports the size of the sparsebundle as 317 GB. I’m running du on the contents of the backup directory right now to be sure, but that’ll take ages. If that finishes with a value less than 300 GB, I’ll post back, but otherwise, I don’t think this key is observed any more.

    • Well, du came in overnight with a report back of 289 GB, so my earlier report isn’t accurate… yet. Will come back with a conclusive report once that pushes 300 GB.

Comments are closed.