Solved

Deleting SIP ID from AD

Posted on 2014-10-03
6
147 Views
Last Modified: 2014-10-23
I currently have my office on Office 365 with DirSYNC.

We are rolling out Lync online to users. We used to have Office Communicator and the SIP ID are now a part of the users AD account.

I need to clear the current SIP ID in field msRTCSIP-PrimaryUserAddress. I know how to do this manually and Office Communicator was used a long time ago, but there are about 400 updates I would need to perform.

With DirSYNC the accounts in Office365 are locked out so the changes must be made locally and Synced up to the cloud.

I'm fairly new to scripting, so I am just starting to get the hang of things.

Thanks.
0
Comment
Question by:Mike Streett
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 16

Accepted Solution

by:
Joshua Grantom earned 333 total points
ID: 40360381
One liner

Import-Module ActiveDirectory ; Get-ADObject -LDAPFilter “(msRTCSIP-PrimaryUserAddress=*)” | ForEach-Object {Set-ADObject -Identity $_.DistinguishedName -Clear “msRTCSIP-PrimaryUserAddress”; “Removed $($_)”}

Open in new window

0
 

Author Comment

by:Mike Streett
ID: 40364302
This is great, thanks.

Just to be on the safe side what would the command be to just run it on one OU at a time.

Such as C3i TestContainer?
0
 
LVL 12

Assisted Solution

by:Jeff_Schertz
Jeff_Schertz earned 167 total points
ID: 40369069
Add the following argument after the Get-ADObject cmdlet:

-SearchBase "OU=someOU,DC=contoso,DC=com"

or if it's a default AD container (and not an OU) then:

-SearchBase "CN=Users,DC=contoso,DC=com"
0
Office 365 Training for Admins - 7 Day Trial

Learn how to provision tenants, synchronize on-premise Active Directory, implement Single Sign-On, customize Office deployment, and protect your organization with eDiscovery and DLP policies.  Only from Platform Scholar.

 
LVL 16

Assisted Solution

by:Joshua Grantom
Joshua Grantom earned 333 total points
ID: 40369095
Sorry about that Mike, I didn't even notice that you asked an additional question, Jeff is correct though.

Import-Module ActiveDirectory ; Get-ADObject -Searchbase "CN=Users,DC=DOMAIN,DC=COM" -LDAPFilter “(msRTCSIP-PrimaryUserAddress=*)” | ForEach-Object {Set-ADObject -Identity $_.DistinguishedName -Clear “msRTCSIP-PrimaryUserAddress”; “Removed $($_)”}

Open in new window


an easy way to find the searchbase is to right click an OU or container, go to Properties > Attribute Editor, and find the distinguishedName.

In order to see the Attribute Editor, you need to have "Advanced Features" enabled from the View menu in ADUC.
0
 

Author Comment

by:Mike Streett
ID: 40400585
Thanks for the help everyone. It's nice to have some other techies to talk with.
0
 
LVL 16

Expert Comment

by:Joshua Grantom
ID: 40400604
You're welcome Mike,

I know how you feel.
0

Featured Post

Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

My attempt to use PowerShell and other great resources found online to simplify the deployment of Office 365 ProPlus client components to any workstation that needs it, regardless of existing Office components that may be needing attention.
There are times when we need to generate a report on the inbox rules, where users have set up forwarding externally in their mailbox. In this article, I will be sharing a script I wrote to generate the report in CSV format.
This Experts Exchange video Micro Tutorial shows how to tell Microsoft Office that a word is NOT spelled correctly. Microsoft Office has a built-in, main dictionary that is shared by Office apps, including Excel, Outlook, PowerPoint, and Word. When …
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

695 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