Jump to content

Rsync question with iphoto


squirrellydw

Recommended Posts

I do this for my Lightroom catalog with this command:

 

rsync -avhPE --delete --exclude *Previews.lrdata --exclude .DS_Store /path/to/backup/folder/ root@unraid:/mnt/user/photo

 

Assuming I have a passwordless key login working, this is a non-interactive command. --delete keeps the unraid backup as a mirror, so files I delete locally get deleted on the backup. I have a couple filename patterns that are excluded as well, for example all the previews I don't need taking up more space.

 

The -a archive option takes care of a bunch of metadata things I believe, but someone please suggest if you've more appropriate arguments to pass to rsync.. I'm a bit paranoid about all the right Mac filesystem attributes getting properly copied. Bombich has an article about the flags for a verifiable Mac backup but I find most of those options no longer exist or have been encompassed in other options.

 

 

If you want to run this regularly, you can wrap this in a shell script and then make a LaunchAgent or LaunchDaemon for it to run at a scheduled interval.

Link to comment

There's a lot of rsync GUIs out there, if you google it.

 

There's also Platypus, a wrapper for turning a script into an app. My "script" is literally just one line, aside from the header:

 

#!/bin/sh

 

rsync command

 

 

Once in a while I just open terminal and type "photo-sync.sh" which is what I named my script, and placed it in /usr/local/bin. Or, you can paste the rsync command into a plain text editor, save it with a ".command" extension, and Finder should recognize it — you might need to set its permissions to executable. Then it's a double-click. You can make it automatically run at login, put it in your dock, whatever.

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...