Script to disable automatic updates

yelnats126
New Contributor

We are looking to push out a script to disable automatic updates on Apples. Does anyone have a step by step walkthrough on how to do this? If not, does anyone have one they already use that we can take a look at?

Thank you.

7 REPLIES 7

bbass
Contributor

This defaults command should do it:

/usr/bin/defaults write /Library/Preferences/com.apple.SoftwareUpdate 'ScheduleFrequency' -int -1

The easy thing to do would be to create a policy that simply runs that command.

Matt
Valued Contributor

You can set a Managed Preference through the JSS.Just goto Managed Preferences -> Create from Template -> Search for com.apple.SoftwareUpdate and follow the instructions provided to set it up.

yelnats126
New Contributor

We have decided to post push a script out that will force all clients to hit the update server instead.
This is what we need pushed out.

defaults write /Library/Preferences/com.apple.SoftwareUpdate CatalogURL http://xserve02.wbtla.net:8088/index.sucatalog

Can someone help me by letting me know how to get this script to run in JAMF? We are rookies when it comes to scripting.

yelnats126
New Contributor

We have decided to post push a script out that will force all clients to hit the update server instead.
This is what we need pushed out.

defaults write /Library/Preferences/com.apple.SoftwareUpdate CatalogURL http://xserve02.wbtla.net:8088/index.sucatalog

Can someone help me by letting me know how to get this script to run in JAMF? We are rookies when it comes to scripting.

stevewood
Honored Contributor II
Honored Contributor II

Simplest way would be to create a policy set to run every15, a frequency of once a week (or once a day if you want), and on the Advanced tab of the policy, place that command in the Run box.

No need to write an entire script for that.

bentoms
Release Candidate Programs Tester

Or add the sus to your servers from within the JSS & push out that way. (sorry not at comp so short reply).

bentoms
Release Candidate Programs Tester

Page 100 of the admin guide advises how to add a Apple Software Update Servers.