10.12.4 + Auto Upgrade with not logged in user

New Contributor

Hello, Apple has changed something in the way osinstall works since 10.12.4. There is a workarround for selfservice.


But i have the need to get this to work automatically after a pmset during weekend on some hundreds of macs. It is not working because the jamfHandler does not like a logged out status. I found that info here


Can anyone help me to get this script to work in a logged out status. I always get errors if try to comment out the handler.

regards Lars


New Contributor III

Hi Lars,

If you mean the script from here:


and you are disabling the jamfhelper references near the top of the script, then I think you will need to remove the pid reference for jamfhelper as well in the last line...

##Start macOS Upgrade

/Users/Shared/Install macOS Sierra.app/Contents/Resources/startosinstall --volume / --applicationpath /Users/Shared/Install macOS Sierra.app --nointeraction --pidtosignal $jamfHelperPID &

exit 0

New Contributor III

Oh, just saw this:

As of macOS 10.12.4 and later, this workflow has changed slightly. Please visit the GitHub repo for an updated version of this workflow.


New Contributor

Hi SimonCU,

yes this is the script, but in v2.0.7. Here is a new one 2.1.1 https://github.com/kc9wwh/macOSUpgrade/releases.

My problem is that i have tried to disabling the references and i have removed the --pidtosignal $jamfHelperPID &. I get not a really good output. I´m not the scripting crack.

I have now

##Begin Upgrade

/Applications/Install macOS Sierra.app/Contents/Resources/startosinstall --applicationpath "/Applications/Install macOS Sierra.app" --nointeraction /bin/sleep 3

and get this in the log

Running script Install_Sierra_test...
Script exit code: 0
Script result: mkdir: /usr/local/jamfps: File exists
Error: __28-[OSISClient targetForPath:]_block_invoke, Couldn’t communicate with a helper application. Error: could not find target... By using the agreetolicense option, you are agreeing that you have run this tool with the license only option and have read and agreed to the terms.
If you do not agree, press CTRL-C and cancel this process immediately.