Windows – Server 2008/2012 (R2) group policy scheduled task not applying

active-directorygroup-policywindows

I am at wit's end and totally confused. The goal is to take group policies(one per day of a week) and set a scheduled task which will trigger a reboot on that day at a specific time.

So I made them (see example below) yet…..they don't work? I've done additional manual reboots of the servers, gpupdate /force on the servers, changed the GPO from 'create' to 'update', and nothing seems to make them actually get applied.

enter image description here
enter image description here
enter image description here
enter image description here

My two questions are:

  1. What am I doing wrong? I just want to schedule graceful restarts on a recurring pattern through group policy (other options are welcome, I guess)
  2. How can I fix it or acheive the same end result?

Goal is simply to: Set policyGPO from AD to reboot servers on certain days, push scheduled tasks to each server the GPO is attached to, have the servers run their received scheduled task going forward.

Edit – gpresult /H
enter image description here

Best Answer

The scheduled task must be created in the GPO's console while sitting in the same OS core version that you will target. In example for 2008R2 you need to edit with a 2008R2 server or to use the RSAT tool on a Windows 7.

At each new OS version they add new scheduled task settings, and thus the task become not valid if the GPO target a OS that does not know those settings. (and thus does not apply)

If you have a mixed OU for your server you can use a WMI filter to target the correct OS with your GPO, like;

For Windows 2008R2 server

select * from Win32_OperatingSystem where Version like "6.1%" and ProductType = "2" 

For Windows 2012R2

select * from Win32_OperatingSystem where Version like "6.2%" and ProductType = "2"