Pages

Tuesday, January 18, 2011

Cannot create mail enabled user because an existing object with type already has the same proxy addresses/MasterAccountSid.

When provisioning an MEU using the Prepare-MoveRequest.Ps1 script you receive the following error:

[PS] C:\Program Files\Microsoft\Exchange Server\V14\Scripts>.\Prepare-MoveRequest.Ps1 -Identity "CN=mbperm1,OU=office,D
=ipcfcdom,DC=inphonic,DC=com" -RemoteForestDomainController "dcfcdc03.ipcfcdom.inphonic.com" -RemoteForestCredential $R
mote -LocalForestDomainController "eqdcp01.corp.dom" -LocalForestCredential $Local -TargetMailUserOU "OU=office,DC=corp
DC=dom" -uselocalobject -overwritelocalobject
The operation couldn't be performed because object 'corp.dom/Office/mbperm1' couldn't be found on 'EQDCP01.corp.dom'.
+ CategoryInfo : NotSpecified: (:) [Get-Recipient], ManagementObjectNotFoundException
+ FullyQualifiedErrorId : 4A3D86A8,Microsoft.Exchange.Management.RecipientTasks.GetRecipient

C:\Program Files\Microsoft\Exchange Server\V14\Scripts\Prepare-MoveRequest.ps1 : Cannot create mail enabled user becaus
e an existing object with type already has the same proxy addresses/MasterAccountSid.
At line:1 char:26
+ .\Prepare-MoveRequest.Ps1 <<<< -Identity "CN=mbperm1,OU=office,DC=ipcfcdom,DC=inphonic,DC=com" -RemoteForestDomainCo
ntroller "dcfcdc03.ipcfcdom.inphonic.com" -RemoteForestCredential $Remote -LocalForestDomainController "eqdcp01.corp.do
m" -LocalForestCredential $Local -TargetMailUserOU "OU=office,DC=corp,DC=dom" -uselocalobject -overwritelocalobject
+ CategoryInfo : NotSpecified: (:) [Write-Error], WriteErrorException
+ FullyQualifiedErrorId : Microsoft.PowerShell.Commands.WriteErrorException,Prepare-MoveRequest.ps1

The reason is you used ADMT and didn't exclude the necessary exchange attributes. Therefore prepare-moverequest fails to merge to the existing object brought over by ADMT. The provisioning script must match 3 attributes: Proxyaddresses, mail and mailnickname. You must have all 3 attributes set in order for the script to match and merge the MEU then excluse all other Exchange attributes.

You must script the move to stop the exclusion of some core exchange attributes. The link below shows a sample script. You would then need to append the following lines.

Create a new notepad file and name it ADMTexclusion.vbs and enter the lines below.
Set objMig = CreateObject("ADMT.Migration")

objMig.SystemPropertiesToExclude = "homeMDB, homeMTA, showInAddressBook, msExchHomeServerName, msExchRecipientTypeDetails, msexchrecipientdisplaytype msExchMailboxSecurityDescriptor, msExchMDBRulesQuota, msExchPoliciesIncluded, msExchUserAccountControl, msExchVersion, mdbusedefaults"

Then run the file on your ADMT server:


C:\Windows\SysWOW64>cscript c:\admin\scripts\admtexclusion.vbs

Migrating All User Accounts
http://technet.microsoft.com/en-us/library/cc974368(WS.10).aspx


Another option is to use ADMT to bulk move\seed them without any attributes, then use either powershell or old friend ADModify to bulk update the proxyaddresses, mail and mailnickname. Typically you would use %'samaccount'% as the variable to fill in these attributes.

Finally you can just provision the account using Prepare-MoveRequest.ps1 first then use ADMT.



James Chong
MCITP | EA | EMA; MCSE | M+, S+
Security+, Project+, ITIL
msexchangetips.blogspot.com

29 comments:

  1. I started up by performing ADMT without this script and the result was the creation of a disabled account which mean it did not merge properly.
    Later on I used the script you provided, and as a result when running new-moverequest I got "The critical preperty 'LegacyExchangeDN' is missing in the MailUser". I saw that you also talk about it in a different post, however I find it irresponsible of you to originally post the exclude script as it causes more issues than helping.
    Can you provide an additional script to roll back this change ?

    ReplyDelete
  2. Anonymous7:41 AM

    @ Liran Zamir:
    Woah strong choice of words. If you knew what to do you would not be on this site. Additionally, there is an implied risk of running untested scripts.

    ReplyDelete
  3. Klaus Thorn6:11 AM

    Dear James Chong, thank you very much, your advice helped me out of a dead end.

    Sad that the script does not come with documentation or error messages which highlight these crucial details. Even the documentation for the script that Microsoft provides online is not helpful in preventing this pitfall.

    ReplyDelete
  4. This article is very useful, thank you for sharing. And allow me to share articles too, it's about health and treatment. God willing

    cara menghilangkan kista bartholin
    cara mengobati infeksi ginjal
    pengobatan paru-paru basah secara alami
    obat tipes tradisional untuk anak dan dewasa

    ReplyDelete
  5. Thank you for sharing. I have been searching for it for a long time. It is fortunate to see it from your article. If you want to watch movies, go to my site YesMovies

    ReplyDelete
  6. Anonymous2:32 AM

    movies123. bud absence four zyrtec publisher zyrtec edward

    ReplyDelete
  7. Anonymous11:08 PM

    movies123. Morazán, Thunderbird ‘12, Mentora para el

    ReplyDelete
  8. Anonymous12:51 AM

    123movies. Esiste la storia di un uomo che cade dall’ultimo

    ReplyDelete
  9. Hey guys, you can also checkout my blog for amazing post.
    Here I, am sharing link of some of best posts of my blog. Bum Bollywood

    Pushpa Full Movie Download in Hindi Filmyzilla

    ReplyDelete
  10. Very nice post. I just stumbled upon your blog and wished to say that I have truly enjoyed browsing your blog posts.Newskhabri

    ReplyDelete
  11. This post is very unique and informative for all. Impressive information you share in this. Keep it up and keep sharing.

    artificial intelligence internship | best final year projects for cse | internship certificate online | internship for mba finance students | internship meaning in tamil

    ReplyDelete