Skip to main content
Question

Utilizing Softwareupdate Command


Forum|alt.badge.img+8
  • Contributor
  • 30 replies

Hello Everyone,

I have been using the built in macOS update function to get devices from 10.13.5 to 10.13.6 via Terminal. I figured I could create a policy that uses executes the command

sudo softwareupdate -iaR

in order to pull down the OS upgrade and also whatever is sitting in the App Store in a pending state. For some reason I am having no luck. For reference, this works fine via Terminal as well as pushing out a UNIX command in ARD.

5 replies

bpavlov
Forum|alt.badge.img+18
  • Esteemed Contributor
  • 1206 replies
  • August 2, 2018

What do you mean by having no luck? What's happening?

Also you do not need sudo in your command. Jamf runs policies with root privileges already.


Forum|alt.badge.img+8
  • Valued Contributor
  • 126 replies
  • August 3, 2018

I found using :

#!/bin/sh
softwareupdate -ia -R

works better


AVmcclint
Forum|alt.badge.img+21
  • Esteemed Contributor
  • 1043 replies
  • August 3, 2018

I have seen that if I don't specifically download the updates first before running the -ia switch, it might sometimes fail. What I've done is create a policy that runs in the background to only run softwareupdate -d -a at check in. This makes sure that the applicable updates are already waiting to be installed and it means the user doesn't have to wait for the downloads. Then I put a policy in Self Service that runs softwareupdate -i -a That makes the process visible to the user go faster. I will have to remember the -R switch once we go to 10.13.


bpavlov
Forum|alt.badge.img+18
  • Esteemed Contributor
  • 1206 replies
  • August 3, 2018

@Ricky @BOBW @AVmcclint Since we're on the topic, figured I'd plug this feature request: https://www.jamf.com/jamf-nation/feature-requests/7285/add-softwareupdate-restart-support which deals with this new flag in 10.13.4+.


Forum|alt.badge.img+8
  • Valued Contributor
  • 126 replies
  • August 6, 2018

upvoted the feature request :)


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings