Since Exchange 2010 SP1, the default maximum of ActiveSync devices per user is set to 10. Although this seems rather much for a single user, a user who has multiple phones, uses Windows 8 tiles, tablets etc. can reach this maximum pretty easily.
ActiveSync Settings
ActiveSync settings are applied through a throttling policy. These settings determine the amount of resources that can be used by ActiveSync processes. You can retrieve your current throttling policy settings by running the following command in Exchange Management Shell: Get-ThrottlingPolicy
The settings for ActiveSync all start with EAS. The settings available are: EASMaxConcurrency, EASPercentTimeInAD, EASPercentTimeInCAS, EASPercentTimeInMailboxRPC, EASMaxDevices, EASMaxDeviceDeletesPerMonth
To change the number of ActiveSync devices there are 2 settings you can adjust:
EasMaxDevices: limits the maximum number of active EAS partnerships per user.
EasMaxConcurrency: limits the maximum number of concurrent devices at one time.
Get ActiveSync Devices per user script
Here is a simple powershell script which will look at all the CAS mailboxes, retrieve the ActiveSync device partnerships and show the number of partnerships per user. The output is as follows on screen:
- Full Name of the user
- Identity of the user
- Number of ActiveSync devices / partnerships of the user
You can easily adjust this script to output it to CSV file. If you have an improved version of the script or suggestions, please let me know.
$devices = @() $mailboxes = Get-CASMailbox -ResultSize:Unlimited | Where-Object {$_.HasActiveSyncDevicePartnership -eq $true} foreach ($m in $mailboxes) { $username = $m.Name $useridentity = $m.Identity $devices = Get-ActiveSyncDeviceStatistics -Mailbox $m.Identity if ($devices -is [system.array]) { $numberofdevices = $devices.length } else { if ($devices) { $numberofdevices = 1 } else { $numberofdevices = 0 } } write-host "$username; $useridentity; $numberofdevices" } }
Incoming search terms:
- sfb dbo SessionDetails per user report
I was looking for it.
I will try now
Thanks a ton!
$EASMailboxes = Get-CASMailbox -Filter {HasActiveSyncDevicePartnership -eq $True -and DisplayName -notlike “CAS_{*”} | Get-Mailbox
$EASMailboxes | Select-Object SamAccountName, DisplayName, PrimarySMTPAddress, @{Name=”EASDeviceCount”;Expression={(Get-ActiveSyncDevice -Mailbox $_.Identity).Count}} | Export-CSV .EASMailboxes.csv -NoTypeInformation
if ($devices -is [system.array])
I couldn’t understand the above line . Could you please help
Thanks in advance.
Hello,
I am quite new to powershell. How do you export this to a CSV file please?
Thanks
Florent