Use this cmdlet to show the progress of active sync tasks. The progress can either be shown a graphical ‘progress bars’ or as decimal ‘percentage’ values.
PowerShell
Show-SyncTaskProgress
- [-TaskID]
- [-ShowPercentages]
- [-Width]
Description
Use the Show-SyncTaskProgress cmdlet to show progress detail about an actively processing SyncTask.
Note that due to the fact that the Super-ExMerge sync task engine being multi-threaded, the display of progress is non-linear. There are threads that execute to examine and collect the folder tree(s), gather and analyze items, as well as threads that do actions like creating folder or copying items. As such, it is difficult to provide a simple linear progress of the sync effort. Take time to review the example below and its sample output to understand what values are reported.
Also note that it can take a 200-1500 ms to pull stats from an active task. Running this cmdlet in a repetitive high frequency fashion is not advised as doing so will spike the CPU utilization and thus lower the availability for the sync.
The -ShowPercentages can be helpful in producing one’s own view or report on progress, for example pulling this data an creating a chart or graph in an application or web page.
Examples
Example 1
PowerShell
Show-SyncTaskProgress -TaskID 11223344-aabb-ccdd-eeff-112233445566 TaskID : 335d55d1-1fc2-4f57-bc23-71c8319fa84d TaskName : Sync from [Mailbox] user@source.com to [Mailbox] user@target.com ------------------------------ : Startup Progress : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Source Folder Enumeration : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Target Folder Enumeration : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Source Folder Analysis : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Target Folder Analysis : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Source Items Enumerated : [oooooooo ] Target Items Enumerated : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Source Item Analysis : [oooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooooo] Target Item Analysis : [ ] Source Folder Content Collect : [ooooooooooooooooooooooooooooooooooooooooooo ] Target Folder Content Collect : [oooooooooooooooooooooooooooooooooooooooooooooooooooo ] Item Processing : [ ] Item Completion : [ ]
This example shows the graphical progress-bar view of the various counters related to an active task.
Example 2
PowerShell
Show-SyncTaskProgress -ShowPercentages TaskID : 335d55d1-1fc2-4f57-bc23-71c8319fa84d TaskName : Sync from [Mailbox] user@source.com to [Mailbox] user@target.com ------------------------------ : Startup Progress : 1.00 Source Folder Enumeration : 1.00 Target Folder Enumeration : 1.00 Source Folder Analysis : 1.00 Target Folder Analysis : 1.00 Source Items Enumerated : 0.28 Target Items Enumerated : 0.98 Source Item Analysis : 0.97 Target Item Analysis : 0.00 Source Folder Content Collect : 0.79 Target Folder Content Collect : 0.68 Item Processing : 0.00 Item Completion : 0.00
This example will show the progress of all active sync tasks, and will show percentage values instead of progress-bars.
Values returned are System.Double values. To convert to a friend % value, multiply by 100, or use .NET’s .ToString(‘P2’) method.
Parameters
-TaskID
The TaskID parameter specifies the SyncTask for which to display progress detail. Note that only an actively processing task can have progress detail shown by this cmdlet.
-ShowPercentages
The ShowPercentages switch parameter changes the output to show decimal percentage values instead of progress-bars.
Returned values with this parameter are System.Double.
-Width
The Width parameter specifies the number of characters to use to generate the progress-bar detail.
If PowerShell is hosted in a non-default application, the cmdlet may not be able to determine the width of the console buffer and will default to a with of 20.
This parameter can be valuable for headless use, for example in a PowerShell job or scheduled task, to control the width of the progress-bars.
Output
This cmdlet will place a PSObject instance on the pipeline with the details shown in Example #1 above for the SyncTask referenced by the TaskID parameter.
