We help IT Professionals succeed at work.

Script to list users with SIP attribute in Exchange 2013

Hello, Is there any way to list all users in a AD OU with SIP attribute enabled in EMAIL address tab of user properties.
Comment
Watch Question

HariomExchange Experts

Commented:
Hi,

Please try the following commands

Get-ADUser -Filter {msRTCSIP-UserEnabled -eq $true} -Properties msRTCSIP-PrimaryUserAddress

Ref :  https://social.technet.microsoft.com/Forums/scriptcenter/en-US/fcf08849-2ea5-4861-9dd2-8178fb68634d/attempting-to-query-active-directory-user-attribute-with-ad-powershell?forum=ITCG
Senior Solution Architect
Most Valuable Expert 2015
Top Expert 2015
Commented:
You can do this using the following powershell script...

This will find users that are Enabled for Lync within a specific OU as you have requested.
import-module activedirectory
get-aduser -Filter * -SearchBase "OU=testou,dc=cplvpn,dc=com" -Properties msRTCSIP-PrimaryUserAddress, msRTCSIP-UserEnabled | ? {$_.msRTCSIP-UserEnabled -eq $true} | select name, msRTCSIP-PrimaryUserAddress

Open in new window


That should do it

Will.

Author

Commented:
@viralr Rathod
im getting below error: Get-ADUser : One or more properties are invalid.
Parameter name: msRTCSIP-PrimaryUserAddress