PowerShell Genie

AD Sync PowerShell commands for Microsoft Entra Connect

Lesson 2 min read Windows PowerShell 5.1 and PowerShell 7

Documentation: Microsoft Learn

An example to inspect

Preview the example. Sign in for the full lesson and activities.

Get-ADSyncScheduler | Select-Object SyncCycleEnabled, StagingModeEnabled, SyncCycleInProgress
Inspect this example’s structure

Read the command and its supplied arguments. This example requires real PowerShell or its module; this diagram does not execute it.

Get-ADSyncScheduler | Select-Object SyncCycleEnabled, StagingModeEnabled, SyncCycleInProgress
  1. Stage 1Get-ADSyncSchedulerPositional values or no named parameters
  2. Stage 2Select-ObjectPositional values or no named parameters

    Inspect a sample

    1PS> Get-ADSyncScheduler | Select-Object SyncCycleEnabled, StagingModeEnabled, SyncCycleInProgress

    Example reader

    Inspect this page's example

    Fictional browser data when supported

    Run supported commands against the practice data, or inspect the example without executing it.

    Ready to inspect.

      Show reference output
      1 SyncCycleEnabled StagingModeEnabled SyncCycleInProgress
      2 ---------------- ------------------ -------------------
      3 True False False

      Inspect the scheduler first

      Confirm the server and scheduler state. A running cycle, disabled schedule or staging configuration changes what a new request will do. Record the affected object and the attribute change you expect before triggering another cycle.

      Choose the appropriate cycle

      Delta processes changes through import, synchronization and export. Initial requests a full cycle and can take substantially longer. Use a full cycle for a justified configuration or diagnostic requirement rather than making it the default response to every delay.

      Verify completion and object state

      Inspect synchronization run history and connector errors after the request. Then inspect the intended cloud object and attribute. A request accepted by Start-ADSyncSyncCycle does not establish that a connector export succeeded or that all downstream applications have refreshed.

      Handle a stalled or rejected request

      Check for an existing cycle and investigate its state before submitting more work. Resolve the connector-specific failure, such as scope, attribute conflict or authorization. Avoid repeatedly changing scheduler settings when the underlying object cannot export.

      Use the correct product guidance

      These commands concern Microsoft Entra Connect Sync. Entra Cloud Sync has a different agent and management model. Keep the product name, server identity, observation time and affected object in the incident record so another administrator can reproduce the diagnosis.

      Command-line reference

      1PS> # Run on the approved Entra Connect Sync server:
      2PS> Start-ADSyncSyncCycle -PolicyType Delta
      3PS> # A full cycle is a separate, deliberate operation:
      4PS> # Start-ADSyncSyncCycle -PolicyType Initial

      The code above is a reference for your own authorized environment. The Run sample button shows only the stored fictional inspection result.

      Read the original documentation

      ADSync scheduler · ADSync command reference

      Primary documentation

      Microsoft 365, Entra and Azure documentation

      Keep going

      Next: PowerShell Remoting
      Genie guideAD Sync PowerShell commands for Microsoft Entra Connect

      Preview the example. Sign in for the full lesson and activities.