Problems using rsync and launchd

Joined
Dec 13, 2009
Messages
1
Reaction score
0
Points
1
I have a computer at work that I would like to backup. I only need to backup a couple of folders, and I won't be connected to any external drives except for an 8GB usb stick. I have a 13" Macbook Pro.

I have had reasonable success with this using rsync and launchd. But there are a few quirks. For instance, the following launch agent spawns TWO rsync processes that run continuously and eat up around 30% of my CPU. Does anybody know why there are two processes, why they run continuously, or why they eat up so much power when they are copying nothing?

It seems to be copying all the files over and over again every ten minutes, despite the fact that they haven't changed. My entire reason for using rsync was to get avoid this.

Also, I don't want to use chronosync, time machine, or any other third party software. I'm not that kind of guy.

Any help at all would be appreciated.

Code:
<plist version="1.0">
<dict>
        <key>Label</key>
        <string>USB backup</string>
        <key>ProgramArguments</key>
        <array>
                <string>/usr/bin/rsync</string>
                <string>-a</string>
                <string>/Users/alan/Documents/school/</string>
                <string>/Volumes/ALAN8G/backUp/school</string>
        </array>
        <key>RunAtLoad</key>
        <true/>
        <key>StartInterval</key>
        <integer>600</integer>
</dict>
</plist>
 
Joined
Feb 8, 2005
Messages
315
Reaction score
6
Points
18
Looks like you need something in there to check for differences, then copy if yes, and close down the process when complete. Use a cron job to spawn the process versus running at boot.
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top