Link to home
Start Free TrialLog in
Avatar of kblumen
kblumenFlag for United States of America

asked on

How do I script the creation of resource mailboxes/users from a list?

AD Server: Microsoft Windows Server 2003
Mail Server: Exchange Server 2007

I have a list of about 60 conference & training rooms that I need to import into AD/Exchange.  

I would like to script as much of this as possible.  Creation of the disabled user, name, email, password, creation of the resource mailbox, room or equipment, auto accept, capacity, AV/TV/Whiteboard, etc...

Thanks for your time in advance!
ASKER CERTIFIED SOLUTION
Avatar of Jeff_Schertz
Jeff_Schertz
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of kblumen

ASKER

Thank you.  
This helps but I cannot seem to figure out how to include custom properties in the CSV/script.  So if my Conference Room has a (ceiling mounted) LCD projector I want the custom property to exist in my CSV/script.

I checked http://technet.microsoft.com/en-us/library/aa997663.aspx but I cannot figure out which would apply for a custom property.  

Also, what if 10 rooms do not have a custom property, 20 rooms have 2 custom properties and the rest had 3 custom properties?
In the CSV import file you would include a column for every attribute you want to import, but objects without values in those would simply be left blank.  This is most easily managed in Excel and then when you save the file in CSV format you'd see repeated commas indicating there is no data in that field to import.

I'm not sure if the CustomAttribute fields are supported by the New-Mailbox cmdlet.  You might need to create the accounts first and then use a different cmdlet or LDIFDE approach to populate the other data after the account is created.
Avatar of kblumen

ASKER

In the initial link you provided (down in the comments) the author replies to a user asking the same thing:

"The last paragraph in the post has a link to Microsoft's online documentation for new-mailbox command, which lists all the parameters that you can add. The list includes custom attributes as well as plenty of others."

Do you know what they might be called or do you think he misspoke?


The raw AD attrbiute names are extensionAttribute1 through extensionAttribute15.
Avatar of kblumen

ASKER

I am speaking more along the lines of a Mailbox Property.  

So Jeff would you say it is only in the Set-Mailbox cmdlet (http://technet.microsoft.com/en-us/library/bb123981.aspx)
This for example?
 [-ResourceCustom <MultiValuedProperty>]

Would you know how to pass the results of a Get-Mailbox to the Set-Mailbox?