Using powershell to Enable-mailbox for list of users using exactly the username listed?
Sorry think I posted this in wrong forum initially, looking all over for how to specify exact match with Enable-Mailbox. Keep getting errors for "Enable-Mailbox : The operation could not be performed because 'User' matches multiple entries"' In our AD enviro we may have a 'User' a 'User1', User2 etc. The command simply reads from a csv a list of users and what database to enable them on in Exchange This is the command, very simple.. import-csv c:\drmbstest.csv | ForEach-Object { Enable-Mailbox -Identity $_.Login -database $_.Store} Any help appreciated, thanks in advance.Regards, Michael
August 3rd, 2010 11:10pm

what attribute is the one read from the csv file? Check this link for provisioing new users: http://www.myexchangeworld.com/2010/02/powershell-provisioning-users/ thanks ThiyaguThiyagu | MCTS/MCITP - Exchange 2007 | MCSE 2003[Messaging] | http://www.myExchangeWorld.com. This posting is provided "AS IS" with no warranties, and confers no rights.
Free Windows Admin Tool Kit Click here and download it now
August 3rd, 2010 11:21pm

Using the users login name, it is behaving like find in ad users and computers which gives you matches for multiple users if you enter the first few characters of a login name. Not sure if the new user provisioning article helps, I don't get this error provisioning new users from commandline, but haven't done it often enough to notice. Just getting ready to go live with an Exchange project (migration from groupwise to exchange), have a list of like 600 pre existing users in AD in additon to the users being migrated with all attributes attached, just need to mailbox enable them, and they will get our default mail templates etc applied. It may just be this commandlet is limited, and I will pipe the errors for duplicates as above to an output file and do these manually from EMC.Regards, Michael
August 4th, 2010 12:13am

Figured it out. Have to use Domain\username and not just username and I get an exact match, go figure. Looked at Microsofts detailed documentation online for the commandlet it had in italics domain\username as possible parameter for Identity, so gave it a try that way. Thanks for your help though :) Regards, Michael
Free Windows Admin Tool Kit Click here and download it now
August 4th, 2010 12:20am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics