Time Sync Compliance
Summary
This monitor will sync the machine's time with us.pool.ntp.org.
Monitor
- 
Navigate to Endpoints>Alerts>Monitors 
- 
Click the Create Monitorbutton.
- 
This screen will appear.  
- 
Name: Time Sync Compliance 
 Description: This monitor will sync machine time with us.pool.ntp.org.
 Type: Script
 Family: Desktop Operating System
 Severity: Others
- 
The Conditionstab will start looking like this: 
- 
Set the Repeat everyto24Hours:
- 
Disable the Ticket Resolutionsection by clicking theAutomatically resolvebutton.
- 
Paste this PowerShell script in the Scriptbox.$S = 'W32Time';
 $peerList = 'us.pool.ntp.org';
 $syncOutput = '';
 if ((Get-Service $S).Status -ne 'Running')
 {Try
 {Start-Service $S -Confirm:$False -ErrorAction Stop | Out-Null}
 catch
 {return "Failed to start $S Service. Reason: $($Error.Exception.Message)"}
 };
 $syncOutput += w32tm /config /manualpeerlist:$peerList;
 Start-Sleep -Seconds 5;
 $syncOutput += "`n" + (W32tm /resync /force);
 if ($syncOutput -match 'The computer did not resync')
 {return 'Failed: The computer did not resync.'}
 else
 {return 'Success: The computer resynced successfully.'}
- 
Set Failedto theScript Outputbox.
- 
Select the required client or group to target from the Select Targetsbutton.
  
- 
Monitors Final Look  
- 
Click the Savebutton to save the monitor set.