Kaseya Community

Active Directory Replication Monitoring

  • Hi all,

    Before i lock myself in a dark room for three days to write something from scratch, has anyone been able to effectively monitor the state of Active Directory in situations where there are more than one domain controller?

    Id like to be able to keep tabs on the replication between the domain controllers.

    Any assistance greatly appreciated.

    Cheers

    Commander

    Legacy Forum Name: Active Directory Replication Monitoring,
    Legacy Posted By Username: Commander
  • I surely hope you don't spend three days locked in a dark room trying to figure this out...

    That would have horrible affects on the health of your eyes...


    anyways give this .vbs a shot


    strComputer = "."
    Set objWMIService = GetObject("winmgmts:" _
    & "{impersonationLevel=impersonate}!\\" & _
    strComputer & "\root\MicrosoftActiveDirectory")

    Set colReplicationOperations = objWMIService.ExecQuery _
    ("Select * from MSAD_ReplNeighbor")

    For each objReplicationJob in colReplicationOperations
    Wscript.Echo "Domain: " & objReplicationJob.Domain
    Wscript.Echo "Naming context DN: " & objReplicationJob.NamingContextDN
    Wscript.Echo "Source DSA DN: " & objReplicationJob.SourceDsaDN
    Wscript.Echo "Last synch result: " & objReplicationJob.LastSyncResult
    Wscript.Echo "Number of consecutive synchronization failures: " & _
    objReplicationJob.NumConsecutiveSyncFailures
    Next


    Legacy Forum Name: Monitor Sets,
    Legacy Posted By Username: thirteentwenty