Solved

PowerShell: Error provisoning a user for Office Communicator 2007 R2 (Using SET-QADUser)

Posted on 2011-02-21
8
1,599 Views
Last Modified: 2013-11-29
I'm getting the following error when I attempt to use Quest SET-QADUser to provision a user for OCS 2007 R2 support.

I get that the SET-QADUser is in the example below is modifying the user account attributes directly, but I'm confused as to why the command is failing.

The server I'm pointing to is the Office Communicator 2007 R2 server...

Set-QADUser : A constraint violation occurred.

At \\<network path erased>\NewUserCreationV1_1.ps1:530 char:13

+     set-qaduser <<<<  -identity $strSamAccountName -oa @{'msRTCSIP-UserEnabled'=$true;'msRTCSIP-PrimaryHomeServer'='CN=OCServer1,CN=Live Communicator,CN=Member Servers,CN=Servers,DC=humpty,DC=dumpty,DC=com';'msRTCSIP-PrimaryUserAddress'=("sip:" + $strMailAddress );'msRTCSIP-OptionFlags'=256;'msRTCSIP-InternetAccessEnabled'=$true}

    + CategoryInfo          : NotSpecified: (:) [Set-QADUser], DirectoryServicesCOMException

    + FullyQualifiedErrorId : System.DirectoryServices.DirectoryServicesCOMException,Quest.Act
   iveRoles.ArsPowerShellSnapIn.Powershell.Cmdlets.SetUserCmdlet


Any thoughts?

I don't see any options on Experts Exchange for OCS 2007 (or any OCS / Lync platform for that matter), so I'm placing this in PowerShell and AD.

GB
0
Comment
Question by:gerhardub
  • 4
  • 3
8 Comments
 
LVL 70

Expert Comment

by:Chris Dent
ID: 34942704

They both sit until LCS (Live Communications Server), which is a tad out of date these days.

Anyway, I think this is the problem:

msRTCSIP-PrimaryHomeServer

I believe this should be a reference to the Pool under the Configuration Naming Context, not the server itself in the Domain context.

Chris
0
 
LVL 70

Expert Comment

by:Chris Dent
ID: 34942719

And just for reference, the topic area path is:

OS / Microsoft OS / MS Server OS / Microsoft LCS

Chris
0
 
LVL 1

Author Comment

by:gerhardub
ID: 34943296
You rock... searching just did not find OCS, Lync, or LCS...

A pool eh?  Humph... I just not really familiar with LCS to know what to look for in AD... (Assuming I look in AD for the pool?  ...or is it the container were the OCS server resides?, etc.)

GB
0
Find Ransomware Secrets With All-Source Analysis

Ransomware has become a major concern for organizations; its prevalence has grown due to past successes achieved by threat actors. While each ransomware variant is different, we’ve seen some common tactics and trends used among the authors of the malware.

 
LVL 70

Accepted Solution

by:
Chris Dent earned 500 total points
ID: 34943412

Can you copy it from someone who is already activated on the system?

I forget exactly what it looks like for OCS (upgraded ours to Lync), but it will be named after the server for Standard Edition. And it'll be under this if I remember correctly:

CN=Pools,CN=RTC Service,CN=Services,CN=Configuration,DC=domain,DC=com

If not that, you might check that proxyAddresses already contains the SIP address, not sure if it validates that at all, or if it just figures itself out.

Upgrade to Lync, Enable-CsUser is easier :)

Chris
0
 
LVL 1

Author Comment

by:gerhardub
ID: 34944299
Ok,

So this is what I needed to do to get it to work, and it did work:

set-qaduser -identity $strSamAccountName -oa @{'msRTCSIP-UserEnabled'=$true;'msRTCSIP-primaryHomeServer'='CN=LC Services,CN=Microsoft,CN=<LCS Server>,CN=Pools,CN=RTC Service,CN=Microsoft,CN=System,DC=<company>,DC=com';'msRTCSIP-PrimaryUserAddress'=("sip:" + $strMailAddress );'msRTCSIP-OptionFlags'=256;'msRTCSIP-InternetAccessEnabled'=$true}

What I find confusing is that none of the contructs are visible in AD as OUs.  E.g. pools.RTC Service.Microsoft.System... etc.

Using the format above causes everything to work without issue... the only configuration difference I need to fix is that the "Allow Remote Access" attribute is set to $true.

But the code about will provision an OCS account and it does work!

GB
1
 
LVL 70

Expert Comment

by:Chris Dent
ID: 34944315

> What I find confusing is that none of the contructs are visible in AD as OUs.  E.g. pools.RTC Service.Microsoft.System... etc.

They are, just not in AD Users and Computers. If you fire up ADSI Edit you can access the Configuration naming context, it's an entirely separate partition of AD.

Chris
0
 
LVL 1

Author Comment

by:gerhardub
ID: 34944709
Roger... thanks!
0

Featured Post

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

Join & Write a Comment

Utilizing an array to gracefully append to a list of EmailAddresses
"Migrate" an SMTP relay receive connector to a new server using info from an old server.
This tutorial will walk an individual through the process of transferring the five major, necessary Active Directory Roles, commonly referred to as the FSMO roles to another domain controller. Log onto the new domain controller with a user account t…
This tutorial will walk an individual through the process of configuring their Windows Server 2012 domain controller to synchronize its time with a trusted, external resource. Use Google, Bing, or other preferred search engine to locate trusted NTP …

706 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

20 Experts available now in Live!

Get 1:1 Help Now