Hi Hexnode users, I have been trying to update our macs with custom script from the portal, 12.1 to 12.2 Monterey. I have been waiting for hours on end and nothings happening! The status is shown as initiated and have been so for almost 3 hours. I am so spent right now…been at it for a while now and cant seem to figure out why???
Unable to update mac with scriptSolved
Replies (9)
I know that feeling @gable-lapis, updates are tiring, apple churns out these updates and we have to ensure if its stable enough to be deployed for all. Have you tried running the script from the terminal?? What was the command again
Hi @Kipp, thank you so much, someone understands, I ran the command “ softwareupdate –ia --restart
“. Running from the terminal asks for admin password, usually running from the portal does not require a password.
Hi @gab, This is expected, --restart
requires root privilege, but you wouldn’t have to give the password from the portal.
Yea that makes sense, but I entered the password but it asked again before downloading the 12.2 update.
Wait! Are you using an intel mac or an m1 mac?? My intel device works fine without asking for any credentials, it reboots and all updates are installed without any issues.
Its an m1 macbook pro 16gb. Did I miss something?
Hi there,
Thank you for connecting with us on Hexnode Connect!
From your conversation, you might have guessed that this would be an exception for M1 devices. M1 devices require admin credentials to initiate installation action. We suggest using the fetch installer command to fetch the specific OS version of your requirement and initiate installation by passing admin credentials to your device through the script. Use the command:
1 |
softwareupdate --fetch-full-installer --full-installer-version 12.2 |
Once the installer is fetched, use the command:
1 |
echo <Password> |'/Applications/Install macOS Monterey.app/Contents/Resources/startosinstall' --agreetolicense --nointeraction --forcequitapps --user <adminuser> –stdinpass |
Pass the device admin credentials to the device by replacing <Password> and <adminuser> to execute the upgrade action without any user interaction.
Hexnode facilitates this without any user interaction using custom scripts. Please note that the script may be in the “Initiated” state for a while. Major updates are large in size and may take a while to download. Ensure your device is plugged in and has sufficient space to download updates. Feel free to reach out to us for any queries.
Regards,
Ethan Miller
Hexnode UEM
Thanks for the update, @ethan-miller. Works like a charm! You saved me from a lot of trouble…
Hi there!
I have the same problem, but the script you shared failed…
Maybe you have an idea how to solve this problem?
the Output was:
startosinstall: An extraneous argument was specified with option ‘user’
Usage: startosinstall
Arguments
–license, prints the user license agreement only.
–agreetolicense, agree to the license you printed with –license.
–rebootdelay, how long to delay the reboot at the end of preparing. This delay is in seconds and has a maximum of 300 (5 minutes).
–pidtosignal, Specify a PID to which to send SIGUSR1 upon completion of the prepare phase. To bypass “rebootdelay” send SIGUSR1 back to startosinstall.
–installpackage, the path of a package (built with productbuild(1)) to install after the OS installation is complete; this option can be specified multiple times.
–eraseinstall, (Requires APFS) Erase all volumes and install to a new one. Optionally specify the name of the new volume with –newvolumename.
–newvolumename, the name of the volume to be created with –eraseinstall.
–preservecontainer, preserves other volumes in your APFS container when using –eraseinstall.
–forcequitapps, on restart applications are forcefully quit. This is the default if no users are logged in.
–usage, prints this message.
–user, an admin user to authorize installation.
–passprompt, collect a password for authorization with an interactive prompt.
–stdinpass, collect a password from stdin without interaction.
–reducedsecurity, configure target volume’s security policy as Reduced Security (will prompt for authorization after reboot).
–cloneuser, Copy account settings for the owner provided with –user when installing to a new volume.
Example: startosinstall
-
Expand