HPMST Honored Contributor.
Honored Contributor.
620 views

How to monitor time sync between active directory and other servers

Jump to solution

Dear all,

I want to monitor the time sync in windowes servers between the windowes servers and active directory server 

thansk all fo your support 

0 Likes
1 Solution

Accepted Solutions
Outstanding Contributor.. Gediminas Daniu Outstanding Contributor..
Outstanding Contributor..

Re: How to monitor time sync between active directory and other servers

Jump to solution

you can look for indicators like Time Synch Error is not equal to 0 or Last Successfull time is e.g. > 7 days. 

e.g.
Last Successful Sync Time: 2/5/2019 9:33:57 AM
Last Sync Error: 0 (The command completed successfully.)

It could be enough for monitoriong. If you want to get more sophisticated monitorong, use command to get time difference (offset) e.g.

>w32tm /stripchart /computer:time.windows.com /samples:1
Tracking time.windows.com [13.65.245.138:123].
Collecting 1 samples.
The current time is 2/5/2019 11:48:41 AM.
11:48:41 d:+00.2340005s o:-00.0151106s  [                           *

 

7 Replies
Micro Focus Frequent Contributor
Micro Focus Frequent Contributor

Re: How to monitor time sync between active directory and other servers

Jump to solution

Hi HPMST!

Can you explain in more detail what you'd like to achieve. Do you'd like to monitor the sync time of your events from windows and AD nodes? Please share more details.

Christian

0 Likes
HPMST Honored Contributor.
Honored Contributor.

Re: How to monitor time sync between active directory and other servers

Jump to solution

Dear Christian,

thanks alot for your support and reply:

What I want to achive to monitor if there is windows server is not time synced with it's active directoy

for example if I have one server joined the domain and this server show tim for example 10:00:00AM and the correct time in the active directoy server show 7:00:00AM 

I want to triger event in that case  

0 Likes
Highlighted
Outstanding Contributor.. Mohd_25 Outstanding Contributor..
Outstanding Contributor..

Re: How to monitor time sync between active directory and other servers

Jump to solution

I haven't done this, But may be you could make use of the w32tm command to check

w32tm /query /configuration

Will give the information regarding your current time configuration. You can schedule this or customize it to to create alerts.

HPMST Honored Contributor.
Honored Contributor.

Re: How to monitor time sync between active directory and other servers

Jump to solution

Dear Mohd,

thanks alot for your reply I try this command before but the issue which parameter that show the server is out of sync 

C:\Windows\system32>w32tm /query /configuration
[Configuration]

EventLogFlags: 2 (Local)
AnnounceFlags: 10 (Local)
TimeJumpAuditOffset: 28800 (Local)
MinPollInterval: 10 (Local)
MaxPollInterval: 15 (Local)
MaxNegPhaseCorrection: 4294967295 (Local)
MaxPosPhaseCorrection: 4294967295 (Local)
MaxAllowedPhaseOffset: 300 (Local)

FrequencyCorrectRate: 4 (Local)
PollAdjustFactor: 5 (Local)
LargePhaseOffset: 50000000 (Local)
SpikeWatchPeriod: 900 (Local)
LocalClockDispersion: 10 (Local)
HoldPeriod: 5 (Local)
PhaseCorrectRate: 1 (Local)
UpdateInterval: 30000 (Local)


[TimeProviders]

NtpClient (Local)
DllName: C:\Windows\system32\w32time.dll (Local)
Enabled: 1 (Local)
InputProvider: 1 (Local)
CrossSiteSyncFlags: 2 (Policy)
AllowNonstandardModeCombinations: 1 (Local)
ResolvePeerBackoffMinutes: 15 (Policy)
ResolvePeerBackoffMaxTimes: 7 (Policy)
CompatibilityFlags: 2147483648 (Local)
EventLogFlags: 0 (Policy)
LargeSampleSkew: 3 (Local)
SpecialPollInterval: 3600 (Policy)
Type: NT5DS (Policy)

VMICTimeProvider (Local)
DllName: C:\Windows\System32\vmictimeprovider.dll (Local)
Enabled: 1 (Local)
InputProvider: 1 (Local)
NtpServer (Local)
DllName: C:\Windows\system32\w32time.dll (Local)
Enabled: 0 (Local)
InputProvider: 0 (Local)

0 Likes
Outstanding Contributor.. Gediminas Daniu Outstanding Contributor..
Outstanding Contributor..

Re: How to monitor time sync between active directory and other servers

Jump to solution

Better use "status" option:

w32tm /query /status
Leap Indicator: 0(no warning)
Stratum: 5 (secondary reference - syncd by (S)NTP)
Precision: -6 (15.625ms per tick)
Root Delay: 0.2187500s
Root Dispersion: 7.9641171s
Last Successful Sync Time: 2/5/2019 9:33:57 AM
Source: xxx
Poll Interval: 10 (1024s)

or add "verbose"

C:\Users\GEDAN>w32tm /query /status /verbose

Leap Indicator: 0(no warning)
Stratum: 5 (secondary reference - syncd by (S)NTP)
Precision: -6 (15.625ms per tick)
Root Delay: 0.2187500s
Root Dispersion: 7.9641171s
Last Successful Sync Time: 2/5/2019 9:33:57 AM
Poll Interval: 10 (1024s)

Phase Offset: 0.0076008s
ClockRate: 0.0156001s
State Machine: 1 (Hold)
Time Source Flags: 2 (Authenticated )
Server Role: 0 (None)
Last Sync Error: 0 (The command completed successfully.)
Time since Last Good Sync Time: 761.5827306s

my 2 cents
Gedas

HPMST Honored Contributor.
Honored Contributor.

Re: How to monitor time sync between active directory and other servers

Jump to solution

Dear Gediminas,

thanks for your reply but it is not clear for me which parameter that show the server is out of Sync ?

0 Likes
Outstanding Contributor.. Gediminas Daniu Outstanding Contributor..
Outstanding Contributor..

Re: How to monitor time sync between active directory and other servers

Jump to solution

you can look for indicators like Time Synch Error is not equal to 0 or Last Successfull time is e.g. > 7 days. 

e.g.
Last Successful Sync Time: 2/5/2019 9:33:57 AM
Last Sync Error: 0 (The command completed successfully.)

It could be enough for monitoriong. If you want to get more sophisticated monitorong, use command to get time difference (offset) e.g.

>w32tm /stripchart /computer:time.windows.com /samples:1
Tracking time.windows.com [13.65.245.138:123].
Collecting 1 samples.
The current time is 2/5/2019 11:48:41 AM.
11:48:41 d:+00.2340005s o:-00.0151106s  [                           *

 

The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.