Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Mass-create Mailbox

Status
Not open for further replies.

ntrance

IS-IT--Management
Jan 8, 2008
2
0
0
US
Hello all.

Our organization is running Exchange 2003 for staff email (@domain.edu). We will be offering student email this semester and have set up a Microsoft LIVE@EDU account, which basically hosts the email service for us (@mascot.domain.edu).

Basically we have an MX record that forwards @mascot.campus.edu email to Hotmail servers. Through Exchange we have to Establish An External SMTP email address for a user so that ends up in the Global Address List as well as creates a 'student' distribution list.

We have over 1,000 students and so far we have had to add their Exchange external email manually. Is there a way to automate this?
 
So you want to create a bunch of Contacts in the GAL? You can use CSVDE to do this. Google knows how.
 
zb, I thought about that but was confused by the OP as I wondered if it is 1,000 contacts or 1,000 mailboxes with additional SMTP addresses.
 
Sorry for being vague.
We import users to AD from a csv files via a C# script. I think our current programmer can add the few exchange attributes to it the script to create the external smtp addresses.

Here is a walkthrough of our current Manual steps we have to take:
1.go into AD
2.right-click on the user we want to modify
3.choose 'exchange tasks' (openinging Exchange tasks wizard)
4.choose 'establish e-mail address' username@tbirds.cloud.edu
5.specify desired email address
6. Finish

Now the AD properties for that user have the 'exchange general' 'email address' 'exchange advanced' property tabs.

Another thing is that I am in my first year out of college and not very experienced with how exchange works. I am thinking that we receive the email and our MX record forwards it to the appropriate hotmail server.

We then just import the users and passwords for the LIVE@EDU address through a domain management GUI.
 
It's the proxyaddresses attribute of the user. You need to add a line in the format SMTP:user@domain.edu

You could probably muck around with this script to get it to do what you want:


' Quick and dirty script to remove the default primary smtp address,set a new, and put the old one back as a
' secondary for each member of a nested group
' Author - John Fullbright
' Creation date - 2/12/2004
'
'
' --------------------------------------------- SCRIPT CONFIGURATION --------------------------------------------------
'
'
' strGroupDN is the DN of the group you wish to apply the changes to. You can copy and paste the DN from ADSIEDIT
' strDefaultSuffix is the suffix suffix stamped by the recipient policy for the domain the group is in
' strNewSuffix is the custom suffix you wish to replace the default suffix with for strGroupDN
'
' If you need anything more complex than mailnickname as the prefix then you must modify the script
'
' You will need to create a recipient policy for strNewSuffix with a blank filter so Exchange will accept for delivery
'
strGroupDN = "CN=Test Group,OU=Information Technology,OU=Users,OU=Corporate Office,DC=child,DC=mycompany,DC=com"
strDefaultSuffix = "@permutation1.com"
strNewSuffix = "@permutation2.com"
'
'
' ----------------------------------------------- END CONFIGURATION ---------------------------------------------------
'
'
' create the dictionary and start stamping
set dicSeenGroupMember = CreateObject("Scripting.Dictionary")
StampMembers "LDAP://" & strGroupDN, dicSeenGroupMember
'
Function StampMembers (strGroupADsPath, dicSeenGroupMember)
'
set objGroup = GetObject(strGroupADsPath)
'
for each objMember In objGroup.Members
'
' if the member is a user then stamp it
if objMember.Class = "user" then
' If the smtp address was already there as a secondary smtp address then delete it
objMember.PutEx 4, "ProxyAddresses", Array("smtp:" & objMember.mailnickname & strNewSuffix)
objMember.SetInfo
' put the smtp address in as a primary then set mail and msexchpoliciesexcluded
objMember.PutEx 3, "ProxyAddresses", Array("SMTP:" & objMember.mailnickname & strNewSuffix)
objMember.Put "mail", objMember.mailnickname & strNewSuffix
objMember.Put "msexchpoliciesexcluded", "{26491CFC-9E50-4857-861B-0CB8DF22B5D7}"
objMember.SetInfo
' delete the old primary
objMember.PutEx 4, "ProxyAddresses", Array("SMTP:" & objMember.mailnickname & strDefaultSuffix)
objMember.SetInfo
' add the old primary back as a secondary
objMember.PutEx 3, "ProxyAddresses", Array("smtp:" & objMember.mailnickname & strDefaultSuffix)
objMember.setinfo
end if
'
' if it is a group then expand the group recursively
if objMember.Class = "group" then
'
if dicSeenGroupMember.Exists(objMember.ADsPath) then
' do nothing to avoid looping if we already stamped it
else
' add it to the dictionary and stamp it
dicSeenGroupMember.Add objMember.ADsPath, 1
StampMembers objMember.ADsPath, dicSeenGroupMember
end if
'
end if
'
next
'
End Function
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top