Collecting PowerSyncPro Migration Agent Diagnostics from a Workstation
Gather workstation logs, event logs, registry information, and diagnostic data forPowerSyncPro Migration Agent support cases
Purpose
This article explains how desktop support engineers can run the PowerSyncPro Diagnostics Script on a workstation during a migration event and provide the resulting diagnostic package to PowerSyncPro Product Support.
The script collects key workstation, network, Entra join, MDM, certificate, service, registry, event log, and PowerSyncPro Migration Agent information into a ZIP file. This helps PowerSyncPro Support investigate migration issues quickly without requiring multiple back-and-forth requests for logs.
Target audience
This article is intended for:
- Desktop Support engineers
- Migration floor-walkers
- Service desk engineers
- EUC / workstation support teams
- Migration event support personnel
The person running the script should be comfortable opening PowerShell, running scripts, and collecting files from the local workstation.
When to run this script
Run the PowerSyncPro Diagnostics Script when a device is experiencing issues during or after a PowerSyncPro migration.
Examples include:
- The migration did not start as expected
- The migration appears stuck
- The device did not join or register correctly
- The user profile did not appear to migrate correctly
- The PowerSyncPro Migration Agent service is missing or not running
- Microsoft apps are not signing in as expected after migration
- The device has network connectivity issues to the PowerSyncPro server
- Intune / MDM enrolment is not behaving as expected
- Product Support has requested diagnostics from the device
File required
The required script is: PSPMADiagnostics.ps1 This script does not require any parameters.
DOWNLOAD PSP Diagnostics:
Recommended permissions
Run the script from an elevated PowerShell session.
That means:
- Click Start
- Type PowerShell
- Right-click Windows PowerShell
- Select Run as administrator
Running as administrator gives the script the best chance of collecting all required registry keys, event logs, certificate information, and system-level diagnostics.
The script can still collect some information without elevation, but the diagnostic package may be incomplete.
How to run the script
Option 1 — Run from the folder where the script is saved
- Copy
PSPMADiagnostics.ps1to the affected workstation. Save to C:\Temp - Open PowerShell as Administrator.
- Change directory to the folder containing the script.
Example:
cd C:\Temp
.\PSPMADiagnostics.ps1
Option 2 — If script execution is blocked
If PowerShell blocks the script due to execution policy, run it using:
powershell.exe -ExecutionPolicy Bypass -File .\PSPMADiagnostics.ps1
What the engineer will see
When the script completes, it displays output similar to:
Diagnostics collection complete.
Folder: C:\Users\Public\Documents\PowerSyncPro\<COMPUTERNAME>_PSP_Diagnostics_<timestamp>
ZIP: C:\Users\Public\Documents\PowerSyncPro\<COMPUTERNAME>_PSP_Diagnostics_<timestamp>.zip
The ZIP file is the main file to send to PowerSyncPro Product Support. This ZIP can be uploaded directly to your support ticket.
What the script collects
The diagnostics package includes a summary file and detailed supporting logs.
Key summary information
The script creates: 00_Summary.txt
This contains the most important findings, including:
- Hostname
- Fully qualified hostname
- Domain or workgroup status
- Windows version and build number
- PowerSyncPro Migration Agent service status
- PowerSyncPro Migration Agent file version
- PowerSyncPro server URL from the local registry
- Connectivity test results to the PowerSyncPro server
- C: drive free space
- Key
dsregcmd /statusvalues, including Entra join and MDM information
Support engineers should check this file first.
Entra join and MDM status
The script runs: dsregcmd /status
This helps identify whether the device is:
- Entra joined
- Hybrid joined
- Workplace joined
- Associated with the expected tenant
- Receiving MDM configuration
- Holding an Azure AD PRT
This information is saved in: 01_dsregcmd_status.txt
Network diagnostics
The script collects network information including:
ipconfig /all- Route table
- Network adapters
- Network connection profiles
- Wireless interface information
- Visible wireless networks
- WinHTTP proxy configuration
- Current user proxy settings
- Local machine proxy settings
- Firewall profile state
It also tests connectivity to the PowerSyncPro server host using:
- Ping
- DNS lookup
- TCP test to port 443
- TCP test to port 5000
These checks are useful where the workstation cannot communicate with the PowerSyncPro service or migration dashboard.
PowerSyncPro Migration Agent details
The script collects:
- PowerSyncPro / Declaration service status
- Service start type
- Whether the Migration Agent executable exists
- Migration Agent executable file version
- PowerSyncPro Migration Agent registry configuration
- PowerSyncPro Migration Agent application event log entries
This helps identify whether the agent is installed, running, correctly configured, and logging errors.
Registry information
The script exports and recursively dumps several important registry locations:
HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CDJHKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\CDJ\AAD
HKLM:\SOFTWARE\Microsoft\Enrollments
HKLM:\SOFTWARE\Declaration Software\Migration Agent
These registry keys are useful when troubleshooting:
- Entra join state
- MDM enrolment state
- Device registration
- PowerSyncPro Migration Agent configuration
- The locally configured PowerSyncPro service URL
Event logs
The script exports:
- Full Windows Application event log
- Last 10 Application log entries from provider
PowerSyncPro Migration Agent - Device Management Enterprise Diagnostics Provider Admin log
- Device Management Enterprise Diagnostics Provider Operational log
Both .csv and .evtx formats are collected where applicable.
These are useful for reviewing migration agent events, MDM enrolment issues, and Windows device management errors.
Certificates
The script exports certificate information from:
Cert:\LocalMachine\MyCert:\LocalMachine\Root
Cert:\LocalMachine\CA
This helps troubleshoot issues involving:
- Device certificates
- Trusted root certificates
- Intermediate certificates
- Entra / MDM / VPN / Wi-Fi certificate dependencies
- Certificate loss or replacement after migration
The script exports metadata only, not private keys.
User profile information
The script collects local Windows profile details, including:
- Profile SID
- Local profile path
- Whether the profile is loaded
- Whether the profile is a special/system profile
- Last use time where available
This is useful when troubleshooting profile mapping or post-migration user profile access issues.
Endpoint protection detection
The script performs a basic heuristic scan for common endpoint protection products by checking services, running processes, and installed applications.
Examples include:
- Microsoft Defender
- CrowdStrike
- SentinelOne
- Sophos
- Trellix / McAfee
- Symantec
- Carbon Black
- Cortex
- Trend Micro
- Bitdefender
This can help identify whether security tooling may be blocking, delaying, quarantining, or interfering with migration activity.
Declaration Software program data
The script collects a recursive folder listing of: C:\ProgramData\Declaration Software
It also copies the contents of that folder into the diagnostics package where accessible.
This may include PowerSyncPro Migration Agent operational files required by Product Support.
What to send to PowerSyncPro Product Support
Send the generated ZIP file to PowerSyncPro Support.
The ZIP file name will include the computer name and timestamp.
Example: LAPTOP123_PSP_Diagnostics_2026-04-24_101530.zip
When logging or updating the support case, include the following information:
Customer name:
Migration event / project:
Affected username:
Affected device name:
Approximate time the issue occurred:
Brief description of the issue:
Whether the user was pre-migration, mid-migration, or post-migration:
Whether the device was on corporate LAN, VPN, home Wi-Fi, or other network:
ZIP file attached:
Suggested support case wording
Desktop Support can use the following template when sending diagnostics to PowerSyncPro Product Support:
Hi PowerSyncPro Support,
Please find attached the diagnostics package collected from the affected workstation.
Customer:
Device name:
User:
Issue summary:
Approximate time of issue:
Migration stage:
Network location:
Additional notes:
The attached ZIP was generated using PSPMADiagnostics.ps1.
Regards,
Important notes
- Run the script as administrator where possible.
- Do not rename individual files inside the ZIP.
- Send the full ZIP file, not just
00_Summary.txt. - If the script is run multiple times, send the ZIP file with the timestamp closest to when the issue occurred.
- The script may contain workstation-specific information such as usernames, device names, domain names, IP configuration, certificate metadata, registry configuration, and event logs.
- Handle the ZIP file as support-sensitive diagnostic data.
Troubleshooting script execution
The script will not run
Use: powershell.exe -ExecutionPolicy Bypass -File .\PSPMADiagnostics.ps1
The ZIP file was not created
Check whether the output folder exists: C:\Users\Public\Documents\PowerSyncPro
If the folder exists but the ZIP does not, send the entire timestamped diagnostics folder to Product Support instead.
Access denied errors appear
Re-run PowerShell as Administrator and run the script again.
The script appears to take a while
This can be normal. The script collects event logs, registry data, certificate metadata, network diagnostics, and a copy of the PowerSyncPro program data folder.
Do not close the PowerShell window until the script displays:
Diagnostics collection complete.