Timely machine restart

New Contributor

Dear Community!


I am having a hard time finding a solution for scheduled machine restarts. I have plenty of mac devices in my fleet and my users tend not to restart their machines once in a while so I wish to set a two week / 1 restart schedule for instance every second week wednesday 17:00 in the afternoon - so they dont come complaining that they are out of memory and their machines are slowing by the day. 

Does anyone have any ideas on how to do this? I even wish to have a countdown and a notification to save everything because your machine will automatically reboot in 30 minutes (for instance). 


Is this possible to do in Jamf? 


Thank you in advance!



New Contributor III
New Contributor III

you have a few options here.  

first would be a config profile that has a startup/shutdown schedule - yet you can't provide options to the end user here.

next would be a policy that has just the restart options configured to your liking with the timer - the policy can have a recurring timeline for execution and also be limited to running at certain times of day via server/client side limitations in the policy - you can also configure user deferral for this.

another would be a policy that runs the restart command(or a script) with a user deferral message/timeline similar to the above options.


New Contributor


I guess you can make a policy:
In the Computers pane -> Policies -> New Policy -> Restart Options. Select whatever is appropriate for your fleet.

In the "user interaction" pane under you can set the deferral type to "duration" and set the number of days you want.

A warning message should pop-up to users. 

Back to the General pane:

I belive "Recurring Check-in" would be the right trigger. However, I am not sure how to get this to run every Wednesday, but you can make the policy run once a week, once a month in the "Execution Frequency" option. 
Also it might look like you can tick off the rest of the days in the week you DON'T want the policy to run in the "client-side limitation". (I have not tested this pane myself, so I would try before pushing it out.) 

Hope this points you further on to the goal!  


New Contributor II

I use a rebranded IBM notifier app for this.
I have a policy that is scoped to machines with 13 days uptime which presents the user with a pop up as show here: https://monosnap.com/file/sRPTun0eiLg7ctJM8XxsuCP7m4gBFQ 
The policy is a command line with parameters and underneath that i just run shutdown -r +5 which will auto restart the machine after 5 mins.

New Contributor III
New Contributor III

@cgssi this is a great way to do this.  I like what you did there.

New Contributor

Do you know if/how that could be setup with an interactive deferal?

New Contributor II

You could initially set it to run the policy but allow the user to decide if they reboot or not. Give them two buttons to click "Restart Now", "Restart Later". With Restart Later you could end the script or use it to kick off a delay of your choosing

Valued Contributor II

I have a policy to force reboot devices with a 1 day deferral targeting devices with a 7day up time. If the reboot comes at a bad time users can bump it back 1 day. Since its targeting uptime, custodial users that reboot on their own never see this policy run. I am not too concerned as to when the policy triggers due to the deferral option users have, but you could configure a policy not to run in certain time windows.



Could you please share the process (if you allowed to share) this kind of method would do good for me. Thank you! 

Valued Contributor II

Sure, the nuts and bolts are below.


  • Extension attribute that reads a devices uptime
  • Smart group that is looking for the uptime to be greater than 7 days
  • A policy targeting that 7 day uptime group to issue a FileVault auth reboot
    • The policy has a 1 day user deferral in the user interaction tab


Extension Attribute:


dayCount=$( uptime | awk -F "(up | days)" '{ print $2 }' )

if ! [ "$dayCount" -eq "$dayCount" ] 2> /dev/null ; then

echo "<result>$dayCount</result>"

exit 0