For those that are backing up OS X clients, you may have noticed that 10.8 Mountain Lion and later is much more militant about having machines sleep. Even if you issue a WOL packet to start a backup, they still fall back asleep pretty quickly unless there’s someone actually using the mouse and keyboard. It doesn’t really matter what you have the sleep timer set to.
Apple’s strategy seems to be that programs that need to run must issue a “power assertion” to the system, indicating that the system must stay awake for them complete their task. Fortunately, it’s easy enough to issue one of these manually using the command line. In my job definition (in the Bacula director configuration) I’ve added this line to my Mac clients: Client Run Before Job = "/usr/bin/screen -d -m /usr/bin/caffeinate -i -t 3600; sleep 0;” The first part, using the “screen” command, puts the command in the background. The “caffeinate” command is new for 10.8 and later, and will keep the system awake for 3600 seconds. (Edit to suit your needs.) If you’re backing up 10.7 or earlier systems, they won’t have the caffeinate command, so trying to issue it will fail and thus your backup would fail. That’s why there’s the “sleep 0” part at the end. It ensures you’ll always exit this command with a success (0). Hopefully this will help someone else that gets stuck when a Mac backup starts but then fails, usually taking about 2 hours before the director will give up and move on. Windows 7 seems to have a similar issue. I was able to solve that by editing a registry value as below: [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Power\PowerSettings\238C9FA8-0AAD-41ED-83F4-97BE242C8F20\7bc4a2f9-d8fc-4469-b07b-33eb785aaca0\DefaultPowerSchemeValues\381b4222-f694-41f0-9685-ff5bb260df2e] "AcSettingIndex"=dword:00000e10 [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Power\PowerSettings\238C9FA8-0AAD-41ED-83F4-97BE242C8F20\7bc4a2f9-d8fc-4469-b07b-33eb785aaca0\DefaultPowerSchemeValues\8c5e7fda-e8bf-4a96-9a85-a6e23a8c635c] "AcSettingIndex"=dword:00000e10 [HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Power\PowerSettings\238C9FA8-0AAD-41ED-83F4-97BE242C8F20\7bc4a2f9-d8fc-4469-b07b-33eb785aaca0\DefaultPowerSchemeValues\a1841308-3541-4fab-bc81-f71556f20b4a] "AcSettingIndex"=dword:00000e10 Cheers! -Joe Rhodes
smime.p7s
Description: S/MIME cryptographic signature
------------------------------------------------------------------------------ CenturyLink Cloud: The Leader in Enterprise Cloud Services. Learn Why More Businesses Are Choosing CenturyLink Cloud For Critical Workloads, Development Environments & Everything In Between. Get a Quote or Start a Free Trial Today. http://pubads.g.doubleclick.net/gampad/clk?id=119420431&iu=/4140/ostg.clktrk
_______________________________________________ Bacula-users mailing list Bacula-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/bacula-users