The following command works without difficulty, note the sudo in its midst:
- Code: Select all
cd ~/Documents/com/github/jollyjinx/ZFS-TimeMachine/028ba53 && sudo ./zfstimemachinebackup.perl --sourcepool=gjp22 --destinationpool=tall/backups/gjp22 --createsnapshotonsource --recursive --verbose
With limited knowledge, I'm trying to use launchd with the .perl script. Here's how the .plist looks:
- Code: Select all
macbookpro08-centrim:~ gjp22$ defaults read /Library/LaunchAgents/com.github.jollyjinx.ZFS-TimeMachine~gjp22
{
Debug = 1;
Label = "com.github.jollyjinx.ZFS-TimeMachine~gjp22";
ProgramArguments = (
"/Volumes/gjp22/Documents/com/github/jollyjinx/ZFS-TimeMachine/028ba53/zfstimemachinebackup.perl",
"--sourcepool=gjp22",
"--destinationpool=tall/backups/gjp22",
"--createsnapshotonsource",
"--recursive"
);
StartInterval = 300;
}
The problem
In response to any scheduled or manual attempt to start the job:
- Code: Select all
2012-12-19 21:24:47.246 com.apple.launchd[1]: (com.github.jollyjinx.ZFS-TimeMachine~gjp22[43226]) Exited with code: 2
The loaded job
- Code: Select all
macbookpro08-centrim:~ gjp22$ sudo launchctl list com.github.jollyjinx.ZFS-TimeMachine~gjp22
{
"Label" = "com.github.jollyjinx.ZFS-TimeMachine~gjp22";
"LimitLoadToSessionType" = "System";
"OnDemand" = true;
"LastExitStatus" = 512;
"TimeOut" = 30;
"ProgramArguments" = (
"/Volumes/gjp22/Documents/com/github/jollyjinx/ZFS-TimeMachine/028ba53/zfstimemachinebackup.perl";
"--sourcepool=gjp22";
"--destinationpool=tall/backups/gjp22";
"--createsnapshotonsource";
"--recursive";
);
};
Please, what am I doing wrong?