Skip to the main content.

1 min read

Reporting on ActiveSync

Exchange logs quite a bit of info about ActiveSync device partnerships and you can use this to create reports about the utilization of mobility features in your organization. Getting this data requires a couple of intermediate steps before you can export it to a CSV for processing in something like Excel (or another script). The PowerShell script below will export all of the ActiveSync device relationships in your organization. Keep in mind that this will include old relationships which are no longer active. Depending on how large your organization is and the number of device relationships out there, it may take a little while for the script to run.

Note: If you have a mixed version organization (e.g. Exchange 2007 and Exchange 2010), you’ll need to run the script twice. Once in the Exchange 2007 Management Shell and once in the Exchange 2010 Management Shell. The cmdlets used here are not backwards (or forward compatible). I’ve provided two versions of the script – one for Exchange 2007 and one for Exchange 2010.

Exchange 2007 Version

$devices = @()

$mailboxes = Get-CASMailbox -ResultSize:Unlimited | Where-Object {$_.HasActiveSyncDevicePartnership -eq $true -and $_.ExchangeVersion.ExchangeBuild -ilike “8*”}

foreach ($m in $mailboxes)

{

$devices += Get-ActiveSyncDeviceStatistics -Mailbox $m.Identity

}

$devices | Export-Csv DeviceStats.csv

 

Exchange 2010 Version

$devices = @()

$mailboxes = Get-CASMailbox -ResultSize:Unlimited | Where-Object {$_.HasActiveSyncDevicePartnership -eq $true -and $_.ExchangeVersion.ExchangeBuild -ilike “14*”}

foreach ($m in $mailboxes)

{

$devices += Get-ActiveSyncDeviceStatistics -Mailbox $m.Identity

}

$devices | Export-Csv DeviceStats.csv

You can open the exported CSV in Excel from here and generate reports based on that. There is quite a bit of information in the report including some personally identifiable information (PII) for the devices so keep that in mind before redistributing the raw data file.

This was written by Brian Desmond.

Exchange 2010 lack support for UDP Notifications

Important News With Exchange 2010 SP1 RU3, UDP notifications has been re-added to Exchange 2010. This means that the below symptoms will be resolved...

Read More

Install Exchange 2013 Cumulative Update 1

On April 2, 2013, Microsoft release Cumulative Update 1 for Exchange Server 2013. For details about this update visit Description of Cumulative...

Read More

MEC 2012–The Lost Conference

Well, the Microsoft Exchange Conference 2012 is in the books and what a great conference it was. With all of the Wave 15 products leasing in the next...

Read More