Change Frequency of Time Machine Backups?

12

3

Is it possible to change the frequency of when Time Machine performs its backup?

Nate

Posted 2009-09-15T02:54:00.860

Reputation: 1 661

Answers

13

You can issue this command on the command line from a terminal:

sudo defaults write /System/Library/LaunchDaemons/com.apple.backupd-auto StartInterval -int 3600

The value is in seconds, therefore calculate your interval assuming 3600 seconds per hour.

The command edits the value in /System/Library/LaunchDaemons/com.apple.backupd-auto.plist, only that you don't have to edit the file directly. This bewares you of any syntax errors you might make in that file, so I would prefer this solution.

Furthermore you need to restart for this change to take effect. I also found this thread in an Apple support forum, which indicated a permission problem in a Snow Leopard installation.

dertoni

Posted 2009-09-15T02:54:00.860

Reputation: 1 099

On 10.8, the key name appears to be BackupInterval. – trapezoid – 2014-08-21T10:23:55.143

FYI, this doesn't appear to work on Lion. – Joe Shaw – 2012-07-07T23:46:54.510

4

Or you can try an even easier approach. Time Machine Editor, it's a graphical user interface that allows you to edit some options of Time Machine.

Tiago Veloso

Posted 2009-09-15T02:54:00.860

Reputation: 1 072

3

Under /System/Library/LaunchDaemons there is an XML file called com.apple.backupd-auto.plist. Open it with your text editor of choice and find these lines:

<key>StartInterval</key>
<integer>3600</integer>

Between the integer tags is the backup interval in seconds. Change it to your liking. Just remember it's an integer, so it has a maximum (2,147,483,647 signed I believe), in case you're trying to set it obnoxiously high to avoid backups. But I doubt that's the case.

John T

Posted 2009-09-15T02:54:00.860

Reputation: 149 037

2

Just to be sure: changing the interval won't change what Time Machine keeps. It will still only keep hourly backups for the last 24 hours, all first dailies for the last month, and all first weeklies until the disk is full.

So, for example: tweaking will not save you any disk space. (You'll only notice when you change the same files a lot, and then you'll still only see the change in the hourly backups which are expired soon anyhow.) And unless you're changing the same huge files a lot, you probably won't notice a huge performance increase either, as it will simply need to backup more during each run, if you increase the interval. (But then: if you're changing the very same files a lot, then an hourly backup might be very welcome?)

(I don't know what happens if you set the interval to value less than an hour.)

Arjan

Posted 2009-09-15T02:54:00.860

Reputation: 29 084

1This does not answer the question it is just additional information. That belongs in comments. – None – 2009-09-16T12:01:53.113

2True, the introduction of my answer indeed indicated it was not meant to answer the question. (And, correct answers were already given.) Still, I don't think it should have been a comment either, as it was not meant for the question asker only, and comments are hard to be commented on by others. (And I'm just trying to share some relevant knowledge here; I doubt the comments will be read by others coming to this question in the future.) – Arjan – 2009-09-16T12:17:27.063

1

With OS X Mavericks, Apple changed the scheduling of background tasks to be managed by XPC Services, so instructions for earlier versions of OS X no longer work. The following commands will cause Time Machine to run every 3 hours on average, up from the standard 1 hour:

sudo /usr/libexec/PlistBuddy -c 'set :LaunchEvents:com.apple.xpc.activity:com.apple.backupd-auto:Interval 10800' /System/Library/LaunchDaemons/com.apple.backupd-auto.plist
sudo /usr/libexec/PlistBuddy -c 'set :LaunchEvents:com.apple.xpc.activity:com.apple.backupd-auto:Delay 10800' /System/Library/LaunchDaemons/com.apple.backupd-auto.plist
sudo /usr/libexec/PlistBuddy -c 'set :LaunchEvents:com.apple.xpc.activity:com.apple.backupd-auto:GracePeriod 5400' /System/Library/LaunchDaemons/com.apple.backupd-auto.plist

In my testing, Time Machine originally said the latest backup was at 1:39 and the next was to run at 2:38. After running these commands and rebooting, the next backup had changed to 4:19. I haven't yet found a way to make the changes apply without a reboot, though.

Eric3

Posted 2009-09-15T02:54:00.860

Reputation: 529