Skip to main content

Microsoft OneDrive Sync Status DV

Summary

This document outlines a script designed to collect OneDrive sync status information from Windows machines exclusively for Non-SharePoint Linked Sites. The script leverages the Onedrive.dll module to retrieve the requisite data. It is crucial to note that the script necessitates an active user session on the computer to operate effectively.

Sample Run

Sample Run

Dependencies

Global Parameters

NameDefaultRequiredDescription
ODFolderC:/Windows/LTSvc/Packages/ODFolderTruePath to write and execute the PowerShell script.
ODFileC:/Windows/LTSvc/Packages/ODFolder/ODFile.ps1TrueFull path of the PowerShell script.

Script States

NameExampleDescription
OneDriveSyncStatus"Sync Status for "ramkishor" for "C:/Users/ramkishor/OneDrive/Desktop" is "Synced"; "Sync Status for "ramkishor" for "C:/Users/ramkishor/OneDrive/Documents" is "Synced"; "Sync Status for "ramkishor" for "C:/Users/ramkishor/OneDrive/Pictures" is "Not Synced";"Stores the result returned by the PowerShell script checking the OneDrive status on the endpoint.
OneDriveSyncStatusScriptruntime2023-10-26 11:51:02Stores the data collection time

Output

  • Script log
  • Script states