Mac OS Updates downloading but not installing through policy

fimi
New Contributor III

Hey Everyone,

So I have a policy setup for OS Updates. All the machines are on Big Sur. So it's a policy enabled in self service to allow users to update. The Software Updates payload points to Apples Software Update Server. Then the Restart payload is on restart if a package or update requires it for both logged in and no user logged in with the current startup disk.

The policy logs show it downloads but nothing actually installs. I attached screenshot of running the policy the first time and then the second time.
6f4f5ec8efb3429aac5f2b14f7e55d2a

7a4ebea079cf4352baa00a3004b706e9

6 REPLIES 6

dasariavinash92
New Contributor II

We have gone through similar suitations. softwareupdate -diaR is working as expected but not the Restart payload

Mojinkii
New Contributor III

This is happening to us as well with Big Sur, Catalina seems to be working fine.

jumscheid
New Contributor II

i'm having this issue with Big Sur as well.  Anyone from Jamf wanting to chime in?

fimi
New Contributor III

This could probably be done way better, but here's the script I made now for our environment.

First line installs all applicable updates available, then second line interrupts the user with a button that the computer will restart. Then last line checks again to install any applicable updates with the -R flag for restart. So yes after the user clicks the restart button it will forcefully restart the machine. Though if you just want to install with no restart you can just use the -i and -a flags.

 

#!/bin/bash

sudo softwareupdate -i -a

osascript -e 'display dialog "Updates installed. Mac will now restart. Please save all your data and close all applications before clicking restart." buttons {"Restart"} default button 1'

sudo softwareupdate -i -a -R

 

jumscheid
New Contributor II

I think the challenge with this script is that running softwareupdate -iaR again won't restart the computer right away, it will try to "install" the updates again, which may be 5-10 minutes before restarting.

jumscheid
New Contributor II

I stand corrected...this script worked beautifully!! Thank you!