Tip 347Start Time Machine at the Command Line

About to do something risky with a file at the command line? Here’s how to get some Time Machine goodness from the Terminal.

Taking a Backup Snapshot

Assuming your Mac has local snapshots enabled (see Tip 160, Back Up Without a Time Machine Disk), you can force Time Machine to take a snapshot of the system using the following command:

 
tmutil snapshot

Remember, this creates only a local backup on your hard disk.

Making a Full Backup

To force a full backup to take place, which involves writing files to the Time Machine disk (the equivalent of clicking the Time Machine icon at the top right of the desktop and clicking Back Up Now), type the following:

 
tmutil startbackup

You can also stop the backup ...

Get Mac Kung Fu, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.