Document Replication Schedule of Active Directory Connection Object

This is a PowerShell script to document the replication schedule assigned to a connection object. The script documents the schedule attribute of the object in Active Directory. The schedule attribute is a byte array with one byte for every hour of every day of a week.

GetSchedule.ps1
 
 
 
 
 
(0)
740 times
Add to favorites
Active Directory
10/26/2018
E-mail Twitter del.icio.us Digg Facebook
  • $Sched[] Values
    2 Posts | Last post November 17, 2018
    • Richard,
      
      I came across this script while researching topology manipulation for a project of mine. Do you have any insight into the meaning of the first 20 bytes of the schedule blob? The first byte (or maybe two) appear to be the length but the rest seems prety much static.
      
      Any info / links would be appreciated.
      
      Regards,
      
      Evgenij
    • The first byte, byte[0], is the number of bytes in the array (188). Byte[8] is the number of schedules, always 1. Byte[16] is the offset to the beginning of the actual schedule (20). All other bytes of the header are 0. The schedule itself is in byte[20] through byte[187]. The reference I used was:
      
      https://docs.microsoft.com/en-us/windows/desktop/api/schedule/ns-schedule-_schedule_header
      But it has been modified since I published the Wiki, and no longer has this detail. The best source now (other than inspection of the actual schedule attribute array) is:
      https://docs.microsoft.com/en-us/windows/desktop/api/schedule/ns-schedule-_schedule