Solved

Need a command to find out how many activesync users we have

Posted on 2010-11-29
7
764 Views
Last Modified: 2012-05-10
I am trying to find out exactly how many of our users that ActiveSync enabled on their account. I need this for an audit. I can't believe there is no powershell command to tell me this. I looked and could not find anything. Can someone help out here? Just want to export out all users that have this feature enabled.
0
Comment
Question by:osiexchange
  • 4
  • 3
7 Comments
 
LVL 76

Expert Comment

by:Alan Hardisty
ID: 34231717
What version of Exchange are you using?

If Exchange 2003 - there is no easy way.

If Exchange 2007 / 2010, please use the following:

Get-Mailbox | ForEach {Get-ActiveSyncDeviceStatistics -Mailbox:$_.Identity} | ft DeviceFriendlyName, Devicetype, DeviceUserAgent
0
 

Author Comment

by:osiexchange
ID: 34231734
Sorry. I forgot to mention that. We are using 2007. I will give it a try.
0
 
LVL 76

Expert Comment

by:Alan Hardisty
ID: 34231756
You can play with the variables at the end to get different information out like the username etc.  Shout if you need guidance.
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:osiexchange
ID: 34232348
How would I get the user associated with the device? Is there any way to look at this particular feature to see whether it is enabled or disabled? The command you gave me looks at the device properties with the assumption that AS is enabled, but this is not always the case. When you disable this feature for a user, this device stays in the properties.
0
 
LVL 76

Accepted Solution

by:
Alan Hardisty earned 250 total points
ID: 34232437
Try the following:

Get-CASMailbox -Filter {hasactivesyncdevicepartnership - eq $true} | ForEach {Get-ActiveSyncDeviceStatistics -Mailbox:$_.Identity} | ft Identity, Devicetype

This will show you the device with a current partnership and the user associated with that partnership (active or not).

Get-CASMailbox -Filter {hasactivesyncdevicepartnership - eq $true} | ForEach {Get-ActiveSyncDeviceStatistics -Mailbox:$_.Identity} | ft Identity, Devicetype, LastSuccessSync

The above will show you the last time the device was synced with the server, so you can weed out ones that have not been in touch for a long time.

If you can't see the full username due to the size of the columns, change the line to:

Get-CASMailbox -Filter {hasactivesyncdevicepartnership - eq $true} | ForEach {Get-ActiveSyncDeviceStatistics -Mailbox:$_.Identity} | fl Identity, Devicetype, LastSuccessSync
0
 

Author Comment

by:osiexchange
ID: 34232688
Actually, the command get-CASMailbox all by itself worked great. That gave me what I needed.
0
 
LVL 76

Expert Comment

by:Alan Hardisty
ID: 34233141
Okay - glad you have what you need.

Do you need anything else?  If not - don't forget to close down the question.

Alan
0

Featured Post

The problems with reply email signatures

Do you wish that you could place an email signature under a reply? Well, unfortunately, you can't. That great Exchange/Office 365 signature you've created will just appear at the bottom of an email chain. What a pain! Is there really no way to solve this? Well, there might be...

Join & Write a Comment

"Migrate" an SMTP relay receive connector to a new server using info from an old server.
Easy CSR creation in Exchange 2007,2010 and 2013
In this video we show how to create an email address policy in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Mail Flow…
This video discusses moving either the default database or any database to a new volume.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now